docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Class FileExtensions

    Extension methods for IFile.

    Inheritance
    object
    FileExtensions
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Unity.Cloud.Assets
    Assembly: Unity.Cloud.Assets.dll
    Syntax
    public static class FileExtensions

    Methods

    ListUpdateHistoriesAsync(IFile, Range, CancellationToken)

    Returns the update histories of the file.

    Declaration
    public static IAsyncEnumerable<FileUpdateHistory> ListUpdateHistoriesAsync(this IFile file, Range range, CancellationToken cancellationToken)
    Parameters
    Type Name Description
    IFile file

    The file to query.

    Range range

    The range of results to return.

    CancellationToken cancellationToken

    A token that can be used to cancel the request.

    Returns
    Type Description
    IAsyncEnumerable<FileUpdateHistory>

    An async enumeration of FileUpdateHistory in descending order of SequenceNumber.

    UpdateAsync(IFile, FileUpdateHistory, CancellationToken)

    Updates the file to its state at the specified update history sequence number.

    Declaration
    public static Task UpdateAsync(this IFile file, FileUpdateHistory fileUpdateHistory, CancellationToken cancellationToken)
    Parameters
    Type Name Description
    IFile file

    The file to query.

    FileUpdateHistory fileUpdateHistory

    The update history entry to which the file should be updated.

    CancellationToken cancellationToken

    A token that can be used to cancel the request.

    Returns
    Type Description
    Task

    A task with no result.

    UpdateAsync(IFile, FileUpdateHistoryDescriptor, CancellationToken)

    Updates the file to its state at the specified update history sequence number.

    Declaration
    public static Task UpdateAsync(this IFile file, FileUpdateHistoryDescriptor fileUpdateHistoryDescriptor, CancellationToken cancellationToken)
    Parameters
    Type Name Description
    IFile file

    The file to query.

    FileUpdateHistoryDescriptor fileUpdateHistoryDescriptor

    The update history descriptor to which the file should be updated.

    CancellationToken cancellationToken

    A token that can be used to cancel the request.

    Returns
    Type Description
    Task

    A task with no result.

    In This Article
    Back to top
    Copyright © 2025 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)