CVB.Net 15.0
Loading...
Searching...
No Matches
NodeDictionaryBase< TNode > Class Template Referenceabstract

Base class for all GevServer node dictionaries. More...

Inherited by NodeDictionary< TNode >, and NodeMap.

Public Member Functions

void Dispose ()
 Disposes of this dictionary and all its nodes.
 
bool ContainsKey (string key)
 Gets whether this dictionaries contains the given key .
 
bool Remove (string key)
 Removes the node identified by the given key .
 

Protected Member Functions

virtual void Dispose (bool disposing)
 Dispose implementation.
 
void AddNode (string key, TNode value)
 Adds a new TNode value associated to the given key .
 
bool RemoveNode (string key)
 Removes the node at the given key .
 
TNode GetNode (string key)
 Actual implementation for getting nodes.
 
bool TryGetNode (string key, out TNode value)
 Tries to get the TNode value with the given key .
 

Properties

bool IsDisposed [get]
 Gets whether this dictionary has been disposed.
 
IDictionary< string, TNode > Nodes = new Dictionary<string, TNode>() [get]
 Gets the dictionary holding all node objects.
 
TNode this[string key] [get, set]
 Indexer of this dictionary to get/add TNode objects.
 
int Count [get]
 Gets the number of TNodes in this dictionary.
 
bool IsReadOnly [get]
 Gets whether this dictionary is read only.
 
ICollection< string > Keys [get]
 Gets the keys for all nodes.
 
ICollection< TNode > Values [get]
 Gets all the TNodes in this dictionary.
 

Detailed Description

Base class for all GevServer node dictionaries.

Template Parameters
TNode
Type Constraints
TNode :Node 

Member Function Documentation

◆ AddNode()

void AddNode ( string key,
TNode value )
abstractprotected

Adds a new TNode value associated to the given key .

Parameters
keyKey to identify value .
valueTNode to store.

◆ ContainsKey()

bool ContainsKey ( string key)

Gets whether this dictionaries contains the given key .

Parameters
keyKey to find.
Returns
true if key was found; false if not.

◆ Dispose()

virtual void Dispose ( bool disposing)
protectedvirtual

Dispose implementation.

Parameters
disposingtrue if called from IDisposable.Dispose; false if called from finalizer.

Reimplemented in NodeMap.

◆ GetNode()

TNode GetNode ( string key)
protected

Actual implementation for getting nodes.

Parameters
keyNode key to find TNode object.
Returns
The TNode associated with the key .

◆ Remove()

bool Remove ( string key)

Removes the node identified by the given key .

Parameters
keyKey to identify the node to remove.
Returns
true if TNode object was removed; false if not.

◆ RemoveNode()

bool RemoveNode ( string key)
abstractprotected

Removes the node at the given key .

Parameters
keyNode key to identify entry to remove.
Returns
true if the key was actually removed; false otherwise.

◆ TryGetNode()

bool TryGetNode ( string key,
out TNode value )
protected

Tries to get the TNode value with the given key .

Parameters
keyKey of node to find.
valueVariable to receive found node.
Returns
true if key was found; false if not.

Property Documentation

◆ this[string key]

TNode this[string key]
getset

Indexer of this dictionary to get/add TNode objects.

Parameters
keyNode key to find TNode object.
Returns
The TNode associated with the key .