[This is preliminary documentation and is subject to change.]
The OrderedRegistry T type exposes the following members.Constructors
Name | Description | |
---|---|---|
![]() | OrderedRegistry T | Initializes a new instance of the OrderedRegistry T class |
![]() | OrderedRegistry T (Boolean) | Initializes a new instance of the OrderedRegistry T class |
Methods
Name | Description | |
---|---|---|
![]() | Clear |
Deletes all items from ordered registry
(Overrides Registry T Clear .) |
![]() | ContainsName | (Inherited from Registry T .) |
![]() | ![]() | Determines whether the specified object is equal to the current object. (Inherited from ![]() |
![]() | ![]() | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from ![]() |
![]() | GetEnumerator | (Inherited from Registry T .) |
![]() | ![]() | Serves as the default hash function. (Inherited from ![]() |
![]() | GetOrRegister TContext (String, Func TContext, T , TContext) |
Tries to find an item by name, and returns it if it is found, otherwise calls a factory function supplying context value and registers the obtained
new item. The first lookup is performed in a lock-free way and if an item is found then it is immediately returned.
The second check and factory call operation is performed atomically under the lock to ensure consistency
(Inherited from Registry T .) |
![]() | GetOrRegister TContext (String, Func TContext, T , TContext, Boolean ) |
Tries to find an item by name, and returns it if it is found, otherwise calls a factory function supplying context value and registers the obtained
new item. The first lookup is performed in a lock-free way and if an item is found then it is immediately returned.
The second check and factory call operation is performed atomically under the lock to ensure consistency
(Inherited from Registry T .) |
![]() | ![]() | Gets the (Inherited from ![]() ![]() |
![]() | JustRegistered | (Overrides Registry T JustRegistered(T).) |
![]() | JustReplaced | (Overrides Registry T JustReplaced(T, T).) |
![]() | JustUnregistered | (Overrides Registry T JustUnregistered(T).) |
![]() | ![]() | Creates a shallow copy of the current (Inherited from ![]() ![]() |
![]() | Register |
Registers item and returns true if it was registered, false if this named instance already existed in the list
(Inherited from Registry T .) |
![]() | RegisterOrReplace(T) |
Registers item and returns true if it was registered, false if this named instance already existed and was replaced
(Inherited from Registry T .) |
![]() | RegisterOrReplace(T, T ) |
Registers item and returns true if it was registered, false if this named instance already existed and was replaced
(Inherited from Registry T .) |
![]() | ![]() | Returns a string that represents the current object. (Inherited from ![]() |
![]() | TryGetValue | (Inherited from Registry T .) |
![]() | Unregister(String) |
Unregisters item by name and returns true if it was unregistered, false if it did not exist
(Inherited from Registry T .) |
![]() | Unregister(T) |
Unregisters item and returns true if it was unregistered, false if it did not exist
(Inherited from Registry T .) |
Extension Methods
Fields
Name | Description | |
---|---|---|
![]() | m_Sync | (Inherited from Registry T .) |
Properties
Name | Description | |
---|---|---|
![]() | Count |
Returns the number of entries in the registry
(Inherited from Registry T .) |
![]() | IsCaseSensitive |
Returns true if the instance differentiates names by case
(Inherited from Registry T .) |
![]() | Item Int32 |
Tries to return an item by its position index in ordered set of items that this registry keeps.
Null is returned when index is out of bounds.
Note: since registry does reading in a lock-free manner, it is possible to have an inconsistent read snapshot
of ordered items which may capture items that have already/not yet been added to the registry
|
![]() | Item String |
Returns a value by name or null if not found
(Inherited from Registry T .) |
![]() | Names | (Inherited from Registry T .) |
![]() | OrderedValues |
Returns items that registry contains ordered by their Order property.
The returned sequence is pre-sorted during alteration of registry, so this property access is efficient.
Note: since registry does reading in a lock-free manner, it is possible to have an inconsistent read snapshot
of ordered items which may capture items that have already/not yet been added to the registry
|
![]() | Values | (Inherited from Registry T .) |
Explicit Interface Implementations
Name | Description | |
---|---|---|
![]() ![]() | IEnumerable GetEnumerator | (Inherited from Registry T .) |
See Also