Click or drag to resize

NamedCodeObjectDictionary Class

Represents a dictionary of INamedCodeObjects, allowing multiple entries with the same name. Differs from NamedObjectDictionary in that it can only hold INamedCodeObjects, and NOT metadata (IMemberDefinition/MemberInfo).
Inheritance Hierarchy
SystemObject
  Nova.CodeDOMNamedCodeObjectDictionary

Namespace:  Nova.CodeDOM
Assembly:  Nova.CodeDOM (in Nova.CodeDOM.dll) Version: 7.44.8391.13415
Syntax
C#
public class NamedCodeObjectDictionary : ICollection<INamedCodeObject>, 
	IEnumerable<INamedCodeObject>, IEnumerable

The NamedCodeObjectDictionary type exposes the following members.

Constructors
  NameDescription
Public methodNamedCodeObjectDictionary
Initializes a new instance of the NamedCodeObjectDictionary class
Top
Properties
  NameDescription
Public propertyCount
The number of items in the dictionary.
Public propertyIsReadOnly
Returns true if the ICollection is read-only.
Public propertyIsSynchronized
True if access to the ICollection is synchronized.
Public propertySyncRoot
Gets an object that can be used to synchronize access to the ICollection.
Top
Methods
  NameDescription
Public methodAdd(INamedCodeObject)
Add an INamedCodeObject with the specified name to the dictionary.
Public methodAdd(String, INamedCodeObject)
Add an INamedCodeObject with the specified name to the dictionary.
Public methodClear
Clear all members from the dictionary.
Public methodContains
Check if the dictionary contains the specified INamedCodeObject.
Public methodCopyTo
Copy the objects in the dictionary to the specified array, starting at the specified offset.
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public methodFind
Find INamedCodeObjects in the dictionary by name.
Public methodFindGotoTarget
Find a named goto target in the dictionary by name.
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodRemove(INamedCodeObject)
Remove the INamedCodeObject with the specified name from the dictionary.
Public methodRemove(String, INamedCodeObject)
Remove the INamedCodeObject with the specified name from the dictionary.
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Top
Fields
  NameDescription
Protected field_dictionary
Top
Extension Methods
  NameDescription
Public Extension MethodToString
Format the specified collection into a single string using the specified separating string to separate each item. Null items are converted to empty strings.
(Defined by StringUtil.)
Top
Remarks
This dictionary is used by Blocks to maintain a dictionary of child INamedCodeObjects to allow for lookups by name. It handles multiple entries with the same name (such as overloaded methods, different type parameter counts, or name collisions in invalid code) by storing a NamedCodeObjectGroup object.
See Also