Click or drag to resize

PFApplicationRestHandlerPFApplicationType Class

Provides methods to handle requests of three types:

-Extended actions made to the item module. URLs follow this format: "RestItem/APPLICATION_NAME/CONTENTTYPE_NAME/ITEM_ID/ACTION_NAME/PARAMETER_1/PARAMETER_2/..."

-Actions not centered on a specific entity. URLs follow this format: "RestCustomAction/APPLICATION_NAME/ACTION_NAME/PARAMETER_1/PARAMETER_2/..."

-Requests made on a custom (not Packflow) resource. URLs follow this format: "RestCustomResource/APPLICATION_NAME/RESOURCE_NAME/PARAMETER_1/PARAMETER_2/..."

Posted values are available using a dedicated method.

This class is inherited in all applications for customization.

Inheritance Hierarchy
SystemObject
  Packflow.RestPFApplicationRestHandler
    Packflow.RestPFApplicationRestHandlerPFApplicationType

Namespace:  Packflow.Rest
Assembly:  MicaSystems.Packflow.Interface (in MicaSystems.Packflow.Interface.dll) Version: 1.0.0.0 (2.0.0.223)
Syntax
C#
public abstract class PFApplicationRestHandler<PFApplicationType> : PFApplicationRestHandler
where PFApplicationType : PFApplication

Type Parameters

PFApplicationType

The PFApplicationRestHandlerPFApplicationType type exposes the following members.

Constructors
Properties
  NameDescription
Public propertyApplication
Gets or sets the application.
Public propertyCustomHttpMethod
Gets the HTTP method text. Only filled if the used Http method is not listed by the RestHttpMethod enum.
(Inherited from PFApplicationRestHandler.)
Public propertyHttpMethod
Gets the HTTP method.
(Inherited from PFApplicationRestHandler.)
Public propertyRequest
Gets the request.
(Inherited from PFApplicationRestHandler.)
Public propertyRequestExpectsCamelCaseJson
Gets a (request parameter) value indicating if the returned JSON should follow camel case. Default value: false. Query string parameter name: "camelCase".
(Inherited from PFApplicationRestHandler.)
Public propertyRequestExpectsIgnoredNullValues
Gets a (request parameter) value indicating if the returned JSON should ignore null values. Default value: true. Query string parameter name: "ignoreNullValues".
(Inherited from PFApplicationRestHandler.)
Public propertyRequestExpectsPrettyJson
Gets a (request parameter) value indicating if the returned JSON should be indented. Default value: false. Query string parameter name: "pretty".
(Inherited from PFApplicationRestHandler.)
Public propertyResponse
Gets the response.
(Inherited from PFApplicationRestHandler.)
Top
Methods
  NameDescription
Protected methodGetPostedValue
Gets a posted parameter value.
(Inherited from PFApplicationRestHandler.)
Protected methodGetRequestBody
Gets the request body.
(Inherited from PFApplicationRestHandler.)
Protected methodGetSerializerSettings
Gets the serializer settings for JsonConvert (NewtonSoft).
(Inherited from PFApplicationRestHandler.)
Public methodHandleCustomActionRequest
Handles Rest requests for custom actions with an URL following the format

"RestCustomAction/APPLICATION_NAME/ACTION_NAME/PARAMETER_1/PARAMETER_2/..."

(Inherited from PFApplicationRestHandler.)
Public methodHandleCustomResourceRequest
Handles Rest requests for custom resources with an URL following the format

"RestCustomResource/APPLICATION_NAME/RESOURCE_NAME/PARAMETER_1/PARAMETER_2/..."

(Inherited from PFApplicationRestHandler.)
Public methodHandleItemCustomRequest
Handles Rest requests for custom actions on an item with an URL following the format

"RestItem/APPLICATION_NAME/CONTENTTYPE_NAME/ITEM_ID/ACTION_NAME/PARAMETER_1/PARAMETER_2/..."

(Inherited from PFApplicationRestHandler.)
Protected methodSerializeResult
Serializes an object (using JSON) to be returned in the response. Respects request parameters.
(Inherited from PFApplicationRestHandler.)
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Top
Extension Methods
  NameDescription
Public Extension MethodAsT
Casts an object to another type. Returns default(T) if the object is null.
(Defined by Utils_Other.)
Public Extension MethodEqualsAll
Checks that this object is equal to every object in parameters.
(Defined by Utils_Other.)
Public Extension MethodEqualsAny
Checks that this object is equal to at least one of the parameters.
(Defined by Utils_Other.)
Public Extension MethodGetString
Converts an object to String using ToString() method, else returns String.Empty.
(Defined by Utils_Other.)
Public Extension MethodIsGenericListOverloaded.
Checks if this object is a System.Collections.Generic.List.
(Defined by Utils_Linq.)
Public Extension MethodIsGenericList(Type)Overloaded.
Checks if this object is a System.Collections.Generic.List using type as T.
(Defined by Utils_Linq.)
Public Extension MethodSerializeOverloaded.
Serializes an object into an XML document.
(Defined by Utils_Xml.)
Public Extension MethodSerialize(String)Overloaded.
Serializes an object into an XML document.
(Defined by Utils_Xml.)
Public Extension MethodSerializeJsonOverloaded.
Serializes an object using a DataContractJsonSerializer.
(Defined by Utils_String.)
Public Extension MethodSerializeJson(ListType)Overloaded.
Serializes an object using a DataContractJsonSerializer.
(Defined by Utils_String.)
Public Extension MethodSerializeJson(DataContractJsonSerializerSettings)Overloaded.
Serializes an object using a DataContractJsonSerializer.
(Defined by Utils_String.)
Top
See Also