Search Results for

    Show / Hide Table of Contents

    Class RequestModuleExtensions

    Set of extension methods used to bring request module support

    Inheritance
    System.Object
    RequestModuleExtensions
    Namespace: PnP.Core.Model
    Assembly: PnP.Core.dll
    Syntax
    public static class RequestModuleExtensions : object

    Methods

    WithHeaders<TModel>(ISupportModules<TModel>, Dictionary<String, String>, Action<Dictionary<String, String>>)

    Executes this request with additional request headers

    Declaration
    public static TModel WithHeaders<TModel>(this ISupportModules<TModel> dataModel, Dictionary<string, string> headers, Action<Dictionary<string, string>> responseHeaders = null)
    Parameters
    ISupportModules<TModel> dataModel

    Model instance to operate on

    Dictionary<System.String, System.String> headers

    Collection of headers to add to add to the request

    Action<Dictionary<System.String, System.String>> responseHeaders

    Delegate that can be invoked to pass along the response headers

    Returns
    TModel

    The passed model instance

    Type Parameters
    TModel

    Model type

    WithResponseHeaders<TModel>(ISupportModules<TModel>, Action<Dictionary<String, String>>)

    Returns the response headers for Microsoft Graph, SharePoint REST and CSOM requests after this request has been executed

    Declaration
    public static TModel WithResponseHeaders<TModel>(this ISupportModules<TModel> dataModel, Action<Dictionary<string, string>> responseHeaders = null)
    Parameters
    ISupportModules<TModel> dataModel

    Model instance to operate on

    Action<Dictionary<System.String, System.String>> responseHeaders

    Delegate that can be invoked to receive the response headers

    Returns
    TModel

    The passed model instance

    Type Parameters
    TModel

    Model type

    Back to top PnP Core SDK
    Generated by DocFX with Material UI
    spacer