Table of Contents

TXDataAction Class

Represents a service operation, an endpoint that executes a method of a service contract.

Remarks

Each service operation belongs to a controller, which represents the service contract interface, and usually corresponds to one method of that interface. It defines the route, the HTTP method, the parameters and the return type of the endpoint.

Syntax

Unit: XData.Model.Classes

TXDataAction = class(TXDataModelObject);

Constructors

Name Description
Create Creates a service operation with no parameters, which responds to the POST method.

Methods

Name Description
BodyParamCount Returns the number of parameters read from the request body.
FindParameter Looks for a parameter by its name.
HasOutputParams Returns True if any parameter of the service operation is sent back in the response.
IndexOf Returns the position of a parameter in the parameter list.
IndexOfParameter Returns the position of a parameter in the parameter list, by its name.
IsFormContent Returns True if the service operation accepts a form-encoded request body.
IsJsonContent Returns True if the service operation accepts a JSON request body.
ParamStreamIndex Returns the position of the parameter that receives the raw request body.
PathParamCount Returns the number of parameters read from the URL path.
QueryParamCount Returns the number of parameters read from the URL query string.
RequiredPath​Param​Count Returns the number of path parameters that have no default value.

Properties

Name Description
BodyParams[Index] Gets a parameter read from the request body, by its index.
Consumes Gets or sets the content type of the request body accepted by the service operation.
Controller Gets the controller (service contract) the service operation belongs to.
HttpMethod Gets or sets the HTTP method the service operation responds to.
IsDeprecated Indicates whether the service operation is flagged as deprecated in the generated API documentation.
IsParamStream Indicates whether the service operation receives the raw request body as a stream.
IsResultCriteria Indicates whether the service operation returns an Aurelius Aurelius.​Criteria.​Base.​TCriteria.
IsResultSingleObject Indicates whether the service operation returns a single object.
IsResultStream Indicates whether the service operation returns a TStream.
Name Gets or sets the route of the service operation, relative to the route of its controller.
OperationId Gets or sets the identifier that uniquely identifies the service operation.
Parameters Gets all the parameters of the service operation.
PathParams[Index] Gets a parameter read from the URL path, by its index.
QueryParams[Index] Gets a parameter read from the URL query string, by its index.
Remarks Gets or sets the detailed description of the service operation in the generated API documentation.
ReturnType Gets or sets the type of the value returned by the service operation.
ReturnTypeRef Gets or sets the name of the return type, used when the model is written to or read from JSON.
RouteInfo Gets the full route of the service operation, including the route of its controller.