Show / Hide Table of Contents

    Interface IResourceCollection<TResource, TEntity>

    The resource collection interface.

    Inherited Members
    IResourceCollection.TerminateAsync(TimeSpan)
    IResourceBase.CreatedDateTime
    IResourceBase.Client
    IResourceBase.GraphClient
    IResourceBase.GraphLogger
    IResourceBase.ResourcePath
    IDisposable.Dispose()
    IReadOnlyCollection<TResource>.Count
    IEnumerable<TResource>.GetEnumerator()
    Namespace: Microsoft.Graph.Communications.Resources
    Assembly: Microsoft.Graph.Communications.Client.dll
    Syntax
    public interface IResourceCollection<TResource, in TEntity> : IResourceCollection, IResourceBase, IDisposable, IReadOnlyCollection<TResource>, IEnumerable<TResource>, IEnumerable where TResource : IResource where TEntity : Entity
    Type Parameters
    Name Description
    TResource

    The containing resource type. IResource<TSelf, TEntity>

    TEntity

    The containing resource type. Entity

    Properties

    Item[String]

    The resource with the specified identifier.

    Declaration
    TResource this[string id] { get; }
    Parameters
    Type Name Description
    String id

    The identifier.

    Property Value
    Type Description
    TResource

    The IResource<TSelf, TEntity>.

    Methods

    TryForceRemove(String, out TResource)

    Attempts to remove and return the value that has the specified id from the IResourceCollection<TResource, TEntity>. This will force remove the object, if for whatever reason it cannot be removed by the service. It should only be used as a last resort to clean up stale resources.

    Declaration
    bool TryForceRemove(string id, out TResource resource)
    Parameters
    Type Name Description
    String id

    The identifier.

    TResource resource

    The resource.

    Returns
    Type Description
    Boolean

    true if the object was removed successfully; otherwise, false.

    See Also

    IResourceCollection
    IReadOnlyCollection<T>
    Back to top Copyright (c) Microsoft Corporation. All rights reserved.