Show / Hide Table of Contents

Class WMHTTPRequestDTO

Data Transfer Object proxy for a WMHTTPRequest.

Inheritance
object
DataTransferObject<WMHTTPRequest>
WMAssetBaseDTO<WMHTTPRequest>
WMHTTPRequestDTO
Implements
IWMAssetBaseDTO
IWMVersionableAsset
IWMOwnableResource
IWMResource
IDbEntity
IWMEntity
Inherited Members
WMAssetBaseDTO<WMHTTPRequest>.ID
WMAssetBaseDTO<WMHTTPRequest>.Name
WMAssetBaseDTO<WMHTTPRequest>.OwnerID
WMAssetBaseDTO<WMHTTPRequest>.OwnerType
WMAssetBaseDTO<WMHTTPRequest>.ParentID
WMAssetBaseDTO<WMHTTPRequest>.FullPathName
WMAssetBaseDTO<WMHTTPRequest>.CreatedBy
WMAssetBaseDTO<WMHTTPRequest>.CreatedDate
WMAssetBaseDTO<WMHTTPRequest>.LastUpdatedBy
WMAssetBaseDTO<WMHTTPRequest>.LastUpdatedDate
WMAssetBaseDTO<WMHTTPRequest>.Summary
WMAssetBaseDTO<WMHTTPRequest>.Documentation
WMAssetBaseDTO<WMHTTPRequest>.DocumentationMIMEType
WMAssetBaseDTO<WMHTTPRequest>.Properties
WMAssetBaseDTO<WMHTTPRequest>.Version
WMAssetBaseDTO<WMHTTPRequest>.VersionName
WMAssetBaseDTO<WMHTTPRequest>.Status
WMAssetBaseDTO<WMHTTPRequest>.IsDeleted
WMAssetBaseDTO<WMHTTPRequest>.PropertiesSerialized
WMAssetBaseDTO<WMHTTPRequest>.UpdateDTO<A, B>(WMPrincipal, WMAssetIdentifier, A, DbSet<A>, WMAppDbContext, Func<A, Task>)
WMAssetBaseDTO<WMHTTPRequest>.CreateDTO<A, B>(WMPrincipal, A, DbSet<A>, WMAppDbContext, Func<A, Task>)
WMAssetBaseDTO<WMHTTPRequest>.DeleteDTO<A, B>(WMPrincipal, WMAssetIdentifier, DbSet<A>, WMAppDbContext, Func<A, Task>)
WMAssetBaseDTO<WMHTTPRequest>.ValidateDirectory<T_Asset>(WMPrincipal, WMAssetBaseDTO<T_Asset>, WMAssetBaseDTO<T_Asset>, WMAppDbContext)
WMAssetBaseDTO<WMHTTPRequest>.CloneDTO<A, B>(WMPrincipal, WMAssetIdentifier, DbSet<A>, VersionCreateArgs, WMAppDbContext, Func<A, Task>)
WMAssetBaseDTO<WMHTTPRequest>.CommitDTO<A, B>(WMPrincipal, WMAssetIdentifier, DbSet<A>, WMAppDbContext)
WMAssetBaseDTO<WMHTTPRequest>.DTOVersions<A, B>(WMPrincipal, WMAssetIdentifier, DbSet<A>, WMAppDbContext)
WMAssetBaseDTO<WMHTTPRequest>.GetDTO<A>(WMPrincipal, WMAssetIdentifier, IQueryable<A>, WMAppDbContext, Expression<Func<A, A>>)
WMAssetBaseDTO<WMHTTPRequest>.GetDTOFromDirectory<A>(WMPrincipal, WMAssetIdentifier, int, DbSet<A>, WMAppDbContext, Expression<Func<A, A>>)
WMAssetBaseDTO<WMHTTPRequest>.GetAuthorizedAssetIQueryable<A>(WMPrincipal, IQueryable<A>, WMAppDbContext)
WMAssetBaseDTO<WMHTTPRequest>.GetEveryAuthorizedAssetIQueryable(WMPrincipal, WMAppDbContext)
WMAssetBaseDTO<WMHTTPRequest>.GetIdentifier(bool)
DataTransferObject<WMHTTPRequest>.ModelObject
DataTransferObject<WMHTTPRequest>.SetID(string)
DataTransferObject<WMHTTPRequest>.CreateModel(WMPrincipal, DbContext, object[])
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: Quantellia.WMServer.Asset.Model.HTTP.Request
Assembly: WMServer.dll
Syntax
[PrimaryKey("ID", new string[] { "Version" })]
public class WMHTTPRequestDTO : WMAssetBaseDTO<WMHTTPRequest>, IWMAssetBaseDTO, IWMVersionableAsset, IWMOwnableResource, IWMResource, IDbEntity, IWMEntity

Constructors

WMHTTPRequestDTO()

Constructor for DTO

Declaration
public WMHTTPRequestDTO()

WMHTTPRequestDTO(string)

Constructor for DTO, with specified ID

Declaration
public WMHTTPRequestDTO(string ID)
Parameters
Type Name Description
string ID

Properties

HTTPConnectionID

The WMHTTPConnection that this request requests from.

Declaration
public string HTTPConnectionID { get; set; }
Property Value
Type Description
string

Headers

Optional headers to add to and overwrite the Headers contained in the HTTPConnectionID

Declaration
[NotMapped]
public Dictionary<string, string> Headers { get; set; }
Property Value
Type Description
Dictionary<string, string>

HeadersSerialized

Serializes to and from Headers

Declaration
public string HeadersSerialized { get; set; }
Property Value
Type Description
string

Method

The method to call on this request.

Declaration
public WMHTTPRequest.HTTPMethod Method { get; set; }
Property Value
Type Description
WMHTTPRequest.HTTPMethod

Route

An additional path on top of the HTTPConnectionID's Endpoint

Declaration
public string Route { get; set; }
Property Value
Type Description
string

Methods

Clone(WMPrincipal, WMAssetIdentifier, VersionCreateArgs?, WMAppDbContext)

Clones the specified asset with an iterated name "AssetName (1), etc... ", iterates the version number.

Declaration
public static Task<WMHTTPRequestDTO> Clone(WMPrincipal principal, WMAssetIdentifier identifier, VersionCreateArgs? args, WMAppDbContext context)
Parameters
Type Name Description
WMPrincipal principal

The owner of the directory

WMAssetIdentifier identifier

The identifier of the directory

VersionCreateArgs args

Arguments for creating a version.

WMAppDbContext context

The DbContext

Returns
Type Description
Task<WMHTTPRequestDTO>
Exceptions
Type Condition
Exception

Commit(WMPrincipal, WMAssetIdentifier, WMAppDbContext)

Commits the specified asset as Head.

Declaration
public static Task Commit(WMPrincipal principal, WMAssetIdentifier identifier, WMAppDbContext context)
Parameters
Type Name Description
WMPrincipal principal

The owner of the directory

WMAssetIdentifier identifier

The identifier of the directory

WMAppDbContext context

The DbContext

Returns
Type Description
Task
Exceptions
Type Condition
Exception

Create(WMPrincipal, WMHTTPRequestDTO, WMAppDbContext)

Create a new WMHTTPRequestDTO from the provided data.

Declaration
public static Task<WMHTTPRequest> Create(WMPrincipal principal, WMHTTPRequestDTO a_dto, WMAppDbContext context)
Parameters
Type Name Description
WMPrincipal principal

The owner of the data reader

WMHTTPRequestDTO a_dto

The WMHTTPRequestDTO to be created.

WMAppDbContext context

The DbContext

Returns
Type Description
Task<WMHTTPRequest>
Exceptions
Type Condition
Exception

Delete(WMPrincipal, WMAssetIdentifier, WMAppDbContext)

Delete the WMHTTPRequestDTO with the corresponding ID or FullPathName

Declaration
public static Task Delete(WMPrincipal principal, WMAssetIdentifier identifier, WMAppDbContext context)
Parameters
Type Name Description
WMPrincipal principal

The owner of the directory

WMAssetIdentifier identifier

The identifier of the asset

WMAppDbContext context

The DbContext

Returns
Type Description
Task
Exceptions
Type Condition
Exception

Evaluate(WMPrincipal, WMAssetIdentifier, HTTPRequestArgs, WMAppDbContext)

Performs an evaluation on an existing DataReader, or a temporary one created from the arguments of the body DataReaderArgs.

Declaration
public static Task<HTTPRequestResponse> Evaluate(WMPrincipal principal, WMAssetIdentifier identifier, HTTPRequestArgs args, WMAppDbContext context)
Parameters
Type Name Description
WMPrincipal principal
WMAssetIdentifier identifier
HTTPRequestArgs args
WMAppDbContext context
Returns
Type Description
Task<HTTPRequestResponse>

FromModel()

Create this instance by reading properties from the model.

Declaration
public override void FromModel()
Overrides
DataTransferObject<WMHTTPRequest>.FromModel()

Get(WMPrincipal, WMAssetIdentifier, WMAppDbContext?, Expression<Func<WMHTTPRequestDTO, WMHTTPRequestDTO>>)

Gets the WMHTTPRequestDTO instance with the specified id. Ensures ownership.

Declaration
public static Task<WMHTTPRequestDTO> Get(WMPrincipal principal, WMAssetIdentifier identifier, WMAppDbContext? context = null, Expression<Func<WMHTTPRequestDTO, WMHTTPRequestDTO>> propertySelector = null)
Parameters
Type Name Description
WMPrincipal principal
WMAssetIdentifier identifier

The identifier of the asset

WMAppDbContext context
Expression<Func<WMHTTPRequestDTO, WMHTTPRequestDTO>> propertySelector

An optional expression that allows additional mapping of the database DTO object to the instance DTO object. (i.e. excluding DocumentData and DocumentEditedText from WMDocumentDTO, which requires excessive time and bandwidth. An example of this can be found in Get(WMPrincipal, WMAssetIdentifier, WMAppDbContext?, Expression<Func<WMDocumentDTO, WMDocumentDTO>>))

Returns
Type Description
Task<WMHTTPRequestDTO>

GetFromDirectory(WMPrincipal, WMAssetIdentifier, int, WMAppDbContext, Expression<Func<WMHTTPRequestDTO, WMHTTPRequestDTO>>)

Gets a listing of the specified WMHTTPRequestDTO to the recursion depth specified with the ID/Dir of a WMAssetDirectory as input.

Declaration
public static Task<IEnumerable<WMHTTPRequestDTO>> GetFromDirectory(WMPrincipal principal, WMAssetIdentifier identifier = null, int recursionDepth = 0, WMAppDbContext context = null, Expression<Func<WMHTTPRequestDTO, WMHTTPRequestDTO>> propertySelector = null)
Parameters
Type Name Description
WMPrincipal principal

The owner of the assets being requested.

WMAssetIdentifier identifier

The identifier of the asset

int recursionDepth

Depth to which the directory subtrees under the specified directory should be traversed.

WMAppDbContext context

Optional reference to a WMAppDbContext instance.

Expression<Func<WMHTTPRequestDTO, WMHTTPRequestDTO>> propertySelector

An optional expression that allows additional mapping of the database DTO object to the instance DTO object. (i.e. excluding DocumentData and DocumentEditedText from WMDocumentDTO, which requires excessive time and bandwidth. An example of this can be found in Get(WMPrincipal, WMAssetIdentifier, WMAppDbContext?, Expression<Func<WMDocumentDTO, WMDocumentDTO>>))

Returns
Type Description
Task<IEnumerable<WMHTTPRequestDTO>>

ResourceDefinition()

The resource operation definition for this asset.

Declaration
public static WMResourceOperationsDefinition ResourceDefinition()
Returns
Type Description
WMResourceOperationsDefinition

Update(WMPrincipal, WMAssetIdentifier, WMHTTPRequestDTO, WMAppDbContext)

Updates the specified WMHTTPRequestDTO from the provided data.

Declaration
public static Task Update(WMPrincipal principal, WMAssetIdentifier identifier, WMHTTPRequestDTO a_dto, WMAppDbContext context)
Parameters
Type Name Description
WMPrincipal principal

The owner of the directory

WMAssetIdentifier identifier

The identifier of the asset

WMHTTPRequestDTO a_dto

The WMHTTPRequestDTO to be updated.

WMAppDbContext context

The DbContext

Returns
Type Description
Task
Exceptions
Type Condition
Exception

UpdateModel(WMPrincipal, DbContext, object[]?)

Updates and returns the contained model.

Declaration
public override Task<WMHTTPRequest> UpdateModel(WMPrincipal principal, DbContext context, object[]? data = null)
Parameters
Type Name Description
WMPrincipal principal
DbContext context
object[] data
Returns
Type Description
Task<WMHTTPRequest>
Overrides
WMAssetBaseDTO<WMHTTPRequest>.UpdateModel(WMPrincipal, DbContext, object[])

Versions(WMPrincipal, WMAssetIdentifier, WMAppDbContext)

Gets all versions of the specified asset.

Declaration
public static Task<IEnumerable<VersionArgs>> Versions(WMPrincipal principal, WMAssetIdentifier identifier, WMAppDbContext context)
Parameters
Type Name Description
WMPrincipal principal

The owner of the directory

WMAssetIdentifier identifier

The identifier of the directory

WMAppDbContext context

The DbContext

Returns
Type Description
Task<IEnumerable<VersionArgs>>
Exceptions
Type Condition
Exception

Implements

IWMAssetBaseDTO
IWMVersionableAsset
IWMOwnableResource
IWMResource
IDbEntity
IWMEntity
In this article
Back to top Copyright © 2025 Quantellia LLC.    Version 2.0.0 Revision 399     Last Updated 1/15/2025    DRAFT DOCUMENTATION. SUBJECT TO CHANGE