-
Notifications
You must be signed in to change notification settings - Fork 0
Referencing
Äkwav edited this page Apr 13, 2019
·
1 revision
As Referenceables don't have to be present on the current server we need a way to reference them.
This is done by a Reference<T> which links the SourceReference identifying the Object to the Object which it is referencing.
Basiacally it glues together objects on different servers.
To execute a Command for a list of Referenced Resources you would type
var list = new List<Reference<CoflnetUser>>()
foreach(var item in list)
{
item.ExecuteForResource(new MessageData("msg","hi");
}
This will call the Referencemanager which has a list of all local Referenceables inside of a InnerReference object. For nonwriting commands it trys to
- Find the InnerReference that may have addidional information (such as a mirror server/sibbling managing node) and executes if found
- Tries to find General mappings between servers (complete sibbling nodes)
- Takes the server from the
SourceReferenceand executes the command there.
For writing commands the managing node is always prefered.