-
Notifications
You must be signed in to change notification settings - Fork 0
DiGi.Core.Relation.Classes
Represents an abstract many-to-many relationship between unique objects.
public abstract class ManyToManyRelation : DiGi.Core.Relation.Classes.ManyToManyRelation<DiGi.Core.Interfaces.IUniqueObject, DiGi.Core.Interfaces.IUniqueObject>Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → Relation → DiGi.Core.Relation.Classes.Relation<DiGi.Core.Interfaces.IUniqueObject,DiGi.Core.Interfaces.IUniqueObject> → DiGi.Core.Relation.Classes.ManyToManyRelation<DiGi.Core.Interfaces.IUniqueObject,DiGi.Core.Interfaces.IUniqueObject> → ManyToManyRelation
Creates a new instance of the ManyToManyRelation class by copying another instance.
public ManyToManyRelation(DiGi.Core.Relation.Classes.ManyToManyRelation? manyToManyRelation);manyToManyRelation ManyToManyRelation
The existing ManyToManyRelation instance to copy from.
Creates a new instance of the ManyToManyRelation class from unique objects.
public ManyToManyRelation(System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueObject>? uniqueObjects_From, System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueObject>? uniqueObjects_To);uniqueObjects_From System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueObject>
The collection of unique objects representing the source side of the relation.
uniqueObjects_To System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueObject>
The collection of unique objects representing the target side of the relation.
Creates a new instance of the ManyToManyRelation class from unique references.
public ManyToManyRelation(System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>? uniqueReferences_From, System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>? uniqueReferences_To);uniqueReferences_From System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>
The collection of unique references representing the source side of the relation.
uniqueReferences_To System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>
The collection of unique references representing the target side of the relation.
Creates a new instance of the ManyToManyRelation class from a JSON object.
public ManyToManyRelation(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to create the relation from.
Represents an abstract many-to-many relationship between two types of unique objects.
public abstract class ManyToManyRelation<From,To> : DiGi.Core.Relation.Classes.Relation<From, To>, DiGi.Core.Relation.Interfaces.IManyToManyRelation<From, To>, DiGi.Core.Relation.Interfaces.IManyToManyRelation, DiGi.Core.Relation.Interfaces.IRelation, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IObject, DiGi.Core.Relation.Interfaces.IRelation<From, To>
where From : DiGi.Core.Interfaces.IUniqueObject
where To : DiGi.Core.Interfaces.IUniqueObjectFrom
The type of the source objects in the relation.
To
The type of the destination objects in the relation.
Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → Relation → DiGi.Core.Relation.Classes.Relation<From,To> → ManyToManyRelation<From,To>
Derived
↳ ManyToManyRelation
Implements DiGi.Core.Relation.Interfaces.IManyToManyRelation<From,To>, IManyToManyRelation, IRelation, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IObject, DiGi.Core.Relation.Interfaces.IRelation<From,To>
Creates a new instance of the ManyToManyRelation class by copying another instance.
public ManyToManyRelation(DiGi.Core.Relation.Classes.ManyToManyRelation<From,To>? manyToManyRelation);manyToManyRelation DiGi.Core.Relation.Classes.ManyToManyRelation<From,To>
The existing relation instance to copy from.
Creates a new instance of the ManyToManyRelation class from unique references.
public ManyToManyRelation(System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>? uniqueReferences_From, System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>? uniqueReferences_To);uniqueReferences_From System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>
The collection of unique references from the source side.
uniqueReferences_To System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>
The collection of unique references from the destination side.
Creates a new instance of the ManyToManyRelation class from unique objects.
public ManyToManyRelation(System.Collections.Generic.IEnumerable<From>? uniqueObjects_From, System.Collections.Generic.IEnumerable<To>? uniqueObjects_To);uniqueObjects_From System.Collections.Generic.IEnumerable<From>
The collection of unique objects from the source side.
uniqueObjects_To System.Collections.Generic.IEnumerable<To>
The collection of unique objects from the destination side.
Creates a new instance of the ManyToManyRelation class from a JSON object.
public ManyToManyRelation(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to create the relation from.
Gets a list containing all unique references in this relation.
public override System.Collections.Generic.List<DiGi.Core.Interfaces.IUniqueReference>? UniqueReferences { get; }Implements UniqueReferences
System.Collections.Generic.List<DiGi.Core.Interfaces.IUniqueReference>
Gets a list of unique references on the "from" side of the relation.
public System.Collections.Generic.List<DiGi.Core.Interfaces.IUniqueReference>? UniqueReferences_From { get; }Implements UniqueReferences_From
System.Collections.Generic.List<DiGi.Core.Interfaces.IUniqueReference>
Gets a list of unique references on the "to" side of the relation.
public System.Collections.Generic.List<DiGi.Core.Interfaces.IUniqueReference>? UniqueReferences_To { get; }Implements UniqueReferences_To
System.Collections.Generic.List<DiGi.Core.Interfaces.IUniqueReference>
Adds a unique reference to the specified side of the relation.
public override bool Add(DiGi.Core.Relation.Enums.RelationSide relationSide, DiGi.Core.Interfaces.IUniqueReference? uniqueReference);relationSide RelationSide
The side of the relation where the reference should be added.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to add.
System.Boolean
True if the reference was successfully added; otherwise, false.
Determines whether the relation contains the specified unique reference on the given side.
public override bool Contains(DiGi.Core.Relation.Enums.RelationSide relationSide, DiGi.Core.Interfaces.IUniqueReference? uniqueReference);relationSide RelationSide
The side of the relation to check.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to locate in the relation.
Implements Contains(RelationSide, IUniqueReference)
System.Boolean
True if the relation contains the specified unique reference on the given side; otherwise, false.
Determines whether the relation has a reference on the specified side.
public override bool Has(DiGi.Core.Relation.Enums.RelationSide relationSide);relationSide RelationSide
The side of the relation to check.
Implements Has(RelationSide)
System.Boolean
True if the relation has a reference on the specified side; otherwise, false.
Removes a unique reference from the specified side of the relation.
public override bool Remove(DiGi.Core.Relation.Enums.RelationSide relationSide, DiGi.Core.Interfaces.IUniqueReference? uniqueReference);relationSide RelationSide
The side of the relation to remove the reference from.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to remove.
Implements Remove(RelationSide, IUniqueReference)
System.Boolean
True if the reference was successfully removed; otherwise, false.
ManyToManyRelation<From,To>.Remove<TUniqueReference>(RelationSide, IEnumerable<TUniqueReference>) Method
Removes multiple unique references from the specified side of the relation.
public override System.Collections.Generic.List<TUniqueReference>? Remove<TUniqueReference>(DiGi.Core.Relation.Enums.RelationSide relationSide, System.Collections.Generic.IEnumerable<TUniqueReference>? uniqueReferences)
where TUniqueReference : DiGi.Core.Interfaces.IUniqueReference;TUniqueReference
The type of the unique reference.
relationSide RelationSide
The side of the relation to remove references from.
uniqueReferences System.Collections.Generic.IEnumerable<TUniqueReference>
The collection of unique references to remove.
Implements Remove<TUniqueReference>(RelationSide, IEnumerable<TUniqueReference>)
System.Collections.Generic.List<TUniqueReference>
A list of removed unique references, or null if none were removed.
Represents an abstract many-to-one relationship between unique objects.
public abstract class ManyToOneRelation : DiGi.Core.Relation.Classes.ManyToOneRelation<DiGi.Core.Interfaces.IUniqueObject, DiGi.Core.Interfaces.IUniqueObject>Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → Relation → DiGi.Core.Relation.Classes.Relation<DiGi.Core.Interfaces.IUniqueObject,DiGi.Core.Interfaces.IUniqueObject> → DiGi.Core.Relation.Classes.ManyToOneRelation<DiGi.Core.Interfaces.IUniqueObject,DiGi.Core.Interfaces.IUniqueObject> → ManyToOneRelation
Creates a new instance of the ManyToOneRelation class by copying another instance.
public ManyToOneRelation(DiGi.Core.Relation.Classes.ManyToOneRelation? manyToOneRelation);manyToOneRelation ManyToOneRelation
The existing relation instance to copy from.
Creates a new instance of the ManyToOneRelation class from unique objects.
public ManyToOneRelation(System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueObject>? uniqueObjects_From, DiGi.Core.Interfaces.IUniqueObject? uniqueObject_To);uniqueObjects_From System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueObject>
The collection of unique objects representing the 'many' side of the relation.
uniqueObject_To DiGi.Core.Interfaces.IUniqueObject
The unique object representing the 'one' side of the relation.
Creates a new instance of the ManyToOneRelation class from unique references.
public ManyToOneRelation(System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>? uniqueReferences_From, DiGi.Core.Interfaces.IUniqueReference? uniqueReference_To);uniqueReferences_From System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>
The collection of unique references representing the 'many' side of the relation.
uniqueReference_To DiGi.Core.Interfaces.IUniqueReference
The unique reference representing the 'one' side of the relation.
Creates a new instance of the ManyToOneRelation class from a JSON object.
public ManyToOneRelation(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to create the relation from.
Represents an abstract many-to-one relationship between two types of unique objects.
public abstract class ManyToOneRelation<From,To> : DiGi.Core.Relation.Classes.Relation<From, To>, DiGi.Core.Relation.Interfaces.IManyToOneRelation<From, To>, DiGi.Core.Relation.Interfaces.IManyToOneRelation, DiGi.Core.Relation.Interfaces.IRelation, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IObject, DiGi.Core.Relation.Interfaces.IRelation<From, To>
where From : DiGi.Core.Interfaces.IUniqueObject
where To : DiGi.Core.Interfaces.IUniqueObjectFrom
The type of the unique objects on the 'many' side.
To
The type of the unique object on the 'one' side.
Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → Relation → DiGi.Core.Relation.Classes.Relation<From,To> → ManyToOneRelation<From,To>
Derived
↳ ManyToOneRelation
Implements DiGi.Core.Relation.Interfaces.IManyToOneRelation<From,To>, IManyToOneRelation, IRelation, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IObject, DiGi.Core.Relation.Interfaces.IRelation<From,To>
Creates a new instance of the ManyToOneRelation class by copying another instance.
public ManyToOneRelation(DiGi.Core.Relation.Classes.ManyToOneRelation<From,To>? manyToOneRelation);manyToOneRelation DiGi.Core.Relation.Classes.ManyToOneRelation<From,To>
The existing relation to copy from.
Creates a new instance of the ManyToOneRelation class from unique references.
public ManyToOneRelation(System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>? uniqueReferences_From, DiGi.Core.Interfaces.IUniqueReference? uniqueReference_To);uniqueReferences_From System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>
The collection of unique references on the 'many' side.
uniqueReference_To DiGi.Core.Interfaces.IUniqueReference
The unique reference on the 'one' side.
Creates a new instance of the ManyToOneRelation class from unique objects.
public ManyToOneRelation(System.Collections.Generic.IEnumerable<From>? uniqueObjects_From, To? uniqueObject_To);uniqueObjects_From System.Collections.Generic.IEnumerable<From>
The collection of unique objects on the 'many' side.
uniqueObject_To To
The unique object on the 'one' side.
Creates a new instance of the ManyToOneRelation class from a JSON object.
public ManyToOneRelation(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to create the relation from.
Gets a list containing all unique references in this relation.
public override System.Collections.Generic.List<DiGi.Core.Interfaces.IUniqueReference>? UniqueReferences { get; }Implements UniqueReferences
System.Collections.Generic.List<DiGi.Core.Interfaces.IUniqueReference>
Gets a list of unique references on the "from" side of the relation.
public System.Collections.Generic.List<DiGi.Core.Interfaces.IUniqueReference>? UniqueReferences_From { get; }Implements UniqueReferences_From
System.Collections.Generic.List<DiGi.Core.Interfaces.IUniqueReference>
Gets the unique reference to the target object.
public DiGi.Core.Interfaces.IUniqueReference? UniqueReference_To { get; }Implements UniqueReference_To
DiGi.Core.Interfaces.IUniqueReference
Adds a unique reference to the specified side of the relation.
public override bool Add(DiGi.Core.Relation.Enums.RelationSide relationSide, DiGi.Core.Interfaces.IUniqueReference? uniqueReference);relationSide RelationSide
The side of the relation to add the reference to.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to add.
System.Boolean
True if the reference was successfully added; otherwise, false.
Determines whether the relation contains the specified unique reference on the given side.
public override bool Contains(DiGi.Core.Relation.Enums.RelationSide relationSide, DiGi.Core.Interfaces.IUniqueReference? uniqueReference);relationSide RelationSide
The side of the relation to check.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to locate.
Implements Contains(RelationSide, IUniqueReference)
System.Boolean
True if the relation contains the specified unique reference on the given side; otherwise, false.
Determines whether the relation has a reference on the specified side.
public override bool Has(DiGi.Core.Relation.Enums.RelationSide relationSide);relationSide RelationSide
The side of the relation to check.
Implements Has(RelationSide)
System.Boolean
True if the relation has a reference on the specified side; otherwise, false.
Removes a unique reference from the specified side of the relation.
public override bool Remove(DiGi.Core.Relation.Enums.RelationSide relationSide, DiGi.Core.Interfaces.IUniqueReference? uniqueReference);relationSide RelationSide
The side of the relation to remove the reference from.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to remove.
Implements Remove(RelationSide, IUniqueReference)
System.Boolean
True if the reference was successfully removed; otherwise, false.
ManyToOneRelation<From,To>.Remove<TUniqueReference>(RelationSide, IEnumerable<TUniqueReference>) Method
Removes multiple unique references from the specified side of the relation.
public override System.Collections.Generic.List<TUniqueReference>? Remove<TUniqueReference>(DiGi.Core.Relation.Enums.RelationSide relationSide, System.Collections.Generic.IEnumerable<TUniqueReference>? uniqueReferences)
where TUniqueReference : DiGi.Core.Interfaces.IUniqueReference;TUniqueReference
The type of the unique reference.
relationSide RelationSide
The side of the relation to remove references from.
uniqueReferences System.Collections.Generic.IEnumerable<TUniqueReference>
The collection of unique references to remove.
Implements Remove<TUniqueReference>(RelationSide, IEnumerable<TUniqueReference>)
System.Collections.Generic.List<TUniqueReference>
A list of removed unique references, or null if none were removed.
Represents a bidirectional one-to-many relationship between unique objects.
public class OneToManyBidirectionalRelation : DiGi.Core.Relation.Classes.OneToManyBidirectionalRelation<DiGi.Core.Interfaces.IUniqueObject, DiGi.Core.Interfaces.IUniqueObject>Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → Relation → DiGi.Core.Relation.Classes.Relation<DiGi.Core.Interfaces.IUniqueObject,DiGi.Core.Interfaces.IUniqueObject> → DiGi.Core.Relation.Classes.OneToManyRelation<DiGi.Core.Interfaces.IUniqueObject,DiGi.Core.Interfaces.IUniqueObject> → DiGi.Core.Relation.Classes.OneToManyBidirectionalRelation<DiGi.Core.Interfaces.IUniqueObject,DiGi.Core.Interfaces.IUniqueObject> → OneToManyBidirectionalRelation
Creates a new instance of the OneToManyBidirectionalRelation class from unique references.
public OneToManyBidirectionalRelation(DiGi.Core.Classes.UniqueReference? uniqueReference_From, System.Collections.Generic.IEnumerable<DiGi.Core.Classes.UniqueReference>? uniqueReferences_To);uniqueReference_From DiGi.Core.Classes.UniqueReference
The unique reference for the 'from' side of the relation.
uniqueReferences_To System.Collections.Generic.IEnumerable<DiGi.Core.Classes.UniqueReference>
The collection of unique references for the 'to' side of the relation.
Creates a new instance of the OneToManyBidirectionalRelation class from unique objects.
public OneToManyBidirectionalRelation(DiGi.Core.Interfaces.IUniqueObject? uniqueObject_From, System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueObject>? uniqueObjects_To);uniqueObject_From DiGi.Core.Interfaces.IUniqueObject
The unique object for the 'from' side of the relation.
uniqueObjects_To System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueObject>
The collection of unique objects for the 'to' side of the relation.
Creates a new instance of the OneToManyBidirectionalRelation class by copying another instance.
public OneToManyBidirectionalRelation(DiGi.Core.Relation.Classes.OneToManyBidirectionalRelation? oneToManyBidirectionalRelation);oneToManyBidirectionalRelation OneToManyBidirectionalRelation
The existing relation instance to copy from.
Creates a new instance of the OneToManyBidirectionalRelation class from a JSON object.
public OneToManyBidirectionalRelation(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to create the relation from.
Represents a bidirectional one-to-many relationship between two types of unique objects.
public class OneToManyBidirectionalRelation<From,To> : DiGi.Core.Relation.Classes.OneToManyRelation<From, To>, DiGi.Core.Relation.Interfaces.IBidirectionalRelation<From, To>, DiGi.Core.Relation.Interfaces.IBidirectionalRelation, DiGi.Core.Relation.Interfaces.IRelation, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IObject, DiGi.Core.Relation.Interfaces.IRelation<From, To>
where From : DiGi.Core.Interfaces.IUniqueObject
where To : DiGi.Core.Interfaces.IUniqueObjectFrom
The type of the object on the 'one' side of the relation.
To
The type of the objects on the 'many' side of the relation.
Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → Relation → DiGi.Core.Relation.Classes.Relation<From,To> → DiGi.Core.Relation.Classes.OneToManyRelation<From,To> → OneToManyBidirectionalRelation<From,To>
Derived
↳ OneToManyBidirectionalRelation
Implements DiGi.Core.Relation.Interfaces.IBidirectionalRelation<From,To>, IBidirectionalRelation, IRelation, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IObject, DiGi.Core.Relation.Interfaces.IRelation<From,To>
Creates a new instance of the OneToManyBidirectionalRelation class from unique references.
public OneToManyBidirectionalRelation(DiGi.Core.Classes.UniqueReference? uniqueReference_From, System.Collections.Generic.IEnumerable<DiGi.Core.Classes.UniqueReference>? uniqueReferences_To);uniqueReference_From DiGi.Core.Classes.UniqueReference
The unique reference for the 'from' side of the relation.
uniqueReferences_To System.Collections.Generic.IEnumerable<DiGi.Core.Classes.UniqueReference>
The collection of unique references for the 'to' side of the relation.
Creates a new instance of the OneToManyBidirectionalRelation class by copying another instance.
public OneToManyBidirectionalRelation(DiGi.Core.Relation.Classes.OneToManyBidirectionalRelation<From,To>? oneToManyBidirectionalRelation);oneToManyBidirectionalRelation DiGi.Core.Relation.Classes.OneToManyBidirectionalRelation<From,To>
The existing relation instance to copy from.
Creates a new instance of the OneToManyBidirectionalRelation class from unique objects.
public OneToManyBidirectionalRelation(From? uniqueObject_From, System.Collections.Generic.IEnumerable<To>? uniqueObjects_To);uniqueObject_From From
The unique object for the 'from' side of the relation.
uniqueObjects_To System.Collections.Generic.IEnumerable<To>
The collection of unique objects for the 'to' side of the relation.
Creates a new instance of the OneToManyBidirectionalRelation class from a JSON object.
public OneToManyBidirectionalRelation(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to create the relation from.
Represents a one-to-many directional relationship between IUniqueObject instances.
public class OneToManyDirectionalRelation : DiGi.Core.Relation.Classes.OneToManyRelation<DiGi.Core.Interfaces.IUniqueObject, DiGi.Core.Interfaces.IUniqueObject>Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → Relation → DiGi.Core.Relation.Classes.Relation<DiGi.Core.Interfaces.IUniqueObject,DiGi.Core.Interfaces.IUniqueObject> → DiGi.Core.Relation.Classes.OneToManyRelation<DiGi.Core.Interfaces.IUniqueObject,DiGi.Core.Interfaces.IUniqueObject> → OneToManyDirectionalRelation
Creates a new instance from unique references.
public OneToManyDirectionalRelation(DiGi.Core.Classes.UniqueReference? uniqueReference_From, System.Collections.Generic.IEnumerable<DiGi.Core.Classes.UniqueReference>? uniqueReferences_To);uniqueReference_From DiGi.Core.Classes.UniqueReference
The source unique reference.
uniqueReferences_To System.Collections.Generic.IEnumerable<DiGi.Core.Classes.UniqueReference>
The collection of destination unique references.
Creates a new instance from unique objects.
public OneToManyDirectionalRelation(DiGi.Core.Interfaces.IUniqueObject? uniqueObject_From, System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueObject>? uniqueObjects_To);uniqueObject_From DiGi.Core.Interfaces.IUniqueObject
The source unique object.
uniqueObjects_To System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueObject>
The collection of destination unique objects.
Creates a new instance by copying another instance.
public OneToManyDirectionalRelation(DiGi.Core.Relation.Classes.OneToManyDirectionalRelation? oneToManyDirectionalRelation);oneToManyDirectionalRelation OneToManyDirectionalRelation
The existing relation to copy from.
Creates a new instance from a JSON object.
public OneToManyDirectionalRelation(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to create the instance from.
One To One Directional Relation
public class OneToManyDirectionalRelation<XUniqueObject,YUniqueObject> : DiGi.Core.Relation.Classes.OneToManyRelation<XUniqueObject, YUniqueObject>, DiGi.Core.Relation.Interfaces.IDirectionalRelation<XUniqueObject, YUniqueObject>, DiGi.Core.Relation.Interfaces.IDirectionalRelation, DiGi.Core.Relation.Interfaces.IRelation, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IObject, DiGi.Core.Relation.Interfaces.IRelation<XUniqueObject, YUniqueObject>
where XUniqueObject : DiGi.Core.Interfaces.IUniqueObject
where YUniqueObject : DiGi.Core.Interfaces.IUniqueObjectXUniqueObject
Parent Unique Object
YUniqueObject
Related Unique Object
Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → Relation → DiGi.Core.Relation.Classes.Relation<XUniqueObject,YUniqueObject> → DiGi.Core.Relation.Classes.OneToManyRelation<XUniqueObject,YUniqueObject> → OneToManyDirectionalRelation<XUniqueObject,YUniqueObject>
Implements DiGi.Core.Relation.Interfaces.IDirectionalRelation<XUniqueObject,YUniqueObject>, IDirectionalRelation, IRelation, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IObject, DiGi.Core.Relation.Interfaces.IRelation<XUniqueObject,YUniqueObject>
Creates a new instance from unique references.
public OneToManyDirectionalRelation(DiGi.Core.Classes.UniqueReference? uniqueReference_From, System.Collections.Generic.IEnumerable<DiGi.Core.Classes.UniqueReference>? uniqueReferences_To);uniqueReference_From DiGi.Core.Classes.UniqueReference
The source unique reference.
uniqueReferences_To System.Collections.Generic.IEnumerable<DiGi.Core.Classes.UniqueReference>
The collection of destination unique references.
Creates a new instance by copying another instance.
public OneToManyDirectionalRelation(DiGi.Core.Relation.Classes.OneToManyDirectionalRelation<XUniqueObject,YUniqueObject>? oneToManyDirectionalRelation);oneToManyDirectionalRelation DiGi.Core.Relation.Classes.OneToManyDirectionalRelation<XUniqueObject,YUniqueObject>
The existing relation to copy from.
Creates a new instance from a JSON object.
public OneToManyDirectionalRelation(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to create the instance from.
Creates a new instance from unique objects.
public OneToManyDirectionalRelation(XUniqueObject? uniqueObject_From, System.Collections.Generic.IEnumerable<YUniqueObject>? uniqueObjects_To);uniqueObject_From XUniqueObject
The source unique object.
uniqueObjects_To System.Collections.Generic.IEnumerable<YUniqueObject>
The collection of destination unique objects.
Represents an abstract one-to-many relationship between unique objects.
public abstract class OneToManyRelation : DiGi.Core.Relation.Classes.OneToManyRelation<DiGi.Core.Interfaces.IUniqueObject, DiGi.Core.Interfaces.IUniqueObject>Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → Relation → DiGi.Core.Relation.Classes.Relation<DiGi.Core.Interfaces.IUniqueObject,DiGi.Core.Interfaces.IUniqueObject> → DiGi.Core.Relation.Classes.OneToManyRelation<DiGi.Core.Interfaces.IUniqueObject,DiGi.Core.Interfaces.IUniqueObject> → OneToManyRelation
Creates a new instance of the OneToManyRelation class from unique objects.
public OneToManyRelation(DiGi.Core.Interfaces.IUniqueObject? uniqueObject_From, System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueObject>? uniqueObjects_To);uniqueObject_From DiGi.Core.Interfaces.IUniqueObject
The source unique object.
uniqueObjects_To System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueObject>
The collection of destination unique objects.
Creates a new instance of the OneToManyRelation class from unique references.
public OneToManyRelation(DiGi.Core.Interfaces.IUniqueReference? uniqueReference_From, System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>? uniqueReferences_To);uniqueReference_From DiGi.Core.Interfaces.IUniqueReference
The source unique reference.
uniqueReferences_To System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>
The collection of destination unique references.
Creates a new instance of the OneToManyRelation class by copying another instance.
public OneToManyRelation(DiGi.Core.Relation.Classes.OneToManyRelation? oneToManyRelation);oneToManyRelation OneToManyRelation
The existing relation to copy from.
Creates a new instance of the OneToManyRelation class from a JSON object.
public OneToManyRelation(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to create the relation from.
Represents an abstract one-to-many relationship between two types of unique objects.
public abstract class OneToManyRelation<From,To> : DiGi.Core.Relation.Classes.Relation<From, To>, DiGi.Core.Relation.Interfaces.IOneToManyRelation<From, To>, DiGi.Core.Relation.Interfaces.IOneToManyRelation, DiGi.Core.Relation.Interfaces.IRelation, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IObject, DiGi.Core.Relation.Interfaces.IRelation<From, To>
where From : DiGi.Core.Interfaces.IUniqueObject
where To : DiGi.Core.Interfaces.IUniqueObjectFrom
The type of the object on the 'one' side of the relation.
To
The type of the objects on the 'many' side of the relation.
Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → Relation → DiGi.Core.Relation.Classes.Relation<From,To> → OneToManyRelation<From,To>
Derived
↳ OneToManyBidirectionalRelation<From,To>
↳ OneToManyDirectionalRelation
↳ OneToManyDirectionalRelation<XUniqueObject,YUniqueObject>
↳ OneToManyRelation
Implements DiGi.Core.Relation.Interfaces.IOneToManyRelation<From,To>, IOneToManyRelation, IRelation, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IObject, DiGi.Core.Relation.Interfaces.IRelation<From,To>
Creates a new instance of the OneToManyRelation class from unique references.
public OneToManyRelation(DiGi.Core.Interfaces.IUniqueReference? uniqueReference_From, System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>? uniqueReferences_To);uniqueReference_From DiGi.Core.Interfaces.IUniqueReference
The unique reference for the single side of the relationship.
uniqueReferences_To System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>
The collection of unique references for the many side of the relationship.
Creates a new instance of the OneToManyRelation class by copying another instance.
public OneToManyRelation(DiGi.Core.Relation.Classes.OneToManyRelation<From,To>? oneToManyRelation);oneToManyRelation DiGi.Core.Relation.Classes.OneToManyRelation<From,To>
The source relation instance to copy.
Creates a new instance of the OneToManyRelation class from unique objects.
public OneToManyRelation(From? uniqueObject_From, System.Collections.Generic.IEnumerable<To>? uniqueObjects_To);uniqueObject_From From
The unique object for the single side of the relationship.
uniqueObjects_To System.Collections.Generic.IEnumerable<To>
The collection of unique objects for the many side of the relationship.
Creates a new instance of the OneToManyRelation class from a JSON object.
public OneToManyRelation(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to initialize the relation from.
Gets a list containing all unique references in this relation.
public override System.Collections.Generic.List<DiGi.Core.Interfaces.IUniqueReference>? UniqueReferences { get; }Implements UniqueReferences
System.Collections.Generic.List<DiGi.Core.Interfaces.IUniqueReference>
Gets a list of unique references on the "to" side of the relation.
public System.Collections.Generic.List<DiGi.Core.Interfaces.IUniqueReference>? UniqueReferences_To { get; }Implements UniqueReferences_To
System.Collections.Generic.List<DiGi.Core.Interfaces.IUniqueReference>
Gets the unique reference from the source object.
public DiGi.Core.Interfaces.IUniqueReference? UniqueReference_From { get; }Implements UniqueReference_From
DiGi.Core.Interfaces.IUniqueReference
Adds a unique reference to the specified side of the relation.
public override bool Add(DiGi.Core.Relation.Enums.RelationSide relationSide, DiGi.Core.Interfaces.IUniqueReference? uniqueReference);relationSide RelationSide
The side of the relation to add the reference to.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to add.
System.Boolean
True if the reference was successfully added; otherwise, false.
Determines whether the relation contains the specified unique reference on the given side.
public override bool Contains(DiGi.Core.Relation.Enums.RelationSide relationSide, DiGi.Core.Interfaces.IUniqueReference? uniqueReference);relationSide RelationSide
The side of the relation to check.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to locate in the relation.
Implements Contains(RelationSide, IUniqueReference)
System.Boolean
True if the relation contains the specified unique reference on the given side; otherwise, false.
Determines whether the relation has a reference on the specified side.
public override bool Has(DiGi.Core.Relation.Enums.RelationSide relationSide);relationSide RelationSide
The side of the relation to check.
Implements Has(RelationSide)
System.Boolean
True if the relation has a reference on the specified side; otherwise, false.
Removes a unique reference from the specified side of the relation.
public override bool Remove(DiGi.Core.Relation.Enums.RelationSide relationSide, DiGi.Core.Interfaces.IUniqueReference? uniqueReference);relationSide RelationSide
The side of the relation to remove the reference from.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to remove.
Implements Remove(RelationSide, IUniqueReference)
System.Boolean
True if the reference was successfully removed; otherwise, false.
OneToManyRelation<From,To>.Remove<TUniqueReference>(RelationSide, IEnumerable<TUniqueReference>) Method
Removes multiple unique references from the specified side of the relation.
public override System.Collections.Generic.List<TUniqueReference>? Remove<TUniqueReference>(DiGi.Core.Relation.Enums.RelationSide relationSide, System.Collections.Generic.IEnumerable<TUniqueReference>? uniqueReferences)
where TUniqueReference : DiGi.Core.Interfaces.IUniqueReference;TUniqueReference
The type of the unique reference.
relationSide RelationSide
The side of the relation to remove references from.
uniqueReferences System.Collections.Generic.IEnumerable<TUniqueReference>
The collection of unique references to remove.
Implements Remove<TUniqueReference>(RelationSide, IEnumerable<TUniqueReference>)
System.Collections.Generic.List<TUniqueReference>
A list of removed unique references, or null if no references were removed.
Represents a bidirectional one-to-one relationship between two IUniqueObject instances.
public class OneToOneBidirectionalRelation : DiGi.Core.Relation.Classes.OneToOneBidirectionalRelation<DiGi.Core.Interfaces.IUniqueObject, DiGi.Core.Interfaces.IUniqueObject>Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → Relation → DiGi.Core.Relation.Classes.Relation<DiGi.Core.Interfaces.IUniqueObject,DiGi.Core.Interfaces.IUniqueObject> → DiGi.Core.Relation.Classes.OneToOneRelation<DiGi.Core.Interfaces.IUniqueObject,DiGi.Core.Interfaces.IUniqueObject> → DiGi.Core.Relation.Classes.OneToOneBidirectionalRelation<DiGi.Core.Interfaces.IUniqueObject,DiGi.Core.Interfaces.IUniqueObject> → OneToOneBidirectionalRelation
Creates a new instance of the OneToOneBidirectionalRelation class from unique objects.
public OneToOneBidirectionalRelation(DiGi.Core.Interfaces.IUniqueObject? uniqueObject_From, DiGi.Core.Interfaces.IUniqueObject? uniqueObject_To);uniqueObject_From DiGi.Core.Interfaces.IUniqueObject
The source unique object.
uniqueObject_To DiGi.Core.Interfaces.IUniqueObject
The destination unique object.
Creates a new instance of the OneToOneBidirectionalRelation class from unique references.
public OneToOneBidirectionalRelation(DiGi.Core.Interfaces.IUniqueReference? uniqueReference_From, DiGi.Core.Interfaces.IUniqueReference? uniqueReference_To);uniqueReference_From DiGi.Core.Interfaces.IUniqueReference
The source unique reference.
uniqueReference_To DiGi.Core.Interfaces.IUniqueReference
The destination unique reference.
Creates a new instance of the OneToOneBidirectionalRelation class by copying another instance.
public OneToOneBidirectionalRelation(DiGi.Core.Relation.Classes.OneToOneBidirectionalRelation? oneToOneBidirectionalRelation);oneToOneBidirectionalRelation OneToOneBidirectionalRelation
The existing relation to copy from.
Creates a new instance of the OneToOneBidirectionalRelation class from a JSON object.
public OneToOneBidirectionalRelation(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to create the relation from.
Represents a bidirectional one-to-one relationship between two unique object instances.
public class OneToOneBidirectionalRelation<From,To> : DiGi.Core.Relation.Classes.OneToOneRelation<From, To>, DiGi.Core.Relation.Interfaces.IBidirectionalRelation<From, To>, DiGi.Core.Relation.Interfaces.IBidirectionalRelation, DiGi.Core.Relation.Interfaces.IRelation, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IObject, DiGi.Core.Relation.Interfaces.IRelation<From, To>
where From : DiGi.Core.Interfaces.IUniqueObject
where To : DiGi.Core.Interfaces.IUniqueObjectFrom
The type of the source object.
To
The type of the destination object.
Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → Relation → DiGi.Core.Relation.Classes.Relation<From,To> → DiGi.Core.Relation.Classes.OneToOneRelation<From,To> → OneToOneBidirectionalRelation<From,To>
Derived
↳ OneToOneBidirectionalRelation
Implements DiGi.Core.Relation.Interfaces.IBidirectionalRelation<From,To>, IBidirectionalRelation, IRelation, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IObject, DiGi.Core.Relation.Interfaces.IRelation<From,To>
Creates a new instance of the OneToOneBidirectionalRelation class from unique references.
public OneToOneBidirectionalRelation(DiGi.Core.Interfaces.IUniqueReference? uniqueReference_From, DiGi.Core.Interfaces.IUniqueReference? uniqueReference_To);uniqueReference_From DiGi.Core.Interfaces.IUniqueReference
The source unique reference.
uniqueReference_To DiGi.Core.Interfaces.IUniqueReference
The destination unique reference.
Creates a new instance of the OneToOneBidirectionalRelation class by copying another instance.
public OneToOneBidirectionalRelation(DiGi.Core.Relation.Classes.OneToOneBidirectionalRelation<From,To>? oneToOneBidirectionalRelation);oneToOneBidirectionalRelation DiGi.Core.Relation.Classes.OneToOneBidirectionalRelation<From,To>
The existing relation to copy from.
Creates a new instance of the OneToOneBidirectionalRelation class from unique objects.
public OneToOneBidirectionalRelation(From? uniqueObject_From, To? uniqueObject_To);uniqueObject_From From
The source unique object.
uniqueObject_To To
The destination unique object.
Creates a new instance of the OneToOneBidirectionalRelation class from a JSON object.
public OneToOneBidirectionalRelation(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to create the relation from.
Represents a one-to-one directional relationship between IUniqueObject instances.
public class OneToOneDirectionalRelation : DiGi.Core.Relation.Classes.OneToOneRelation<DiGi.Core.Interfaces.IUniqueObject, DiGi.Core.Interfaces.IUniqueObject>Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → Relation → DiGi.Core.Relation.Classes.Relation<DiGi.Core.Interfaces.IUniqueObject,DiGi.Core.Interfaces.IUniqueObject> → DiGi.Core.Relation.Classes.OneToOneRelation<DiGi.Core.Interfaces.IUniqueObject,DiGi.Core.Interfaces.IUniqueObject> → OneToOneDirectionalRelation
Creates a new instance from unique references.
public OneToOneDirectionalRelation(DiGi.Core.Classes.UniqueReference? uniqueReference_From, DiGi.Core.Classes.UniqueReference? uniqueReference_To);uniqueReference_From DiGi.Core.Classes.UniqueReference
The source unique reference.
uniqueReference_To DiGi.Core.Classes.UniqueReference
The destination unique reference.
Creates a new instance from unique objects.
public OneToOneDirectionalRelation(DiGi.Core.Interfaces.IUniqueObject? uniqueObject_From, DiGi.Core.Interfaces.IUniqueObject? uniqueObject_To);uniqueObject_From DiGi.Core.Interfaces.IUniqueObject
The source unique object.
uniqueObject_To DiGi.Core.Interfaces.IUniqueObject
The destination unique object.
Creates a new instance by copying another instance.
public OneToOneDirectionalRelation(DiGi.Core.Relation.Classes.OneToOneDirectionalRelation? oneToOneDirectionalRelation);oneToOneDirectionalRelation OneToOneDirectionalRelation
The relation instance to copy from.
Creates a new instance from a JSON object.
public OneToOneDirectionalRelation(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to create the instance from.
Creates a shallow copy of this relation.
public override DiGi.Core.Interfaces.ISerializableObject Clone();Implements Clone()
DiGi.Core.Interfaces.ISerializableObject
A shallow copy of the current relation as an DiGi.Core.Interfaces.ISerializableObject.
One To One Directional Relation
public class OneToOneDirectionalRelation<XUniqueObject,YUniqueObject> : DiGi.Core.Relation.Classes.OneToOneRelation<XUniqueObject, YUniqueObject>, DiGi.Core.Relation.Interfaces.IDirectionalRelation<XUniqueObject, YUniqueObject>, DiGi.Core.Relation.Interfaces.IDirectionalRelation, DiGi.Core.Relation.Interfaces.IRelation, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IObject, DiGi.Core.Relation.Interfaces.IRelation<XUniqueObject, YUniqueObject>
where XUniqueObject : DiGi.Core.Interfaces.IUniqueObject
where YUniqueObject : DiGi.Core.Interfaces.IUniqueObjectXUniqueObject
Parent Unique Object
YUniqueObject
Related Unique Object
Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → Relation → DiGi.Core.Relation.Classes.Relation<XUniqueObject,YUniqueObject> → DiGi.Core.Relation.Classes.OneToOneRelation<XUniqueObject,YUniqueObject> → OneToOneDirectionalRelation<XUniqueObject,YUniqueObject>
Implements DiGi.Core.Relation.Interfaces.IDirectionalRelation<XUniqueObject,YUniqueObject>, IDirectionalRelation, IRelation, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IObject, DiGi.Core.Relation.Interfaces.IRelation<XUniqueObject,YUniqueObject>
Creates a new instance from unique references.
public OneToOneDirectionalRelation(DiGi.Core.Classes.UniqueReference? uniqueReference_From, DiGi.Core.Classes.UniqueReference? uniqueReference_To);uniqueReference_From DiGi.Core.Classes.UniqueReference
The source unique reference.
uniqueReference_To DiGi.Core.Classes.UniqueReference
The destination unique reference.
Creates a new instance by copying another instance.
public OneToOneDirectionalRelation(DiGi.Core.Relation.Classes.OneToOneDirectionalRelation<XUniqueObject,YUniqueObject>? oneToOneDirectionalRelation);oneToOneDirectionalRelation DiGi.Core.Relation.Classes.OneToOneDirectionalRelation<XUniqueObject,YUniqueObject>
The relation instance to copy from.
Creates a new instance from a JSON object.
public OneToOneDirectionalRelation(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to create the instance from.
Creates a new instance from unique objects.
public OneToOneDirectionalRelation(XUniqueObject? uniqueObject_From, YUniqueObject? uniqueObject_To);uniqueObject_From XUniqueObject
The source unique object.
uniqueObject_To YUniqueObject
The destination unique object.
Represents a one-to-one relationship between two IUniqueObject instances.
public abstract class OneToOneRelation : DiGi.Core.Relation.Classes.OneToOneRelation<DiGi.Core.Interfaces.IUniqueObject, DiGi.Core.Interfaces.IUniqueObject>Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → Relation → DiGi.Core.Relation.Classes.Relation<DiGi.Core.Interfaces.IUniqueObject,DiGi.Core.Interfaces.IUniqueObject> → DiGi.Core.Relation.Classes.OneToOneRelation<DiGi.Core.Interfaces.IUniqueObject,DiGi.Core.Interfaces.IUniqueObject> → OneToOneRelation
Creates a new instance of the OneToOneRelation class from unique references.
public OneToOneRelation(DiGi.Core.Classes.UniqueReference? uniqueReference_From, DiGi.Core.Classes.UniqueReference? uniqueReference_To);uniqueReference_From DiGi.Core.Classes.UniqueReference
The source unique reference for the relation.
uniqueReference_To DiGi.Core.Classes.UniqueReference
The destination unique reference for the relation.
Creates a new instance of the OneToOneRelation class from unique objects.
public OneToOneRelation(DiGi.Core.Interfaces.IUniqueObject? uniqueObject_From, DiGi.Core.Interfaces.IUniqueObject? uniqueObject_To);uniqueObject_From DiGi.Core.Interfaces.IUniqueObject
The source unique object for the relation.
uniqueObject_To DiGi.Core.Interfaces.IUniqueObject
The destination unique object for the relation.
Creates a new instance of the OneToOneRelation class by copying another instance.
public OneToOneRelation(DiGi.Core.Relation.Classes.OneToOneRelation? oneToOneRelation);oneToOneRelation OneToOneRelation
The existing OneToOneRelation instance to copy from.
Creates a new instance of the OneToOneRelation class from a JSON object.
public OneToOneRelation(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object used to initialize the relation.
Represents a one-to-one relationship between two unique object instances.
public abstract class OneToOneRelation<From,To> : DiGi.Core.Relation.Classes.Relation<From, To>, DiGi.Core.Relation.Interfaces.IOneToOneRelation<From, To>, DiGi.Core.Relation.Interfaces.IOneToOneRelation, DiGi.Core.Relation.Interfaces.IRelation, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IObject, DiGi.Core.Relation.Interfaces.IRelation<From, To>
where From : DiGi.Core.Interfaces.IUniqueObject
where To : DiGi.Core.Interfaces.IUniqueObjectFrom
The type of the source object.
To
The type of the target object.
Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → Relation → DiGi.Core.Relation.Classes.Relation<From,To> → OneToOneRelation<From,To>
Derived
↳ OneToOneBidirectionalRelation<From,To>
↳ OneToOneDirectionalRelation
↳ OneToOneDirectionalRelation<XUniqueObject,YUniqueObject>
↳ OneToOneRelation
Implements DiGi.Core.Relation.Interfaces.IOneToOneRelation<From,To>, IOneToOneRelation, IRelation, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IObject, DiGi.Core.Relation.Interfaces.IRelation<From,To>
Creates a new instance of the OneToOneRelation class from unique references.
public OneToOneRelation(DiGi.Core.Interfaces.IUniqueReference? uniqueReference_From, DiGi.Core.Interfaces.IUniqueReference? uniqueReference_To);uniqueReference_From DiGi.Core.Interfaces.IUniqueReference
The source unique reference.
uniqueReference_To DiGi.Core.Interfaces.IUniqueReference
The target unique reference.
Creates a new instance of the OneToOneRelation class by copying another instance.
public OneToOneRelation(DiGi.Core.Relation.Classes.OneToOneRelation<From,To>? oneToOneRelation);oneToOneRelation DiGi.Core.Relation.Classes.OneToOneRelation<From,To>
The existing relation to copy from.
Creates a new instance of the OneToOneRelation class from unique objects.
public OneToOneRelation(From? uniqueObject_From, To? uniqueObject_To);uniqueObject_From From
The source unique object.
uniqueObject_To To
The target unique object.
Creates a new instance of the OneToOneRelation class from a JSON object.
public OneToOneRelation(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to create the relation from.
Gets a list containing all unique references in this relation.
public override System.Collections.Generic.List<DiGi.Core.Interfaces.IUniqueReference>? UniqueReferences { get; }Implements UniqueReferences
System.Collections.Generic.List<DiGi.Core.Interfaces.IUniqueReference>
Gets the unique reference from the source object.
public DiGi.Core.Interfaces.IUniqueReference? UniqueReference_From { get; }Implements UniqueReference_From
DiGi.Core.Interfaces.IUniqueReference
Gets the unique reference to the target object.
public DiGi.Core.Interfaces.IUniqueReference? UniqueReference_To { get; }Implements UniqueReference_To
DiGi.Core.Interfaces.IUniqueReference
Adds a unique reference to the specified side of the relation.
public override bool Add(DiGi.Core.Relation.Enums.RelationSide relationSide, DiGi.Core.Interfaces.IUniqueReference? uniqueReference);relationSide RelationSide
The side of the relation to add the reference to.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to add.
System.Boolean
True if the reference was successfully added; otherwise, false.
Determines whether the relation contains the specified unique reference on the given side.
public override bool Contains(DiGi.Core.Relation.Enums.RelationSide relationSide, DiGi.Core.Interfaces.IUniqueReference? uniqueReference);relationSide RelationSide
The side of the relation to check.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to locate.
Implements Contains(RelationSide, IUniqueReference)
System.Boolean
True if the relation contains the specified unique reference on the given side; otherwise, false.
Determines whether the relation has a reference on the specified side.
public override bool Has(DiGi.Core.Relation.Enums.RelationSide relationSide);relationSide RelationSide
The side of the relation to check.
Implements Has(RelationSide)
System.Boolean
True if the relation has a reference on the specified side; otherwise, false.
Removes a unique reference from the specified side of the relation.
public override bool Remove(DiGi.Core.Relation.Enums.RelationSide relationSide, DiGi.Core.Interfaces.IUniqueReference? uniqueReference);relationSide RelationSide
The side of the relation to remove the reference from.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to remove.
Implements Remove(RelationSide, IUniqueReference)
System.Boolean
True if the reference was successfully removed; otherwise, false.
OneToOneRelation<From,To>.Remove<TUniqueReference>(RelationSide, IEnumerable<TUniqueReference>) Method
Removes multiple unique references from the specified side of the relation.
public override System.Collections.Generic.List<TUniqueReference>? Remove<TUniqueReference>(DiGi.Core.Relation.Enums.RelationSide relationSide, System.Collections.Generic.IEnumerable<TUniqueReference>? uniqueReferences)
where TUniqueReference : DiGi.Core.Interfaces.IUniqueReference;TUniqueReference
The type of the unique reference.
relationSide RelationSide
The side of the relation to remove references from.
uniqueReferences System.Collections.Generic.IEnumerable<TUniqueReference>
The collection of unique references to remove.
Implements Remove<TUniqueReference>(RelationSide, IEnumerable<TUniqueReference>)
System.Collections.Generic.List<TUniqueReference>
A list of removed unique references, or null if none were removed.
Represents an abstract relationship between unique objects.
public abstract class Relation : DiGi.Core.Classes.SerializableObject, DiGi.Core.Relation.Interfaces.IRelation, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IObjectInheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → Relation
Derived
↳ Relation<From,To>
Implements IRelation, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IObject
Creates a new instance of the Relation class.
public Relation();Creates a new instance of the Relation class by copying another instance.
public Relation(DiGi.Core.Relation.Classes.Relation? relation);relation Relation
The relation instance to copy from.
Creates a new instance of the Relation class from a JSON object.
public Relation(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to create the relation from.
Gets a list containing all unique references in this relation.
public abstract System.Collections.Generic.List<DiGi.Core.Interfaces.IUniqueReference>? UniqueReferences { get; }Implements UniqueReferences
System.Collections.Generic.List<DiGi.Core.Interfaces.IUniqueReference>
Adds a unique reference to the specified side of the relation.
public abstract bool Add(DiGi.Core.Relation.Enums.RelationSide relationSide, DiGi.Core.Interfaces.IUniqueReference? uniqueReference);relationSide RelationSide
The side of the relation where the reference should be added.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to add.
System.Boolean
True if the reference was successfully added; otherwise, false.
Determines whether the relation contains the specified unique reference on the given side.
public abstract bool Contains(DiGi.Core.Relation.Enums.RelationSide relationSide, DiGi.Core.Interfaces.IUniqueReference? uniqueReference);relationSide RelationSide
The side of the relation to search.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to locate within the relation.
Implements Contains(RelationSide, IUniqueReference)
System.Boolean
True if the specified unique reference is found on the given side; otherwise, false.
Gets the type of the object on the specified side of the relation.
public abstract System.Type? GetType(DiGi.Core.Relation.Enums.RelationSide relationSide);relationSide RelationSide
The side of the relation to retrieve the type for.
Implements GetType(RelationSide)
System.Type
The type of the object on the specified side, or null if no type is associated with that side.
Determines whether the relation has a reference on the specified side.
public abstract bool Has(DiGi.Core.Relation.Enums.RelationSide relationSide);relationSide RelationSide
The side of the relation to check for a reference.
Implements Has(RelationSide)
System.Boolean
True if the relation has a reference on the specified side; otherwise, false.
Removes a unique reference from the specified side of the relation.
public abstract bool Remove(DiGi.Core.Relation.Enums.RelationSide relationSide, DiGi.Core.Interfaces.IUniqueReference? uniqueReference);relationSide RelationSide
The side of the relation to remove the reference from.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to remove.
Implements Remove(RelationSide, IUniqueReference)
System.Boolean
True if the reference was successfully removed; otherwise, false.
Removes multiple unique references from the specified side of the relation.
public abstract System.Collections.Generic.List<TUniqueReference>? Remove<TUniqueReference>(DiGi.Core.Relation.Enums.RelationSide relationSide, System.Collections.Generic.IEnumerable<TUniqueReference>? uniqueReferences)
where TUniqueReference : DiGi.Core.Interfaces.IUniqueReference;TUniqueReference
The type of the unique reference being removed.
relationSide RelationSide
The side of the relation from which to remove references.
uniqueReferences System.Collections.Generic.IEnumerable<TUniqueReference>
The collection of unique references to be removed.
Implements Remove<TUniqueReference>(RelationSide, IEnumerable<TUniqueReference>)
System.Collections.Generic.List<TUniqueReference>
A list of the removed unique references, or null if no references were removed.
Represents an abstract relationship between two types of unique objects.
public abstract class Relation<From,To> : DiGi.Core.Relation.Classes.Relation, DiGi.Core.Relation.Interfaces.IRelation<From, To>, DiGi.Core.Relation.Interfaces.IRelation, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IObject
where From : DiGi.Core.Interfaces.IUniqueObject
where To : DiGi.Core.Interfaces.IUniqueObjectFrom
The type of the source object in the relation.
To
The type of the destination object in the relation.
Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → Relation → Relation<From,To>
Derived
↳ ManyToManyRelation<From,To>
↳ ManyToOneRelation<From,To>
↳ OneToManyRelation<From,To>
↳ OneToOneRelation<From,To>
Implements DiGi.Core.Relation.Interfaces.IRelation<From,To>, IRelation, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IObject
Creates a new instance of the Relation class.
public Relation();Creates a new instance of the Relation class by copying another instance.
public Relation(DiGi.Core.Relation.Classes.Relation<From,To>? relation);relation DiGi.Core.Relation.Classes.Relation<From,To>
The relation instance to copy from.
Creates a new instance of the Relation class from a JSON object.
public Relation(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to initialize the relation from.
Gets the type associated with the specified relation side.
public override System.Type? GetType(DiGi.Core.Relation.Enums.RelationSide relationSide);relationSide RelationSide
The side of the relation to retrieve the type for.
Implements GetType(RelationSide)
System.Type
The type associated with the specified relation side, or null if not found.
Represents a collection of relations.
public class RelationCollection<TRelation> : DiGi.Core.Classes.SerializableObjectCollection<TRelation>
where TRelation : DiGi.Core.Relation.Interfaces.IRelationTRelation
The type of relation elements in the collection.
Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → DiGi.Core.Classes.SerializableObjectCollection<TRelation> → RelationCollection<TRelation>
Initializes a new instance of the RelationCollection class.
public RelationCollection();Initializes a new instance of the RelationCollection class by copying another RelationCollection.
public RelationCollection(DiGi.Core.Relation.Classes.RelationCollection<TRelation>? relationCollection);relationCollection DiGi.Core.Relation.Classes.RelationCollection<TRelation>
The source collection to copy from.
Initializes a new instance of the RelationCollection class with the specified relations.
public RelationCollection(System.Collections.Generic.IEnumerable<TRelation>? relations);relations System.Collections.Generic.IEnumerable<TRelation>
The collection of relations to initialize with.
Initializes a new instance of the RelationCollection class from a JSON object.
public RelationCollection(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to initialize the collection from.
Finds the first relation that contains the specified unique reference and optionally matches the predicate.
public XRelation? Find<XRelation>(DiGi.Core.Interfaces.IUniqueReference? uniqueReference, System.Func<XRelation?,bool>? func=null)
where XRelation : TRelation;XRelation
The type of relation being searched for.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to filter by.
func System.Func<XRelation,System.Boolean>
The predicate used to further filter the relations.
XRelation
The first relation that matches both the unique reference and the predicate, or null if no match is found.
Finds the first relation that optionally matches the predicate.
public XRelation? Find<XRelation>(System.Func<XRelation?,bool>? func=null)
where XRelation : TRelation;XRelation
The type of relation being searched for.
func System.Func<XRelation,System.Boolean>
The predicate used to filter the relations.
XRelation
The first relation that matches the predicate, or null if no match is found.
Finds all relations that contain the specified unique reference and optionally match the predicate.
public System.Collections.Generic.List<XRelation>? FindAll<XRelation>(DiGi.Core.Interfaces.IUniqueReference? uniqueReference, System.Func<XRelation?,bool>? func=null)
where XRelation : TRelation;XRelation
The type of relation being searched for.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to filter by.
func System.Func<XRelation,System.Boolean>
The predicate used to further filter the relations.
System.Collections.Generic.List<XRelation>
A list of relations that match both the unique reference and the predicate, or null if no matches are found.
Finds all relations that optionally match the predicate.
public System.Collections.Generic.List<XRelation>? FindAll<XRelation>(System.Func<XRelation?,bool>? func=null)
where XRelation : TRelation;XRelation
The type of relation being searched for.
func System.Func<XRelation,System.Boolean>
The predicate used to filter the relations.
System.Collections.Generic.List<XRelation>
A list of relations that match the predicate, or null if no matches are found.
Removes all relations that contain the specified unique reference.
public bool Remove(DiGi.Core.Interfaces.IUniqueReference? uniqueReference);uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference of the relations to remove.
System.Boolean
True if one or more relations were removed; otherwise, false.
Represents a cluster that organizes all relations by their source type references.
public class RelationListCluster : DiGi.Core.Relation.Classes.RelationListCluster<DiGi.Core.Relation.Interfaces.IRelation>Inheritance System.Object → DiGi.Core.Classes.Cluster<DiGi.Core.Classes.TypeReference,DiGi.Core.Classes.TypeReference,IRelation> → DiGi.Core.Classes.List<DiGi.Core.Classes.TypeReference,DiGi.Core.Classes.TypeReference,IRelation> → DiGi.Core.Classes.SerializableObjectListCluster<DiGi.Core.Classes.TypeReference,DiGi.Core.Classes.TypeReference,IRelation> → DiGi.Core.Relation.Classes.RelationListCluster<IRelation> → RelationListCluster
Initializes a new instance of the RelationListCluster class.
public RelationListCluster();Initializes a new instance of the RelationListCluster class by copying another RelationListCluster.
public RelationListCluster(DiGi.Core.Relation.Classes.RelationListCluster? relationCluster);relationCluster RelationListCluster
The RelationListCluster to copy from.
Initializes a new instance of the RelationListCluster class with the specified relations.
public RelationListCluster(System.Collections.Generic.IEnumerable<DiGi.Core.Relation.Interfaces.IRelation>? relations);relations System.Collections.Generic.IEnumerable<IRelation>
The collection of relations to initialize with.
Initializes a new instance of the RelationListCluster class from a JSON object.
public RelationListCluster(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to initialize from.
Represents a cluster that organizes relations by their source type references.
public class RelationListCluster<XRelation> : DiGi.Core.Classes.SerializableObjectListCluster<DiGi.Core.Classes.TypeReference, DiGi.Core.Classes.TypeReference, XRelation>
where XRelation : DiGi.Core.Relation.Interfaces.IRelationXRelation
The type of relation used in the cluster.
Inheritance System.Object → DiGi.Core.Classes.Cluster<DiGi.Core.Classes.TypeReference,DiGi.Core.Classes.TypeReference,XRelation> → DiGi.Core.Classes.List<DiGi.Core.Classes.TypeReference,DiGi.Core.Classes.TypeReference,XRelation> → DiGi.Core.Classes.SerializableObjectListCluster<DiGi.Core.Classes.TypeReference,DiGi.Core.Classes.TypeReference,XRelation> → RelationListCluster<XRelation>
Derived
↳ RelationListCluster
Initializes a new instance of the RelationListCluster class.
public RelationListCluster();Initializes a new instance of the RelationListCluster class by copying another RelationListCluster.
public RelationListCluster(DiGi.Core.Relation.Classes.RelationListCluster<XRelation>? relationListCluster);relationListCluster DiGi.Core.Relation.Classes.RelationListCluster<XRelation>
The source cluster to copy from.
Initializes a new instance of the RelationListCluster class with the specified relations.
public RelationListCluster(System.Collections.Generic.IEnumerable<XRelation>? relations);relations System.Collections.Generic.IEnumerable<XRelation>
The collection of relations to initialize the cluster with.
Initializes a new instance of the RelationListCluster class from a JSON object.
public RelationListCluster(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to initialize the cluster from.
Gets the list of source type references.
public System.Collections.Generic.List<DiGi.Core.Classes.TypeReference>? TypeReferences_From { get; }System.Collections.Generic.List<DiGi.Core.Classes.TypeReference>
Gets the source type reference from a relation.
protected override DiGi.Core.Classes.TypeReference? GetKey_1(XRelation? value);value XRelation
DiGi.Core.Classes.TypeReference
Gets the target type reference from a relation.
protected override DiGi.Core.Classes.TypeReference? GetKey_2(XRelation? value);value XRelation
DiGi.Core.Classes.TypeReference
Gets all relations of the specified type that contain the given unique reference and optionally match the predicate.
public System.Collections.Generic.List<URelation>? GetValues<URelation>(DiGi.Core.Interfaces.IUniqueReference? uniqueReference, System.Func<URelation?,bool>? func=null)
where URelation : XRelation;URelation
The type of relation to retrieve.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to search for.
func System.Func<URelation,System.Boolean>
An optional predicate to filter the relations.
System.Collections.Generic.List<URelation>
A list of matching relations, or null if none are found.
RelationListCluster<XRelation>.GetValues<URelation>(IEnumerable<IUniqueReference>, Func<URelation,bool>) Method
Gets all relations of the specified type that contain any of the given unique references and optionally match the predicate.
public System.Collections.Generic.List<URelation>? GetValues<URelation>(System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>? uniqueReferences, System.Func<URelation?,bool>? func=null)
where URelation : XRelation;URelation
The type of relation to retrieve.
uniqueReferences System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>
A collection of unique references to search for.
func System.Func<URelation,System.Boolean>
An optional predicate to filter the relations.
System.Collections.Generic.List<URelation>
A list of matching relations, or null if none are found.
Removes the specified unique reference from the relations.
public bool Remove(DiGi.Core.Interfaces.IUniqueReference? uniqueReference);uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to remove.
System.Boolean
True if the element is successfully removed; otherwise, false.
Removes the specified unique references from the relations and returns the affected relations.
public System.Collections.Generic.List<XRelation>? Remove<XUniqueReference>(System.Collections.Generic.IEnumerable<XUniqueReference>? uniqueReferences)
where XUniqueReference : DiGi.Core.Interfaces.IUniqueReference;XUniqueReference
The type of unique reference.
uniqueReferences System.Collections.Generic.IEnumerable<XUniqueReference>
The collection of unique references to remove.
System.Collections.Generic.List<XRelation>
A list of the affected relations, or null if none were removed.
Represents a reference to a relation list cluster identified by two type references and an index.
public class RelationListClusterReference : DiGi.Core.Classes.ListClusterReference<DiGi.Core.Classes.TypeReference, DiGi.Core.Classes.TypeReference>Inheritance System.Object → DiGi.Core.Classes.ListClusterReference<DiGi.Core.Classes.TypeReference,DiGi.Core.Classes.TypeReference> → RelationListClusterReference
Represents a reference to a relation list cluster identified by two type references and an index.
public RelationListClusterReference(DiGi.Core.Classes.TypeReference? key_1, DiGi.Core.Classes.TypeReference? key_2, int index);key_1 DiGi.Core.Classes.TypeReference
key_2 DiGi.Core.Classes.TypeReference
index System.Int32
Determines whether this instance equals the specified reference.
public override bool Equals(DiGi.Core.Interfaces.IReference? reference);reference DiGi.Core.Interfaces.IReference
The reference to compare with this instance.
System.Boolean
True if the instances are equal; otherwise, false.
Returns the hash code for this instance.
public override int GetHashCode();System.Int32
The hash code for this instance.
Represents a cluster that associates unique objects with their related relations.
public class UniqueObjectRelationCluster<TUniqueObject,XRelation> : DiGi.Core.Classes.UniqueObjectValueCluster<TUniqueObject>
where TUniqueObject : DiGi.Core.Interfaces.IUniqueObject
where XRelation : DiGi.Core.Relation.Interfaces.IRelationTUniqueObject
The type of the unique objects in the cluster.
XRelation
The type of the relations associated with the unique objects.
Inheritance System.Object → DiGi.Core.Classes.Cluster<DiGi.Core.Classes.TypeReference,DiGi.Core.Interfaces.IUniqueReference,TUniqueObject> → DiGi.Core.Classes.ValueCluster<DiGi.Core.Classes.TypeReference,DiGi.Core.Interfaces.IUniqueReference,TUniqueObject> → DiGi.Core.Classes.SerializableObjectValueCluster<DiGi.Core.Classes.TypeReference,DiGi.Core.Interfaces.IUniqueReference,TUniqueObject> → DiGi.Core.Classes.UniqueObjectValueCluster<TUniqueObject> → UniqueObjectRelationCluster<TUniqueObject,XRelation>
Initializes a new instance of the UniqueObjectRelationCluster class.
public UniqueObjectRelationCluster();Initializes a new instance of the UniqueObjectRelationCluster class by copying another UniqueObjectRelationCluster.
public UniqueObjectRelationCluster(DiGi.Core.Relation.Classes.UniqueObjectRelationCluster<TUniqueObject,XRelation>? uniqueObjectRelationCluster);uniqueObjectRelationCluster DiGi.Core.Relation.Classes.UniqueObjectRelationCluster<TUniqueObject,XRelation>
The existing cluster to copy from.
Initializes a new instance of the UniqueObjectRelationCluster class with the specified unique objects.
public UniqueObjectRelationCluster(System.Collections.Generic.IEnumerable<TUniqueObject>? uniqueObjects);uniqueObjects System.Collections.Generic.IEnumerable<TUniqueObject>
The collection of unique objects to initialize the cluster with.
Initializes a new instance of the UniqueObjectRelationCluster class from a JSON object.
public UniqueObjectRelationCluster(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to deserialize into a cluster.
Adds a relation to the cluster and returns it if successfully added.
public ZRelation? AddRelation<ZRelation>(ZRelation? relation)
where ZRelation : XRelation;ZRelation
The type of the relation.
relation ZRelation
The relation to add to the cluster.
ZRelation
The added relation if successful; otherwise, null.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.GetRelatedValue<UUniqueObject,ZRelation>(TUniqueObject, Func<UUniqueObject,bool>) Method
Gets a related value of the specified relation type for the given unique object.
public UUniqueObject? GetRelatedValue<UUniqueObject,ZRelation>(TUniqueObject? value, System.Func<UUniqueObject?,bool>? func=null)
where UUniqueObject : TUniqueObject
where ZRelation : XRelation;UUniqueObject
The type of the related unique object.
ZRelation
The type of the relation.
value TUniqueObject
The unique object to get a related value for.
func System.Func<UUniqueObject,System.Boolean>
An optional filter function to apply to the related value.
UUniqueObject
The related value, or null if not found.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.GetRelatedValue<UUniqueObject>(TUniqueObject, Func<UUniqueObject,bool>) Method
Gets a related value of the specified type for the given unique object.
public UUniqueObject? GetRelatedValue<UUniqueObject>(TUniqueObject? value, System.Func<UUniqueObject?,bool>? func=null)
where UUniqueObject : TUniqueObject;UUniqueObject
The type of the related unique object.
value TUniqueObject
The unique object to get a related value for.
func System.Func<UUniqueObject,System.Boolean>
An optional filter function to apply to the related value.
UUniqueObject
The related value, or null if not found.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.GetRelatedValueDictionary<UUniqueObject,ZRelation>(IEnumerable<TUniqueObject>, Func<UUniqueObject,bool>) Method
Gets a dictionary mapping unique references to their related values of the specified relation type.
public System.Collections.Generic.Dictionary<DiGi.Core.Interfaces.IUniqueReference,UUniqueObject>? GetRelatedValueDictionary<UUniqueObject,ZRelation>(System.Collections.Generic.IEnumerable<TUniqueObject>? values, System.Func<UUniqueObject?,bool>? func=null)
where UUniqueObject : TUniqueObject
where ZRelation : XRelation;UUniqueObject
The type of the related unique objects.
ZRelation
The type of the relation.
values System.Collections.Generic.IEnumerable<TUniqueObject>
The collection of unique objects to get related values for.
func System.Func<UUniqueObject,System.Boolean>
An optional filter function to apply to the related values.
System.Collections.Generic.Dictionary<DiGi.Core.Interfaces.IUniqueReference,UUniqueObject>
A dictionary mapping unique references to their related values, or null if none are found.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.GetRelatedValues<UUniqueObject,ZRelation>(TUniqueObject, Func<UUniqueObject,bool>) Method
Gets all related values of the specified relation type for the given unique object.
public System.Collections.Generic.List<UUniqueObject>? GetRelatedValues<UUniqueObject,ZRelation>(TUniqueObject? value, System.Func<UUniqueObject?,bool>? func=null)
where UUniqueObject : TUniqueObject
where ZRelation : XRelation;UUniqueObject
The type of the related unique objects.
ZRelation
The type of the relation.
value TUniqueObject
The unique object to get related values for.
func System.Func<UUniqueObject,System.Boolean>
An optional filter function to apply to the related values.
System.Collections.Generic.List<UUniqueObject>
A list of related values, or null if none are found.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.GetRelatedValues<UUniqueObject>(TUniqueObject, Func<UUniqueObject,bool>) Method
Gets all related values for the given unique object.
public System.Collections.Generic.List<UUniqueObject>? GetRelatedValues<UUniqueObject>(TUniqueObject? value, System.Func<UUniqueObject?,bool>? func=null)
where UUniqueObject : TUniqueObject;UUniqueObject
The type of the related unique objects.
value TUniqueObject
The unique object to get related values for.
func System.Func<UUniqueObject,System.Boolean>
An optional filter function to apply to the related values.
System.Collections.Generic.List<UUniqueObject>
A list of related values, or null if none are found.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.GetRelation<ZRelation>(IUniqueReference, Func<ZRelation,bool>) Method
Gets the first relation of the specified type that contains the given unique reference and optionally matches the predicate.
public ZRelation? GetRelation<ZRelation>(DiGi.Core.Interfaces.IUniqueReference? uniqueReference, System.Func<ZRelation?,bool>? func=null)
where ZRelation : XRelation;ZRelation
The type of relation to retrieve.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to search for.
func System.Func<ZRelation,System.Boolean>
An optional predicate to filter the relations.
ZRelation
The first relation containing the unique reference and matching the predicate, or null.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.GetRelation<ZRelation>(TUniqueObject, Func<ZRelation,bool>) Method
Gets the first relation of the specified type that contains the given unique object and optionally matches the predicate.
public ZRelation? GetRelation<ZRelation>(TUniqueObject? value, System.Func<ZRelation?,bool>? func=null)
where ZRelation : XRelation;ZRelation
The type of relation to retrieve.
value TUniqueObject
The unique object to search for.
func System.Func<ZRelation,System.Boolean>
An optional predicate to filter the relations.
ZRelation
The first relation containing the unique object and matching the predicate, or null.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.GetRelations<ZRelation>(IUniqueReference) Method
Gets all relations of the specified type that contain the given unique reference.
public System.Collections.Generic.List<ZRelation>? GetRelations<ZRelation>(DiGi.Core.Interfaces.IUniqueReference? uniqueReference)
where ZRelation : XRelation;ZRelation
The type of relation to retrieve.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference to search for.
System.Collections.Generic.List<ZRelation>
A list of relations containing the unique reference, or null.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.GetRelations<ZRelation>(IUniqueReference, Func<ZRelation,bool>) Method
Gets all relations of the specified type that contain the given unique reference and optionally match the predicate.
public System.Collections.Generic.List<ZRelation>? GetRelations<ZRelation>(DiGi.Core.Interfaces.IUniqueReference? uniqueReference, System.Func<ZRelation?,bool>? func=null)
where ZRelation : XRelation;ZRelation
The type of relation to retrieve.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference used to filter the relations.
func System.Func<ZRelation,System.Boolean>
An optional predicate to further filter the resulting relations.
System.Collections.Generic.List<ZRelation>
A list of matching relations, or null if no matches were found.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.GetRelations<ZRelation>(IEnumerable<IUniqueReference>, Func<ZRelation,bool>) Method
Gets all relations of the specified type that contain any of the given unique references and optionally match the predicate.
public System.Collections.Generic.List<ZRelation>? GetRelations<ZRelation>(System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>? uniqueReferences, System.Func<ZRelation?,bool>? func=null)
where ZRelation : XRelation;ZRelation
The type of relation to retrieve.
uniqueReferences System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>
The collection of unique references used to filter the relations.
func System.Func<ZRelation,System.Boolean>
An optional predicate to further filter the resulting relations.
System.Collections.Generic.List<ZRelation>
A list of matching relations, or null if no matches were found.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.GetRelations<ZRelation>(IEnumerable<TUniqueObject>, Func<ZRelation,bool>) Method
Gets all relations of the specified type that contain any of the given unique objects and optionally match the predicate.
public System.Collections.Generic.List<ZRelation>? GetRelations<ZRelation>(System.Collections.Generic.IEnumerable<TUniqueObject>? uniqueObjects, System.Func<ZRelation?,bool>? func=null)
where ZRelation : XRelation;ZRelation
The type of relation to retrieve.
uniqueObjects System.Collections.Generic.IEnumerable<TUniqueObject>
A collection of unique objects to search for.
func System.Func<ZRelation,System.Boolean>
An optional predicate to filter the relations.
System.Collections.Generic.List<ZRelation>
A list of relations containing any of the specified unique objects and matching the predicate, or null.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.GetRelations<ZRelation>(TUniqueObject, Func<ZRelation,bool>) Method
Gets all relations of the specified type that contain the given unique object and optionally match the predicate.
public System.Collections.Generic.List<ZRelation>? GetRelations<ZRelation>(TUniqueObject? uniqueObject, System.Func<ZRelation?,bool>? func=null)
where ZRelation : XRelation;ZRelation
The type of relation to retrieve.
uniqueObject TUniqueObject
The unique object to search for.
func System.Func<ZRelation,System.Boolean>
An optional predicate to filter the relations.
System.Collections.Generic.List<ZRelation>
A list of relations containing the unique object and matching the predicate, or null.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.GetValue<UUniqueObject>(XRelation, RelationSide) Method
Gets the unique object of the specified type from the relation on the given side.
public UUniqueObject? GetValue<UUniqueObject>(XRelation? relation, DiGi.Core.Relation.Enums.RelationSide relationSide)
where UUniqueObject : TUniqueObject;UUniqueObject
The type of unique object to retrieve.
relation XRelation
The relation to query.
relationSide RelationSide
The side of the relation to retrieve the value from.
UUniqueObject
The unique object found, or null if no such object exists.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.GetValues<UUniqueObject>(XRelation, RelationSide) Method
Gets all unique objects of the specified type from the relation on the given side.
public System.Collections.Generic.List<UUniqueObject>? GetValues<UUniqueObject>(XRelation? relation, DiGi.Core.Relation.Enums.RelationSide relationSide)
where UUniqueObject : TUniqueObject;UUniqueObject
The type of unique object to retrieve.
relation XRelation
The relation to query.
relationSide RelationSide
The side of the relation to retrieve values from.
System.Collections.Generic.List<UUniqueObject>
A list of unique objects found, or null if no objects were found.
Removes the specified unique references and returns the affected references.
public override System.Collections.Generic.List<DiGi.Core.Interfaces.IUniqueReference>? Remove(System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>? keys_2);keys_2 System.Collections.Generic.IEnumerable<DiGi.Core.Interfaces.IUniqueReference>
The collection of unique references to remove.
System.Collections.Generic.List<DiGi.Core.Interfaces.IUniqueReference>
A list of the removed unique references, or null if no references were removed.
Removes the specified unique object and its associated relations.
public override bool Remove(TUniqueObject? uniqueObject);uniqueObject TUniqueObject
The unique object to remove.
System.Boolean
True if the unique object was successfully removed; otherwise, false.
Removes the specified relation from the cluster.
public virtual bool Remove(XRelation? relation);relation XRelation
The relation to remove.
System.Boolean
True if the relation was successfully removed; otherwise, false.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.Remove<UUniqueObject>(IEnumerable<UUniqueObject>) Method
Removes the specified unique objects and returns those that were successfully removed.
public override System.Collections.Generic.List<UUniqueObject>? Remove<UUniqueObject>(System.Collections.Generic.IEnumerable<UUniqueObject>? uniqueObjects)
where UUniqueObject : TUniqueObject;UUniqueObject
The type of the unique objects.
uniqueObjects System.Collections.Generic.IEnumerable<UUniqueObject>
The collection of unique objects to remove.
System.Collections.Generic.List<UUniqueObject>
A list of unique objects that were successfully removed, or null if none were removed.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.TryGetRelatedValue<UUniqueObject,ZRelation>(UUniqueObject, TUniqueObject, Func<UUniqueObject,bool>) Method
Tries to get a related value of the specified type for the given unique object using the specified relation type.
public bool TryGetRelatedValue<UUniqueObject,ZRelation>(out UUniqueObject? uniqueObject, TUniqueObject? value, System.Func<UUniqueObject?,bool>? func=null)
where UUniqueObject : TUniqueObject
where ZRelation : XRelation;UUniqueObject
The type of the unique object.
ZRelation
The type of the relation.
uniqueObject UUniqueObject
When this method returns, contains the related value if found; otherwise, null.
value TUniqueObject
The value to search for.
func System.Func<UUniqueObject,System.Boolean>
An optional function to filter the results.
System.Boolean
True if a related value was found; otherwise, false.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.TryGetRelatedValue<UUniqueObject>(UUniqueObject, TUniqueObject, Func<UUniqueObject,bool>) Method
Tries to get a related value of the specified type for the given unique object.
public bool TryGetRelatedValue<UUniqueObject>(out UUniqueObject? uniqueObject, TUniqueObject? value, System.Func<UUniqueObject?,bool>? func=null)
where UUniqueObject : TUniqueObject;UUniqueObject
The type of the unique object.
uniqueObject UUniqueObject
When this method returns, contains the related value if found; otherwise, null.
value TUniqueObject
The value to search for.
func System.Func<UUniqueObject,System.Boolean>
An optional function to filter the results.
System.Boolean
True if a related value was found; otherwise, false.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.TryGetRelatedValues<UUniqueObject,ZRelation>(List<UUniqueObject>, TUniqueObject, Func<UUniqueObject,bool>) Method
Tries to get all related values of the specified type for the given unique object using the specified relation type.
public bool TryGetRelatedValues<UUniqueObject,ZRelation>(out System.Collections.Generic.List<UUniqueObject>? uniqueObjects, TUniqueObject? value, System.Func<UUniqueObject?,bool>? func=null)
where UUniqueObject : TUniqueObject
where ZRelation : XRelation;UUniqueObject
The type of the unique objects to retrieve.
ZRelation
The type of the relation used to find the values.
uniqueObjects System.Collections.Generic.List<UUniqueObject>
When this method returns, contains the list of related unique objects found; otherwise, null.
value TUniqueObject
The unique object for which to retrieve related values.
func System.Func<UUniqueObject,System.Boolean>
An optional predicate to filter the related values.
System.Boolean
True if one or more related values were found; otherwise, false.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.TryGetRelatedValues<UUniqueObject>(List<UUniqueObject>, TUniqueObject, Func<UUniqueObject,bool>) Method
Tries to get all related values of the specified type for the given unique object.
public bool TryGetRelatedValues<UUniqueObject>(out System.Collections.Generic.List<UUniqueObject>? uniqueObjects, TUniqueObject? value, System.Func<UUniqueObject?,bool>? func=null)
where UUniqueObject : TUniqueObject;UUniqueObject
The type of the unique objects to retrieve.
uniqueObjects System.Collections.Generic.List<UUniqueObject>
When this method returns, contains the list of related unique objects found; otherwise, null.
value TUniqueObject
The unique object for which to retrieve related values.
func System.Func<UUniqueObject,System.Boolean>
An optional predicate to filter the related values.
System.Boolean
True if one or more related values were found; otherwise, false.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.TryGetRelation<ZRelation>(IUniqueReference, ZRelation, Func<ZRelation,bool>) Method
Tries to get a relation of the specified type that contains the given unique reference and optionally matches the predicate.
public bool TryGetRelation<ZRelation>(DiGi.Core.Interfaces.IUniqueReference? uniqueReference, out ZRelation? relation, System.Func<ZRelation?,bool>? func=null)
where ZRelation : XRelation;ZRelation
The type of relation to retrieve.
uniqueReference DiGi.Core.Interfaces.IUniqueReference
The unique reference used to identify the relation.
relation ZRelation
When this method returns, contains the relation found; otherwise, null.
func System.Func<ZRelation,System.Boolean>
An optional predicate to filter the relation.
System.Boolean
True if a matching relation was found; otherwise, false.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.TryGetRelation<ZRelation>(ZRelation, Func<ZRelation,bool>) Method
Tries to get a relation of the specified type that optionally matches the predicate.
public bool TryGetRelation<ZRelation>(out ZRelation? relation, System.Func<ZRelation?,bool>? func=null)
where ZRelation : XRelation;ZRelation
The type of relation to retrieve.
relation ZRelation
When this method returns, contains the relation found; otherwise, null.
func System.Func<ZRelation,System.Boolean>
An optional predicate to filter the relation.
System.Boolean
True if a matching relation was found; otherwise, false.
UniqueObjectRelationCluster<TUniqueObject,XRelation>.TryGetRelations<ZRelation>(List<ZRelation>, Func<ZRelation,bool>) Method
Tries to get all relations of the specified type that optionally match the predicate.
public bool TryGetRelations<ZRelation>(out System.Collections.Generic.List<ZRelation>? relations, System.Func<ZRelation?,bool>? func=null)
where ZRelation : XRelation;ZRelation
The type of relation to retrieve.
relations System.Collections.Generic.List<ZRelation>
When this method returns, contains the list of relations found; otherwise, null.
func System.Func<ZRelation,System.Boolean>
An optional predicate to filter the relations.
System.Boolean
True if one or more relations were found; otherwise, false.
Provides a base class for unique objects that manage relations through a UniqueObjectRelationCluster.
public abstract class UniqueObjectRelationClusterModel<TUniqueObject,XRelation> : DiGi.Core.Classes.GuidModel
where TUniqueObject : DiGi.Core.Interfaces.IUniqueObject
where XRelation : DiGi.Core.Relation.Interfaces.IRelationTUniqueObject
The type of the unique object.
XRelation
The type of the relation.
Inheritance System.Object → DiGi.Core.Classes.Object → DiGi.Core.Classes.SerializableObject → DiGi.Core.Classes.UniqueObject → DiGi.Core.Classes.GuidObject → DiGi.Core.Classes.GuidModel → UniqueObjectRelationClusterModel<TUniqueObject,XRelation>
Initializes a new instance of the UniqueObjectRelationClusterModel class.
public UniqueObjectRelationClusterModel();UniqueObjectRelationClusterModel(UniqueObjectRelationClusterModel<TUniqueObject,XRelation>) Constructor
Initializes a new instance of the UniqueObjectRelationClusterModel class by cloning another instance.
public UniqueObjectRelationClusterModel(DiGi.Core.Relation.Classes.UniqueObjectRelationClusterModel<TUniqueObject,XRelation>? uniqueObjectRelationClusterModel);uniqueObjectRelationClusterModel DiGi.Core.Relation.Classes.UniqueObjectRelationClusterModel<TUniqueObject,XRelation>
The existing model instance to clone from.
Initializes a new instance of the UniqueObjectRelationClusterModel class from a JsonObject.
public UniqueObjectRelationClusterModel(System.Text.Json.Nodes.JsonObject? jsonObject);jsonObject System.Text.Json.Nodes.JsonObject
The JSON object to initialize the model from.
Creates a new Guid for a unique object of the specified type.
public System.Guid GetNewGuid(System.Type? type);type System.Type
The type of the unique object.
System.Guid
A new unique identifier (Guid).
Creates a new Guid for a unique object of the specified generic type.
public System.Guid GetNewGuid<YUniqueObject>()
where YUniqueObject : TUniqueObject;YUniqueObject
The type of unique object for which to create a new GUID.
System.Guid
A new unique identifier (Guid).
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.GetObject<YUniqueObject>(GuidReference) Method
Gets the unique object of the specified type identified by the given GUID reference.
public YUniqueObject? GetObject<YUniqueObject>(DiGi.Core.Classes.GuidReference? guidReference)
where YUniqueObject : TUniqueObject;YUniqueObject
The type of unique object to retrieve.
guidReference DiGi.Core.Classes.GuidReference
The GUID reference identifying the unique object.
YUniqueObject
The unique object associated with the provided GUID reference, or null if not found.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.GetObject<YUniqueObject>(Func<YUniqueObject,bool>) Method
Gets the first unique object of the specified type that optionally matches the predicate.
public YUniqueObject? GetObject<YUniqueObject>(System.Func<YUniqueObject?,bool>? func=null)
where YUniqueObject : TUniqueObject;YUniqueObject
The type of unique object to retrieve.
func System.Func<YUniqueObject,System.Boolean>
An optional predicate to filter the unique objects.
YUniqueObject
The first unique object that matches the predicate, or null if no match is found.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.GetObjects<YUniqueObject>(Func<YUniqueObject,bool>) Method
Gets all unique objects of the specified type that optionally match the predicate.
public System.Collections.Generic.List<YUniqueObject>? GetObjects<YUniqueObject>(System.Func<YUniqueObject?,bool>? func=null)
where YUniqueObject : TUniqueObject;YUniqueObject
The type of unique object to retrieve.
func System.Func<YUniqueObject,System.Boolean>
An optional predicate to filter the unique objects.
System.Collections.Generic.List<YUniqueObject>
A list of unique objects that match the predicate, or null if none are found.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.GetObjects<YUniqueObject>(XRelation, RelationSide, Func<YUniqueObject,bool>) Method
Gets all unique objects of the specified type related through the specified relation on the given side that optionally match the predicate.
public System.Collections.Generic.List<YUniqueObject>? GetObjects<YUniqueObject>(XRelation? relation, DiGi.Core.Relation.Enums.RelationSide relationSide, System.Func<YUniqueObject?,bool>? func=null)
where YUniqueObject : TUniqueObject;YUniqueObject
The type of the unique objects to retrieve.
relation XRelation
The relation used to find the objects.
relationSide RelationSide
The side of the relation to query.
func System.Func<YUniqueObject,System.Boolean>
An optional predicate to filter the retrieved objects.
System.Collections.Generic.List<YUniqueObject>
A list of unique objects that match the criteria, or null if none are found.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.GetRelatedObject<YUniqueObject>(TUniqueObject, Func<YUniqueObject,bool>) Method
Gets the related object of the specified type for the given unique object that optionally matches the predicate.
public YUniqueObject? GetRelatedObject<YUniqueObject>(TUniqueObject? uniqueObject, System.Func<YUniqueObject?,bool>? func=null)
where YUniqueObject : TUniqueObject;YUniqueObject
The type of the related object.
uniqueObject TUniqueObject
The unique object to find a relation for.
func System.Func<YUniqueObject,System.Boolean>
An optional predicate to filter the related object.
YUniqueObject
The related object that matches the criteria, or null if not found.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.GetRelatedObjectDictionary<YUniqueObject,URelation>(IEnumerable<TUniqueObject>, Func<YUniqueObject,bool>) Method
Gets a dictionary mapping unique references to related objects of the specified type using the specified relation type.
public virtual System.Collections.Generic.Dictionary<DiGi.Core.Interfaces.IUniqueReference,YUniqueObject>? GetRelatedObjectDictionary<YUniqueObject,URelation>(System.Collections.Generic.IEnumerable<TUniqueObject>? uniqueObjects, System.Func<YUniqueObject?,bool>? func=null)
where YUniqueObject : TUniqueObject
where URelation : XRelation;YUniqueObject
The type of the related objects.
URelation
The type of the relation used for mapping.
uniqueObjects System.Collections.Generic.IEnumerable<TUniqueObject>
The collection of unique objects to find relations for.
func System.Func<YUniqueObject,System.Boolean>
An optional predicate to filter the related objects.
System.Collections.Generic.Dictionary<DiGi.Core.Interfaces.IUniqueReference,YUniqueObject>
A dictionary mapping unique references to their corresponding related objects, or null if none are found.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.GetRelatedObjectDictionary<YUniqueObject>(IEnumerable<TUniqueObject>, Func<YUniqueObject,bool>) Method
Gets a dictionary mapping unique references to related objects of the specified type for the given unique objects.
public System.Collections.Generic.Dictionary<DiGi.Core.Interfaces.IUniqueReference,YUniqueObject>? GetRelatedObjectDictionary<YUniqueObject>(System.Collections.Generic.IEnumerable<TUniqueObject>? uniqueObjects, System.Func<YUniqueObject?,bool>? func=null)
where YUniqueObject : TUniqueObject;YUniqueObject
The type of the related objects.
uniqueObjects System.Collections.Generic.IEnumerable<TUniqueObject>
The collection of unique objects to find relations for.
func System.Func<YUniqueObject,System.Boolean>
An optional predicate to filter the related objects.
System.Collections.Generic.Dictionary<DiGi.Core.Interfaces.IUniqueReference,YUniqueObject>
A dictionary mapping unique references to their corresponding related objects, or null if none are found.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.GetRelatedObjects<YUniqueObject>(IEnumerable<TUniqueObject>, Func<YUniqueObject,bool>) Method
Gets all related objects of the specified type for the given unique objects that optionally match the predicate.
public System.Collections.Generic.List<YUniqueObject>? GetRelatedObjects<YUniqueObject>(System.Collections.Generic.IEnumerable<TUniqueObject>? uniqueObjects, System.Func<YUniqueObject?,bool>? func=null)
where YUniqueObject : TUniqueObject;YUniqueObject
The type of the related objects.
uniqueObjects System.Collections.Generic.IEnumerable<TUniqueObject>
The collection of unique objects to find relations for.
func System.Func<YUniqueObject,System.Boolean>
An optional predicate to filter the related objects.
System.Collections.Generic.List<YUniqueObject>
A list of related objects that match the criteria, or null if none are found.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.GetRelatedObjects<YUniqueObject>(TUniqueObject, Func<YUniqueObject,bool>) Method
Gets all related objects of the specified type for the given unique object that optionally match the predicate.
public System.Collections.Generic.List<YUniqueObject>? GetRelatedObjects<YUniqueObject>(TUniqueObject? uniqueObject, System.Func<YUniqueObject?,bool>? func=null)
where YUniqueObject : TUniqueObject;YUniqueObject
The type of the related objects.
uniqueObject TUniqueObject
The unique object to find relations for.
func System.Func<YUniqueObject,System.Boolean>
An optional predicate to filter the related objects.
System.Collections.Generic.List<YUniqueObject>
A list of related objects that match the predicate, or null if none are found.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.GetRelation<URelation>(TUniqueObject, Func<URelation,bool>) Method
Gets the relation of the specified type for the given unique object that optionally matches the predicate.
public URelation? GetRelation<URelation>(TUniqueObject? uniqueObject, System.Func<URelation?,bool>? func=null)
where URelation : XRelation;URelation
The type of the relation.
uniqueObject TUniqueObject
The unique object for which to get the relation.
func System.Func<URelation,System.Boolean>
An optional predicate to filter the relation.
URelation
The relation that matches the predicate, or null if not found.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.GetRelation<YUniqueObject>(Func<YUniqueObject,bool>) Method
Gets the first relation of the specified type that optionally matches the predicate.
public YUniqueObject? GetRelation<YUniqueObject>(System.Func<YUniqueObject?,bool>? func=null)
where YUniqueObject : XRelation;YUniqueObject
The type of the unique object.
func System.Func<YUniqueObject,System.Boolean>
An optional predicate to filter the result.
YUniqueObject
The first matching unique object, or null if not found.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.GetRelations<URelation>(Func<URelation,bool>) Method
Gets all relations of the specified type that optionally match the predicate.
public System.Collections.Generic.List<URelation>? GetRelations<URelation>(System.Func<URelation?,bool>? func=null)
where URelation : XRelation;URelation
The type of the relation.
func System.Func<URelation,System.Boolean>
An optional predicate to filter the relations.
System.Collections.Generic.List<URelation>
A list of relations that match the predicate, or null if none are found.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.TryGetObject<YUniqueObject>(GuidReference, YUniqueObject) Method
Determines whether a unique object of the specified type exists for the given GUID reference.
public bool TryGetObject<YUniqueObject>(DiGi.Core.Classes.GuidReference? guidReference, out YUniqueObject? uniqueObject)
where YUniqueObject : TUniqueObject;YUniqueObject
The type of the unique object to retrieve.
guidReference DiGi.Core.Classes.GuidReference
The GUID reference of the unique object.
uniqueObject YUniqueObject
When this method returns, contains the unique object if found; otherwise, null.
System.Boolean
True if a unique object was found for the given GUID reference; otherwise, false.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.TryGetObject<YUniqueObject>(YUniqueObject, Func<YUniqueObject,bool>) Method
Determines whether a unique object of the specified type exists and optionally matches the predicate.
public virtual bool TryGetObject<YUniqueObject>(out YUniqueObject? uniqueObject, System.Func<YUniqueObject?,bool>? func=null)
where YUniqueObject : TUniqueObject;YUniqueObject
The type of the unique object.
uniqueObject YUniqueObject
When this method returns, contains the unique object if found; otherwise, null.
func System.Func<YUniqueObject,System.Boolean>
An optional predicate to filter the unique object.
System.Boolean
True if the unique object was found and matches the predicate; otherwise, false.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.TryGetObjects<YUniqueObject>(List<YUniqueObject>, Func<YUniqueObject,bool>) Method
Determines whether any unique objects of the specified type exist and optionally match the predicate.
public virtual bool TryGetObjects<YUniqueObject>(out System.Collections.Generic.List<YUniqueObject>? uniqueObjects, System.Func<YUniqueObject?,bool>? func=null)
where YUniqueObject : TUniqueObject;YUniqueObject
The type of the unique objects to retrieve.
uniqueObjects System.Collections.Generic.List<YUniqueObject>
When this method returns, contains a list of found unique objects if any exist; otherwise, null.
func System.Func<YUniqueObject,System.Boolean>
An optional predicate to filter the unique objects.
System.Boolean
True if one or more unique objects were found that match the predicate; otherwise, false.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.TryGetObjects<YUniqueObject>(XRelation, RelationSide, List<YUniqueObject>, Func<YUniqueObject,bool>) Method
Determines whether any unique objects of the specified type exist that are related through the specified relation on the given side and optionally match the predicate.
public virtual bool TryGetObjects<YUniqueObject>(XRelation? relation, DiGi.Core.Relation.Enums.RelationSide relationSide, out System.Collections.Generic.List<YUniqueObject>? uniqueObjects, System.Func<YUniqueObject?,bool>? func=null)
where YUniqueObject : TUniqueObject;YUniqueObject
The type of the unique objects to retrieve.
relation XRelation
The relation used to find the unique objects.
relationSide RelationSide
The side of the relation to search on.
uniqueObjects System.Collections.Generic.List<YUniqueObject>
When this method returns, contains a list of found unique objects if any exist; otherwise, null.
func System.Func<YUniqueObject,System.Boolean>
An optional predicate to filter the unique objects.
System.Boolean
True if one or more unique objects were found that match the predicate; otherwise, false.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.TryGetRelatedObject<YUniqueObject,URelation>(TUniqueObject, YUniqueObject, Func<YUniqueObject,bool>) Method
Determines whether a related object of the specified type exists for the given unique object using the specified relation type and optionally matches the predicate.
public virtual bool TryGetRelatedObject<YUniqueObject,URelation>(TUniqueObject? uniqueObject, out YUniqueObject? relatedUniqueObject, System.Func<YUniqueObject?,bool>? func=null)
where YUniqueObject : TUniqueObject
where URelation : XRelation;YUniqueObject
The type of the related unique object.
URelation
The type of the relation used to find the related object.
uniqueObject TUniqueObject
The unique object for which to find a related object.
relatedUniqueObject YUniqueObject
When this method returns, contains the related unique object if found; otherwise, null.
func System.Func<YUniqueObject,System.Boolean>
An optional predicate to filter the related object.
System.Boolean
True if a related object was found that matches the predicate; otherwise, false.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.TryGetRelatedObject<YUniqueObject>(TUniqueObject, YUniqueObject, Func<YUniqueObject,bool>) Method
Determines whether a related object of the specified type exists for the given unique object and optionally matches the predicate.
public virtual bool TryGetRelatedObject<YUniqueObject>(TUniqueObject? uniqueObject, out YUniqueObject? relatedUniqueObject, System.Func<YUniqueObject?,bool>? func=null)
where YUniqueObject : TUniqueObject;YUniqueObject
The type of the related unique object.
uniqueObject TUniqueObject
The unique object for which to find a related object.
relatedUniqueObject YUniqueObject
When this method returns, contains the related unique object if found; otherwise, null.
func System.Func<YUniqueObject,System.Boolean>
An optional predicate to filter the related object.
System.Boolean
True if a related object was found that matches the predicate; otherwise, false.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.TryGetRelatedObjects<YUniqueObject,URelation>(TUniqueObject, List<YUniqueObject>, Func<YUniqueObject,bool>) Method
Determines whether any related objects of the specified type exist for the given unique object using the specified relation type and optionally match the predicate.
public virtual bool TryGetRelatedObjects<YUniqueObject,URelation>(TUniqueObject? uniqueObject, out System.Collections.Generic.List<YUniqueObject>? uniqueObjects, System.Func<YUniqueObject?,bool>? func=null)
where YUniqueObject : TUniqueObject
where URelation : XRelation;YUniqueObject
The type of the related objects.
URelation
The type of the relation used to identify related objects.
uniqueObject TUniqueObject
The unique object to evaluate.
uniqueObjects System.Collections.Generic.List<YUniqueObject>
When this method returns, contains a list of related objects found; otherwise, null.
func System.Func<YUniqueObject,System.Boolean>
An optional predicate used to filter the related objects.
System.Boolean
True if one or more related objects were found; otherwise, false.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.TryGetRelatedObjects<YUniqueObject>(TUniqueObject, List<YUniqueObject>, Func<YUniqueObject,bool>) Method
Determines whether any related objects of the specified type exist for the given unique object and optionally match the predicate.
public virtual bool TryGetRelatedObjects<YUniqueObject>(TUniqueObject? uniqueObject, out System.Collections.Generic.List<YUniqueObject>? uniqueObjects, System.Func<YUniqueObject?,bool>? func=null)
where YUniqueObject : TUniqueObject;YUniqueObject
The type of the related objects.
uniqueObject TUniqueObject
The unique object to evaluate.
uniqueObjects System.Collections.Generic.List<YUniqueObject>
When this method returns, contains a list of related objects found; otherwise, null.
func System.Func<YUniqueObject,System.Boolean>
An optional predicate used to filter the related objects.
System.Boolean
True if one or more related objects were found; otherwise, false.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.TryGetRelation<URelation>(TUniqueObject, URelation, Func<URelation,bool>) Method
Determines whether a relation of the specified type exists for the given unique object and optionally matches the predicate.
public bool TryGetRelation<URelation>(TUniqueObject uniqueObject, out URelation? relation, System.Func<URelation?,bool>? func=null)
where URelation : XRelation;URelation
The type of relation to search for.
uniqueObject TUniqueObject
The unique object to evaluate.
relation URelation
When this method returns, contains the relation found; otherwise, null.
func System.Func<URelation,System.Boolean>
An optional predicate used to filter the relation.
System.Boolean
True if a relation was found for the specified object; otherwise, false.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.TryGetRelation<URelation>(URelation, Func<URelation,bool>) Method
Determines whether a relation of the specified type exists and optionally matches the predicate.
public virtual bool TryGetRelation<URelation>(out URelation? relation, System.Func<URelation?,bool>? func=null)
where URelation : XRelation;URelation
The type of relation to search for.
relation URelation
When this method returns, contains the relation found; otherwise, null.
func System.Func<URelation,System.Boolean>
An optional predicate used to filter the relation.
System.Boolean
True if a relation was found; otherwise, false.
UniqueObjectRelationClusterModel<TUniqueObject,XRelation>.TryGetRelations<URelation>(List<URelation>, Func<URelation,bool>) Method
Determines whether any relations of the specified type exist and optionally match the predicate.
public virtual bool TryGetRelations<URelation>(out System.Collections.Generic.List<URelation>? relations, System.Func<URelation?,bool>? func=null)
where URelation : XRelation;URelation
The type of relation to search for.
relations System.Collections.Generic.List<URelation>
When this method returns, contains a list of relations found; otherwise, null.
func System.Func<URelation,System.Boolean>
An optional predicate used to filter the relations.
System.Boolean
True if one or more relations were found; otherwise, false.