C# Class Stumps.Server.ContractEntityBinding

A helper class that provides a translation between contracts and entities.
ファイルを表示 Open project: Cayan-LLC/stumps

Public Methods

Method Description
CreateContractFromEntity ( string serverId, StumpEntity entity, IDataAccess dataAccess ) : StumpContract

Creates a Stump contract from a Stump data entity.

CreateEntityFromContract ( StumpContract contract ) : StumpEntity

Creates a Stump data entity from a Stump contract.

Private Methods

Method Description
CreateNameValuePairFromHeaders ( IHttpHeaders headers ) : List

Creates a list of T:Stumps.Server.Data.NameValuePairEntity objects a T:Stumps.IHttpHeaders object.

Method Details

CreateContractFromEntity() public static method

Creates a Stump contract from a Stump data entity.
public static CreateContractFromEntity ( string serverId, StumpEntity entity, IDataAccess dataAccess ) : StumpContract
serverId string The unique identifier for the server.
entity Stumps.Server.Data.StumpEntity The used to create the contract.
dataAccess IDataAccess The data access provider used by the instance.
return StumpContract

CreateEntityFromContract() public static method

Creates a Stump data entity from a Stump contract.
public static CreateEntityFromContract ( StumpContract contract ) : StumpEntity
contract StumpContract The used to create the entity.
return Stumps.Server.Data.StumpEntity