Click or drag to resize

CompositeResult Class

Multi type result used when a result set is a join
Inheritance Hierarchy
SystemObject
  SanteDB.OrmLiteCompositeResult
    SanteDB.OrmLiteCompositeResultTData1, TData2

Namespace: SanteDB.OrmLite
Assembly: SanteDB.OrmLite (in SanteDB.OrmLite.dll) Version: 3.0.2081-alpha+d0a78774d3f97b9193d2ae2fef6d129ea9f29519
Syntax
public abstract class CompositeResult

The CompositeResult type exposes the following members.

Constructors
 NameDescription
Protected methodCompositeResultInitializes a new instance of the CompositeResult class
Top
Properties
 NameDescription
Public propertyValues Gets or sets the values
Top
Methods
 NameDescription
Public methodEqualsDetermines whether the specified object is equal to the current object.
(Inherited from Object)
Protected methodFinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object)
Public methodGetHashCodeServes as the default hash function.
(Inherited from Object)
Public methodGetTypeGets the Type of the current instance.
(Inherited from Object)
Protected methodMemberwiseCloneCreates a shallow copy of the current Object.
(Inherited from Object)
Protected methodParseTData Parse the data
Public methodParseValues Parse values form the open rdr using the provider to populate this CompositeResult
Public methodToStringReturns a string that represents the current object.
(Inherited from Object)
Top
Extension Methods
 NameDescription
Public Extension MethodConvertTReturn The purpose of this method is to convert object me to TReturn. Why? Because if you have an instance of Act that actually needs to be a SubstanceAdministration we can't just cast so we have to copy.
(Defined by ExtensionMethods)
Public Extension MethodWithControl With control parameter is used as a wrapper for _ parameters
(Defined by QueryFilterExtensions)
Top
Remarks
A composite result is used when the caller is joining together data from multiple tables and would like the ORM result engine to load multiple types of objects from a single tuple
Example
C#
var sql = context.Provider.CreateSqlStatement<Table1>().SelectFrom(typeof(Table1), typeof(Table2))
    .InnerJoin<Table1, Table2>(o=>o.ForeignKey, o=>o.PrimaryKey);
var results = context.Query<CompositeResult<Table1, Table2>>(sql);
See Also