GlobalServer

References
public sealed class GlobalServer
Maintains a collection of global data sources within a document.

Constructors

GlobalServer

#
Create a new global object repository.
public GlobalServer(
document
Document that owns this repository.
)

Properties

Document

#
Gets the document associated with this global server.
public Document Document { get; }

Shouts

#
Iterate over all Shout objects in the document associated with this server. This property duplicates the internal collection so it can be used in a thread-safe way. That is to say, changes made to the collection *while iterating* will not be reflected in this enumerable.
public IEnumerable<Shout> Shouts { get; }

Methods

CreateResolver

#
Create an undeclared resolver for expressions based on globals in the current document and parent documents.
public Resolver CreateResolver(
caller,
solution,
stack
)

FindReferences

#
Find all references to a specific shout object.
public void FindReferences(
shout,
Shout to search for.
listenObjects,
All listen objects in this file which depend on this shout.
otherObjects
All other objects, this is probably just objects with expressions, but it could also be scripts or plugin objects.
)

FindShouts

#
Gets all Shout objects associated with the given search. There may be zero or more shouts which match the name, either because they simply have identical names, or because the search contains wildcards.
public Shout[] FindShouts(
search
Search term.
)
Array of matching shout objects.

IsMatch

#
Test whether a Shout matches a search term. The search term may just be a string which will be matched against the shout UserName. The search term may contain * and ? wildcards which will be matched against the shout UserName. The search term may be a Guid in string form which will be matched against the shout InstanceId.
public static bool IsMatch(
search,
shout
)

Resolve

#
Attempt to resolve the actual data stored in a global parameter. If the parameter is unsolved, a solution will be attempted. This method has potentially high overhead, but results are cached during solutions. If no match can be found in this document, the parent document (if any) will be searched, and so on up the document parent chain.
public ITree Resolve(
search,
Search string for global data.
caller,
Object which requests this search.
solution,
Solution within which this search happens.
callstack
Callstack.
)
Volatile data inside global parameter or null if parameter could not be found.