/// <summary> /// Create a new URL request that is not associated with a specific browser or frame. /// Use <see cref="IFrame.CreateUrlRequest(IRequest, IUrlRequestClient)"/> instead if you want the /// request to have this association, in which case it may be handled differently. /// For requests originating from the browser process: It may be intercepted by the client via <see cref="IResourceRequestHandler"/> or <see cref="ISchemeHandlerFactory"/>. /// POST data may only contain only a single element of type PDE_TYPE_FILE or PDE_TYPE_BYTES. /// </summary> /// <param name="request">request</param> /// <param name="urlRequestClient">url request client</param> /// <param name="requestContext">request context associated with this requets.</param> public UrlRequest(IRequest request, IUrlRequestClient urlRequestClient, IRequestContext requestContext) { if (request == null) { throw new ArgumentNullException(nameof(request)); } if (urlRequestClient == null) { throw new ArgumentNullException(nameof(urlRequestClient)); } urlRequest = new CefSharp.Core.UrlRequest(request.UnWrap(), urlRequestClient, requestContext?.UnWrap()); }
/// <summary> /// Create a new instance of <see cref="IUrlRequest"/> /// </summary> /// <param name="request">request</param> /// <param name="urlRequestClient">url request client</param> /// <param name="requestContext">request context</param> /// <returns>returns new instance of <see cref="IUrlRequest"/></returns> public static IUrlRequest CreateUrlRequest(IRequest request, IUrlRequestClient urlRequestClient, IRequestContext requestContext) { return(new CefSharp.Core.UrlRequest(request, urlRequestClient, requestContext)); }
/// <summary> /// Create a new URL request that is not associated with a specific browser or frame. /// Use <see cref="IFrame.CreateUrlRequest(IRequest, IUrlRequestClient)"/> instead if you want the /// request to have this association, in which case it may be handled differently. /// For requests originating from the browser process: It may be intercepted by the client via <see cref="IResourceRequestHandler"/> or <see cref="ISchemeHandlerFactory"/>. /// POST data may only contain only a single element of type PDE_TYPE_FILE or PDE_TYPE_BYTES. /// Uses the Global RequestContext /// </summary> /// <param name="request">request</param> /// <param name="urlRequestClient">url request client</param> public IUrlRequest Create(IRequest request, IUrlRequestClient urlRequestClient) { return(new CefSharp.Core.UrlRequest(request, urlRequestClient)); }
/// <inheritdoc/> public UrlRequest(IRequest request, IUrlRequestClient urlRequestClient, IRequestContext requestContext) : base(request, urlRequestClient, requestContext) { }
/// <inheritdoc/> public UrlRequest(IRequest request, IUrlRequestClient urlRequestClient) : base(request, urlRequestClient) { }
/// <summary> /// Create a new URL request that is not associated with a specific browser or frame. /// Use <see cref="IFrame.CreateUrlRequest(IRequest, IUrlRequestClient)"/> instead if you want the /// request to have this association, in which case it may be handled differently. /// For requests originating from the browser process: It may be intercepted by the client via <see cref="IResourceRequestHandler"/> or <see cref="ISchemeHandlerFactory"/>. /// POST data may only contain only a single element of type PDE_TYPE_FILE or PDE_TYPE_BYTES. /// Uses the Global RequestContext /// </summary> /// <param name="request">request</param> /// <param name="urlRequestClient">url request client</param> public UrlRequest(IRequest request, IUrlRequestClient urlRequestClient) : this(request, urlRequestClient, null) { }