Microsoft.VisualStudio.Modeling Namespace
The Modeling namespace deals with additions, deletions, and modifications of elements and links when a model is created or modified.
The Modeling namespace classes allow your code to create and modify elements and links within transactions. The Store is the class that represents the contents (elements and links) of a model in memory. Whenever you programmatically make changes to a model, these changes must be done within a Transaction.
You can define rules that are run when certain things happen, such as an element or a link being added, changed, or deleted.
You can also subscribe to be notified when an event such as a transaction being rolled back occurs.
The difference between rules and events is that rules are fired within a transaction while events are fired after a transaction is committed.
Classes
Class | Description | |
---|---|---|
AddRule | Represents a rule that is called when an object is added to the model. | |
AmbiguousMonikerException | The exception that is thrown when a model element to be added to the store has the same moniker as another element already in the store. | |
AncestorVisitorFilter | Use with an ElementWalker to visit all aggregating relationships. | |
BreadthFirstRolePlayerFirstElementWalker | Visits the elements in the model, applying an action to each one. The action can update or accumulate results from the elements that are visited. | |
CalculatedPropertyValueHandler<TElement, TValue> | Base class for calculated domain property handlers. | |
ChainingElementVisitorFilter | Represents a chaining filter, which adds filters to a list. | |
ChangeRule | Represents a rule that is called when the value of a property of an element is changed. | |
ClosureContextHelper | Provides methods to add and retrieve closure context information to and from a particular element walker context. | |
ClosureElementOperation | Represents closure element operations. | |
ClosureFindAndRelateElementOperation | Represents a closure operation to mark a find or create target element operation. | |
ClosureFindAndRelateOrDeleteCopiedElementOperation | Represents a closure operation to find and relate to an element or delete the copied element if the target is not found. | |
ClosureFindElementOperation | Represents a closure operation that marks a find target element operation. | |
ClosureFindOrCreateAndRelateElementOperation | Represents a closure operation that marks a find or create target element operation. | |
ClosureFindOrCreateElementOperation | Represents a closure operation that marks a find or create target element operation. | |
Context | Contains the mapping of transactions to partitions. | |
CopyClosureFilter | Base class for copy closure visitor filter | |
CopyOriginContext | Provides information about the origin of the ElementGroupPrototype. | |
CoreCopyClosure | Copy closure visitor filter | |
CoreCopyClosureBase | Base class for copy closure visitor filter | |
CoreDeleteClosure | Remove closure visitor filter | |
CoreDeleteClosureBase | Base class for remove closure visitor filter | |
CoreDomainModel | Represents the domain model that defines the basic elements used by all domain models. | |
CoreDomainModelSerializationBehavior | A DomainXmlSerializationBehavior implementation for defined behavior CoreDomainModelSerializationBehavior. | |
DefaultVisitorFilter | Visits all aggregate relationships. | |
DeleteRule | Represents a rule that is called when an object is deleted from the model. Executes after the corresponding DeletingRule. | |
DeletingRule | Represents a rule that is called when an element is about to be deleted in the model. | |
DependsOnDomainModelAttribute | Attribute class used to specify the domain model the current domain model extends. | |
DepthFirstElementAndLinkWalker | Visits the elements in the model, applying an action to each one. Links can be included. | |
DepthFirstElementWalker | Enables depth-first traversals of the model starting from a particular element or group of elements. Provides notification of begin and end traversing an element and its descendants. | |
DeserializationEndingEventArgs | Provides data for the DeserializationEnding event and notifies listeners that deserialization has ended. | |
DomainClassInfo | Represents a domain class. | |
DomainClassXmlSerializer | Represents the base class for all generated domain serializers. | |
DomainDataDirectory | Stores metadata about the domain models in the store. | |
DomainDataNotFoundException | This exception is thrown by the DomainDataDirectory class when a domain element that has a specific identity is not found in the directory. | |
DomainModel | Represents a domain model. This is the base class of the domain model of your DSL. | |
DomainModel.DomainMemberInfo | Stores information about a domain property in a domain model. | |
DomainModel.DomainRolePlayerInfo | Stores information that is used by the domain model reflector to locate a domain role. | |
DomainModelExtensionProvider | Defines the MEF contract for a type that provides a mapping between a domain model extension and the domain model it extends | |
DomainModelInfo | Represents a domain model definition. | |
DomainModelOwnerAttribute | In the code generated from a domain type, indicates the domain model in which a domain class is defined.F905 | |
DomainModelSerializerAttribute | Custom attribute used to indicate that a class is a domain model serializer, and the type of domain model it serializes. | |
DomainObjectIdAttribute | Represents the ID of a domain object. | |
DomainObjectInfo | Represents an element in a domain model. | |
DomainPropertyAttribute | Indicates that the target is a domain property of a domain class. | |
DomainPropertyInfo | Represents a property of a domain class. | |
DomainPropertyValueHandler | Represents the base class for domain property value handlers. | |
DomainPropertyValueHandler<TElement, TValue> | Represents the base class for strong-type domain property handlers. | |
DomainPropertyXmlSerializer | The base class for all custom domain property serializers | |
DomainRelationshipAttribute | Indicates that the target is a domain relationship. | |
DomainRelationshipInfo | Represents the metadata about a domain relationship. | |
DomainRelationshipXmlSerializer | Represents the base class for all generated domain serializers for domain relationships. | |
DomainRoleAttribute | Indicates that the target is a domain role of a domain relationship. | |
DomainRoleInfo | Represents a role of a domain relationship. | |
DomainXmlSerializationBehavior | Represents all XML serialization behavior-generated classes. | |
DomainXmlSerializerDirectory | Combines XML serialization behaviors from different domain models together. | |
DomainXmlSerializerDirectoryEntry | Associates one domain class ID to its DomainClassXmlSerializer type. | |
DomainXmlSerializerNamespaceEntry | An tuple that links one Domain Model to its xml namepace type. | |
DomainXmlTypeSerializerDirectoryEntry | An tuple that maps a type to the serializer type to use. | |
ElementAddedEventArgs | Provides data for the ElementAdded event. | |
ElementAddedEventManager | Manages element added events. | |
ElementClosureWalker | Represents a walker that builds closures on model elements. | |
ElementDeletedEventArgs | Provides data for the ElementDeleted event. | |
ElementDeletedEventManager | Manages element removed events. | |
ElementDeletingEventArgs | Provides data for the ElementDeleting event. | |
ElementDeserializedRule | A rule that fires when new ModelElements are created, used by SimpleMonikerResolver to monitor new elements. | |
ElementEventArgs | Provides data for notifications associated with a model element. | |
ElementEventManager | In derived classes, provides a mechanism for observers to register for and be notified of changes to an element within the scope of the store. | |
ElementEventsBegunEventArgs | Provides data for the ElementEventsBegun event. | |
ElementEventsBegunEventManager | Manages events that have begun for elements. | |
ElementEventsEndedEventArgs | Provides data for the ElementEventsEnded event. | |
ElementEventsEndedEventManager | Manages element events ended events. | |
ElementFactory | Represents a factory of domain model objects. | |
ElementGroup | Provides a way to collect elements and element links. | |
ElementGroupContext | Stores context information about an element group. | |
ElementGroupPrototype | Contains the information necessary to recreate a set of elements and links. Used to store elements in tools, on the clipboard, and in a drag operation. | |
ElementLink | Base class for all domain relationships. | |
ElementMovedEventArgs | Provides data for the ElementMoved event. | |
ElementMovedEventManager | Manages element moved events. | |
ElementNameAttribute | Indicates the target domain property provides the element name property. | |
ElementNameProvider | Represents a name provider for domain elements. | |
ElementOperations | Provides common operations that act upon a collection of model elements. | |
ElementPropertyChangedEventArgs | Provides data for the ElementPropertyChanged event. | |
ElementPropertyChangedEventManager | Manages element property changed events. | |
ElementWalker | Enables various traversals of the model starting from a particular element. | |
EmbeddingVisitorFilter | Visits all embedding relationships. | |
EventManagerDirectory | Enables you to add or remove custom code to run when an event is raised. | |
ExistingElementEventManager | In a derived class, manages element events. | |
ExtendsDomainModelAttribute | Obsolete. Indicates the domain model that this domain model extends. | |
ExtensionElement | Base class for all domain model element extensions. Allows a DSL Definition to be extended by a third party. | |
ExtensionElementSerializer | Serializer ExtensionElementSerializer for DomainClass ExtensionElement. | |
ExtensionExtendsElement | DomainRelationship ExtensionExtendsElement Reference relationship between ElementExtension and ModelElement | |
ExtensionExtendsElementSerializer | Serializer ExtensionExtendsElementSerializer for DomainClass ExtensionExtendsElement. | |
GenericEventArgs | Abstract base class for all event arguments for element events. | |
GlobalEventManager | When overridden in a derived class, enables observers to register for and be notified of changes within a store. | |
InternalModelingErrorException | Represents the exception that is thrown when an internal error occurs inside the modeling engine. | |
InvalidDomainModelException | Represents an exception that is thrown when an error is encountered with the metadata assigned to a domain model. | |
ISerializerLocatorExtensions | Provides convenience methods to extend the standard ISerializerLocator interface | |
LinkedElementCollection<T> | Provides a collection of all elements that are linked to an element. | |
MefMetadataConstants | Defines the string constants for the names of domain model MEF metadata keys | |
MergeAbortedException | Represents an exception that is thrown when a merge operation on a domain model is aborted by the user. | |
MergeContext | Provides merge information initially set by the merge process when the objects of a ElementGroupPrototype are reconstituted into the target store. | |
MergeElementGroupEventArgs | Provides data for the MergeElementGroup event. | |
ModelElement | The base class for all domain model elements. All elements and links in a DomainModel are members of this type. | |
ModelingEventArgs | Provides data for modeling events. | |
ModelingException | Represents the base class for several exceptions thrown by the modeling engine. | |
Moniker | Contains an expression used to map to its element. | |
MonikerKey | Represents the key of a Moniker. | |
MoveRule | Represents a rule that is called when an object is moved in the model. | |
Partition | Provides a logical container for elements in a store. | |
PartitionDictionary | Represents a collection of partitions. | |
PropagateDeleteVisitorFilter | Visits all PropagateRemove relationships. | |
PropertyAssignment | Represents a property assignment pair that consists of property ID and a property value. | |
ProtoElement | Represents the prototype class for an element. | |
ProtoElementBase | Represents the prototype for the element. | |
ProtoGroup | Contains the information to re-create an ElementGroup in the context of any store. | |
ProtoLink | Contains the information needed to recreate an ElementLink in any store. | |
ProtoPropertyValue | Contains the information necessary to populate an attribute value for a particular model element. | |
ProtoRolePlayer | Contains the data necessary to set the role player data on an ElementLink. | |
ProvidesExtensionToDomainModelAttribute | Custom attribute used to indicate that a domain model is an extension of another domain model. | |
ReadOnlyLinkedElementCollection<T> | Represents a strongly-typed read-only collection of element instances on the opposite side of a relationship. | |
RedoStackFlushedEventArgs | Event args for the RedoStackFlushed event. | |
RoleAssignment | Provides information to initialize a role that is assigned to a link element. | |
RolePlayerChangedEventArgs | Provides data for the RolePlayerChanged event. | |
RolePlayerChangedEventManager | Manages events that are changed by the role. | |
RolePlayerChangeRule | Represents a rule that is called when a role player in the model changes. | |
RolePlayerOrderChangedEventArgs | Provides data for the RolePlayerOrderChanged event. | |
RolePlayerOrderChangedEventManager | Manages events that are changed when the order of the model elements that are assigned to roles change. | |
RolePlayerPositionChangeRule | Represents a rule that is called when a model element that is assigned to a specific role changes position in a multiple relationship. | |
RootElementSettings | Similar to System.Xml.XmlWriterSettings, this class stores settings that need to be passed to a serializer when serializing a root element. Root element has additional information like schema target namespace, versions, etc., so additional information may be needed. | |
Rule | Abstract class from which different types of store rule can be derived. | |
RuleManager | Controls whether rules are enabled or disabled. | |
RuleOnAttribute | Signifies that the class to which this attribute is applied is a rule. The attribute’s parameter specifies what domain class applies to. | |
SerializationContext | Defines the context of a serialization operation. | |
SerializationContextTransactionExtensions | Extension methods for accessing SerializationContext in the scope of a Transaction | |
SerializationException | Throws a SerializationResult as an exception. | |
SerializationMessage | Represents a serialization message. | |
SerializationResult | Represents a serialization result. | |
SerializationUtilities | Provides utilities for serialization. | |
SimpleMonikerResolver | Resolves simple string references when the model is serialized using the default XML serialization. | |
StandardExtensionLocator | Standard implementation of the IExtensionLocator interface | |
StandardSerializerLocator | Standard implementation of the ISerializerLocator interface | |
Store | The store contains an in-memory representation of the elements and links in one or more models. | |
Transaction | A transaction makes sure that changes that were made to the store are treated as a group that can be committed or rolled back. | |
TransactionBeginningEventArgs | Provides data for the TransactionBeginning event. | |
TransactionBeginningEventManager | Manages transaction beginning events. | |
TransactionBeginningRule | Represents a rule that is called when a transaction is beginning in the model. | |
TransactionCommitEventArgs | Provides data for the TransactionCommit event. | |
TransactionCommittedEventManager | Manages transaction committed events. | |
TransactionCommittingRule | Represents a rule that is called when a transaction is in progress in the model. | |
TransactionContext | Stores user data in a transaction. | |
TransactionEventArgs | Provides data for transaction events. | |
TransactionEventManager | Represents the base class for managing notifications of transaction events. | |
TransactionItem | Represents a transaction item. | |
TransactionLog | Represents a container of transaction events. | |
TransactionManager | Creates Transaction objects and keeps track of the current active transaction. | |
TransactionRollbackEventArgs | Event arguments for rollback-transaction events | |
TransactionRolledBackEventManager | Manages transaction rollback events. | |
TransactionRollingBackRule | Represents a rule that is called when a transaction is being rolled back in the model. | |
UndoItemEventArgs | Provides data for the UndoItem event. | |
UndoManager | Provides the functionality for undo and redo operations. | |
UndoRedoCanceledException | Represents the exception that is thrown when an undo or redo operation has been canceled. | |
VisitorFilters | Returns various standard visitor filters. |
Structures
Structure | Description | |
---|---|---|
ReadOnlyLinkedElementCollection<T>.Enumerator | Provides an enumerator over a ReadOnlyLinkedElementCollection |
Interfaces
Interface | Description | |
---|---|---|
IDomainModelSerializer | Defines the contract for a standard domain model serializer. | |
IElementDirectory | Directory of model elements that are contained within a store or a partition. | |
IElementPartitionMapper | Interface for service used to map elements partitions when reconstituting ElementGroupPrototypes | |
IElementVisitor | Defines the traversal of a model. | |
IElementVisitorFilter | Provides a callback mechanism for filtering out which role players and which relationships should be visited during traversal by an ElementWalker. | |
IExtensionLocator | This interface provides a way for the generated serializers to resolve a schema target namespace to a domain model. | |
IMergeElements | Allows classes in derived models to access the merge functionality on a model element. | |
IMonikerResolver | Resolves a moniker to its element. | |
ISchemaResolver | This interface provides a way for the generated serializers to resolve a schema target namespace. Given an XML file using a particular target namespace, it is important to find the schemas that define the namespace, so the generated serializers can do schema validations properly. | |
ISerializerLocator | This interface provides a way to locate serializers for a domain model. | |
ITransientTransactionContextObject | Interface marker to indicate that a particular object is transient and will be released (and disposed) on transaction commit | |
SElementPartitionMapper | Service identifier for the element group rehydration partition mapping service |
Delegates
Delegate | Description | |
---|---|---|
CanCommitCallback | Represents a callback method for determining whether a transaction can commit based on external criteria. | |
CanUndoRedoCallback | Add an instance to the UndoManager to vote on whether an undo or redo operation can continue. |
Enumerations
Enumeration | Description | |
---|---|---|
CanCommitResult | Enumeration status for the CanCommit callback. | |
ChangeSource | Indicates the source of a change that was made during a transaction. | |
ClosureType | Describes the type of closure to create. | |
CompletionStatus | Describes how the transaction was completed. | |
DeleteState | Identifies the state of the element being deleted. | |
DomainPropertyKind | Specifies the type of domain property. | |
DomainRoleOrder | Specifies the direction of a domain role in a domain relationship. | |
Multiplicity | Indicates the multiplicity for a domain role. | |
PropagatesCopyOption | Enum that lists the various PropagateCopy options. | |
SerializationMessageKind | Formats the serialization message. | |
TimeToFire | Determines when to call the rule. | |
UndoState | Describes the undo state in the UndoManager. | |
VisitorFilterResult | Indicates whether an element should be visited. |