Search Results for

    Show / Hide Table of Contents

    Interface IListItemCollection

    Public interface to define a collection of ListItem objects of SharePoint Online

    Inherited Members
    IQueryable.ElementType
    IQueryable.Expression
    IQueryable.Provider
    IAsyncEnumerable<IListItem>.GetAsyncEnumerator(CancellationToken)
    IEnumerable<IListItem>.GetEnumerator()
    IDataModelParent.Parent
    IDataModelWithContext.PnPContext
    IRequestableCollection.Requested
    IRequestableCollection.Length
    IRequestableCollection.RequestedItems
    IRequestableCollection.Clear()
    IDataModelCollectionLoad<IListItem>.LoadAsync(params Expression<Func<IListItem, object>>[])
    IDataModelCollectionLoad<IListItem>.LoadBatchAsync(Batch, params Expression<Func<IListItem, object>>[])
    IDataModelCollectionDeleteByIntegerId.DeleteById(int)
    IDataModelCollectionDeleteByIntegerId.DeleteByIdAsync(int)
    IDataModelCollectionDeleteByIntegerId.DeleteByIdBatch(int)
    IDataModelCollectionDeleteByIntegerId.DeleteByIdBatchAsync(int)
    IDataModelCollectionDeleteByIntegerId.DeleteByIdBatch(Batch, int)
    IDataModelCollectionDeleteByIntegerId.DeleteByIdBatchAsync(Batch, int)
    Namespace: PnP.Core.Model.SharePoint
    Assembly: PnP.Core.dll
    Syntax
    public interface IListItemCollection : IQueryable<IListItem>, IQueryable, IAsyncEnumerable<IListItem>, IDataModelCollection<IListItem>, IEnumerable<IListItem>, IEnumerable, IDataModelParent, IDataModelWithContext, IRequestableCollection, IDataModelCollectionLoad<IListItem>, IDataModelCollectionDeleteByIntegerId, ISupportModules<IListItemCollection>

    Methods

    Add(Dictionary<string, object>, string, FileSystemObjectType)

    Adds a new list item

    Declaration
    IListItem Add(Dictionary<string, object> values, string folderPath = null, FileSystemObjectType underlyingObjectType = FileSystemObjectType.File)
    Parameters
    Dictionary<string, object> values

    Values to add to list item

    string folderPath

    Optional folder path to add the item to.

    FileSystemObjectType underlyingObjectType

    Type of object to create. Defaults to File/ListItem

    Returns
    IListItem

    Newly added list item

    AddAsync(Dictionary<string, object>, string, FileSystemObjectType)

    Adds a new list item

    Declaration
    Task<IListItem> AddAsync(Dictionary<string, object> values, string folderPath = null, FileSystemObjectType underlyingObjectType = FileSystemObjectType.File)
    Parameters
    Dictionary<string, object> values

    Values to add to list item

    string folderPath

    Optional folder path to add the item to.

    FileSystemObjectType underlyingObjectType

    Type of object to create. Defaults to File/ListItem

    Returns
    Task<IListItem>

    Newly added list item

    AddBatch(Batch, Dictionary<string, object>, string, FileSystemObjectType)

    Adds a new list item

    Declaration
    IListItem AddBatch(Batch batch, Dictionary<string, object> values, string folderPath = null, FileSystemObjectType underlyingObjectType = FileSystemObjectType.File)
    Parameters
    Batch batch

    Batch to use

    Dictionary<string, object> values

    Values to add to list item

    string folderPath

    Optional folder path to add the item to.

    FileSystemObjectType underlyingObjectType

    Type of object to create. Defaults to File/ListItem

    Returns
    IListItem

    Newly added list item

    AddBatch(Dictionary<string, object>, string, FileSystemObjectType)

    Adds a new list item

    Declaration
    IListItem AddBatch(Dictionary<string, object> values, string folderPath = null, FileSystemObjectType underlyingObjectType = FileSystemObjectType.File)
    Parameters
    Dictionary<string, object> values

    Values to add to list item

    string folderPath

    Optional folder path to add the item to.

    FileSystemObjectType underlyingObjectType

    Type of object to create. Defaults to File/ListItem

    Returns
    IListItem

    Newly added list item

    AddBatchAsync(Batch, Dictionary<string, object>, string, FileSystemObjectType)

    Adds a new list item

    Declaration
    Task<IListItem> AddBatchAsync(Batch batch, Dictionary<string, object> values, string folderPath = null, FileSystemObjectType underlyingObjectType = FileSystemObjectType.File)
    Parameters
    Batch batch

    Batch to use

    Dictionary<string, object> values

    Values to add to list item

    string folderPath

    Optional folder path to add the item to.

    FileSystemObjectType underlyingObjectType

    Type of object to create. Defaults to File/ListItem

    Returns
    Task<IListItem>

    Newly added list item

    AddBatchAsync(Dictionary<string, object>, string, FileSystemObjectType)

    Adds a new list item

    Declaration
    Task<IListItem> AddBatchAsync(Dictionary<string, object> values, string folderPath = null, FileSystemObjectType underlyingObjectType = FileSystemObjectType.File)
    Parameters
    Dictionary<string, object> values

    Values to add to list item

    string folderPath

    Optional folder path to add the item to.

    FileSystemObjectType underlyingObjectType

    Type of object to create. Defaults to File/ListItem

    Returns
    Task<IListItem>

    Newly added list item

    Contains(int)

    Checks if the collection contains a listitem with a given id

    Declaration
    bool Contains(int id)
    Parameters
    int id

    Id to check for

    Returns
    bool

    True if found, false otherwise

    GetById(int, params Expression<Func<IListItem, object>>[])

    Method to select a list item by Id

    Declaration
    IListItem GetById(int id, params Expression<Func<IListItem, object>>[] selectors)
    Parameters
    int id

    The Id to search for

    Expression<Func<IListItem, object>>[] selectors

    The expressions declaring the fields to select

    Returns
    IListItem

    The resulting list item instance, if any

    GetByIdAsync(int, params Expression<Func<IListItem, object>>[])

    Method to select a list item by Id asynchronously

    Declaration
    Task<IListItem> GetByIdAsync(int id, params Expression<Func<IListItem, object>>[] selectors)
    Parameters
    int id

    The Id to search for

    Expression<Func<IListItem, object>>[] selectors

    The expressions declaring the fields to select

    Returns
    Task<IListItem>

    The resulting list item instance, if any

    RecycleById(int)

    Recycle the list item

    Declaration
    Guid RecycleById(int id)
    Parameters
    int id

    Id of the item to recycle

    Returns
    Guid

    RecycleByIdAsync(int)

    Recycle the list item

    Declaration
    Task<Guid> RecycleByIdAsync(int id)
    Parameters
    int id

    Id of the item to recycle

    Returns
    Task<Guid>

    RecycleByIdBatch(Batch, int)

    Recycle the list item

    Declaration
    void RecycleByIdBatch(Batch batch, int id)
    Parameters
    Batch batch

    Batch to add the request to

    int id

    Id of the item to recycle

    RecycleByIdBatch(int)

    Recycle the list item

    Declaration
    void RecycleByIdBatch(int id)
    Parameters
    int id

    Id of the item to recycle

    RecycleByIdBatchAsync(Batch, int)

    Recycle the list item

    Declaration
    Task RecycleByIdBatchAsync(Batch batch, int id)
    Parameters
    Batch batch

    Batch to add the request to

    int id

    Id of the item to recycle

    Returns
    Task

    RecycleByIdBatchAsync(int)

    Recycle the list item

    Declaration
    Task RecycleByIdBatchAsync(int id)
    Parameters
    int id

    Id of the item to recycle

    Returns
    Task

    Extension Methods

    DataModelCollectionLoadExtensions.LoadBatchAsync<TModel>(IDataModelCollectionLoad<TModel>, Batch, params Expression<Func<TModel, object>>[])
    DataModelCollectionLoadExtensions.LoadBatchAsync<TModel>(IDataModelCollectionLoad<TModel>, params Expression<Func<TModel, object>>[])
    DataModelCollectionLoadExtensions.LoadBatch<TModel>(IDataModelCollectionLoad<TModel>, Batch, params Expression<Func<TModel, object>>[])
    DataModelCollectionLoadExtensions.LoadBatch<TModel>(IDataModelCollectionLoad<TModel>, params Expression<Func<TModel, object>>[])
    DataModelCollectionLoadExtensions.Load<TModel>(IDataModelCollectionLoad<TModel>, params Expression<Func<TModel, object>>[])
    QueryableExtensions.AsRequested<TSource>(IDataModelCollection<TSource>)
    RequestModuleExtensions.WithHeaders<TModel>(ISupportModules<TModel>, Dictionary<string, string>, Action<Dictionary<string, string>>)
    RequestModuleExtensions.WithResponseHeaders<TModel>(ISupportModules<TModel>, Action<Dictionary<string, string>>)
    QueryableExtensions.AsAsyncEnumerable<TSource>(IQueryable<TSource>)
    QueryableExtensions.AsBatchAsync<TSource>(IQueryable<TSource>)
    QueryableExtensions.AsBatchAsync<TSource>(IQueryable<TSource>, Batch)
    QueryableExtensions.AsBatch<TSource>(IQueryable<TSource>)
    QueryableExtensions.AsBatch<TSource>(IQueryable<TSource>, Batch)
    QueryableExtensions.FirstAsync<TSource>(IQueryable<TSource>, Expression<Func<TSource, bool>>, CancellationToken)
    QueryableExtensions.FirstAsync<TSource>(IQueryable<TSource>, CancellationToken)
    QueryableExtensions.FirstOrDefaultAsync<TSource>(IQueryable<TSource>, Expression<Func<TSource, bool>>, CancellationToken)
    QueryableExtensions.FirstOrDefaultAsync<TSource>(IQueryable<TSource>, CancellationToken)
    QueryableExtensions.ForEachAsync<T>(IQueryable<T>, Action<T>, CancellationToken)
    QueryableExtensions.QueryProperties<TResult>(IQueryable<TResult>, params Expression<Func<TResult, object>>[])
    QueryableExtensions.ToArrayAsync<TSource>(IQueryable<TSource>, CancellationToken)
    QueryableExtensions.ToDictionaryAsync<TSource, TKey>(IQueryable<TSource>, Func<TSource, TKey>, IEqualityComparer<TKey>, CancellationToken)
    QueryableExtensions.ToDictionaryAsync<TSource, TKey>(IQueryable<TSource>, Func<TSource, TKey>, CancellationToken)
    QueryableExtensions.ToDictionaryAsync<TSource, TKey, TElement>(IQueryable<TSource>, Func<TSource, TKey>, Func<TSource, TElement>, IEqualityComparer<TKey>, CancellationToken)
    QueryableExtensions.ToDictionaryAsync<TSource, TKey, TElement>(IQueryable<TSource>, Func<TSource, TKey>, Func<TSource, TElement>, CancellationToken)
    QueryableExtensions.ToListAsync<TSource>(IQueryable<TSource>, CancellationToken)
    Back to top PnP Core SDK
    Generated by DocFX with Material UI
    spacer