C# Class Sage.Modules.ModuleResult

Represents the result returned by a module after processing a request.
Datei anzeigen Open project: igorfrance/sage Class Usage Examples

Public Methods

Method Description
AppendDataElement ( XmlNode dataElement = null ) : XmlElement

Creates a mod:data element in the current module.

If this method is invoked with no arguments, a mod:data element will be created (if it doesn't exist in the current module) and the final mod:data element will be returned. If an element whose name is mod:data is supplied, if will either be appended to the current module (if the module doesn't have a mod:data element already) or it will replace the existing mod:data element if one exists already. The element that will be returned will be the appended copy of the specified dataElement.

AppendDataNode ( XmlNode dataNode = null ) : XmlNode

Creates a mod:data node in the current module.

If this method is invoked with no arguments, a mod:data element will be created (if it doesn't exist in the current module) and the final mod:data element will be returned. If an element whose name is mod:data is supplied, if will either be appended to the current module (if the module doesn't have a mod:data element already) or it will replace the existing mod:data element if one exists already. The node that will be returned will be the appended copy of the specified dataNode.

ModuleResult ( ModuleResultStatus status ) : System

Initializes a new instance of the ModuleResult class.

ModuleResult ( XmlElement resultElement, ModuleResultStatus status = ModuleResultStatus.Ok ) : System

Initializes a new instance of the ModuleResult class, using the specified status and resultElement.

Private Methods

Method Description
AppendOrPrependDataNode ( XmlNode dataNode, bool prepend ) : XmlNode

Method Details

AppendDataElement() public method

Creates a mod:data element in the current module.
If this method is invoked with no arguments, a mod:data element will be created (if it doesn't exist in the current module) and the final mod:data element will be returned. If an element whose name is mod:data is supplied, if will either be appended to the current module (if the module doesn't have a mod:data element already) or it will replace the existing mod:data element if one exists already. The element that will be returned will be the appended copy of the specified dataElement.
public AppendDataElement ( XmlNode dataElement = null ) : XmlElement
dataElement System.Xml.XmlNode Optional data element to add to the current module's element.
return System.Xml.XmlElement

AppendDataNode() public method

Creates a mod:data node in the current module.
If this method is invoked with no arguments, a mod:data element will be created (if it doesn't exist in the current module) and the final mod:data element will be returned. If an element whose name is mod:data is supplied, if will either be appended to the current module (if the module doesn't have a mod:data element already) or it will replace the existing mod:data element if one exists already. The node that will be returned will be the appended copy of the specified dataNode.
public AppendDataNode ( XmlNode dataNode = null ) : XmlNode
dataNode System.Xml.XmlNode Optional data node to add to the current module's element.
return System.Xml.XmlNode

ModuleResult() public method

Initializes a new instance of the ModuleResult class.
public ModuleResult ( ModuleResultStatus status ) : System
status ModuleResultStatus The status.
return System

ModuleResult() public method

Initializes a new instance of the ModuleResult class, using the specified status and resultElement.
public ModuleResult ( XmlElement resultElement, ModuleResultStatus status = ModuleResultStatus.Ok ) : System
resultElement System.Xml.XmlElement The content of this result.
status ModuleResultStatus The status of this result.
return System