1. Stylelabs.M.Framework.Essentials.LoadOptions

Class RelationSpecification

Specifies a relation.

Inheritance

object

RelationSpecification

Implements

IRelationSpecification

Namespace: StylelabsStylelabs.MStylelabs.M.FrameworkStylelabs.M.Framework.EssentialsLoadOptions

Assembly: Stylelabs.M.Sdk.dll

Syntax

public class RelationSpecification : IRelationSpecification

Constructors

RelationSpecification()

Initializes a new instance of the RelationSpecification class.

Declaration

public RelationSpecification()

RelationSpecification(IRelationSpecification)

Initializes a new instance of the RelationSpecification class.

Declaration

public RelationSpecification(IRelationSpecification spec)

Parameters

TypeNameDescription
IRelationSpecificationspecRelation specification.

RelationSpecification(string, RelationRole?)

Initializes a new instance of the RelationSpecification class with a specified name and optional role.

Declaration

public RelationSpecification(string name, RelationRole? role = null)

Parameters

TypeNameDescription
stringnameThe relation name.
RelationRoleroleThe relation role.

Properties

Name

Gets name of the relation (case insensitive).

Declaration

public string Name { get; set; }

Property Value

TypeDescription
string

Gets if the relation is self-referencing, which role to load. If it is null, both will be loaded into two separate relation objects.

Declaration

public RelationRole? Role { get; set; }

Property Value

TypeDescription
RelationRole

Methods

DeepClone()

Creates a deep clone of this instance.

Declaration

public IRelationSpecification DeepClone()

Returns

TypeDescription
IRelationSpecificationThe relation specification.

Equals(object)

Declaration

public override bool Equals(object obj)

Parameters

TypeNameDescription
objectobj

Returns

TypeDescription
bool

GetHashCode()

Declaration

public override int GetHashCode()

Returns

TypeDescription
int

Implements

IRelationSpecification

If you have suggestions for improving this article, let us know!