Share via


ElementNameProvider.SetUniqueName Method

Definition

Overloads

SetUniqueName(ElementLink, DomainRoleInfo, String)

Sets unique name on an element link if it's not already unique (and not the base name)

SetUniqueName(ModelElement, ModelElement, DomainRoleInfo, String)

Sets unique name on an element.

Sets unique name on an element link if it's not already unique (and not the base name)

public:
 virtual void SetUniqueName(Microsoft::VisualStudio::Modeling::ElementLink ^ link, Microsoft::VisualStudio::Modeling::DomainRoleInfo ^ indexingDomainRole, System::String ^ baseName);
public virtual void SetUniqueName (Microsoft.VisualStudio.Modeling.ElementLink link, Microsoft.VisualStudio.Modeling.DomainRoleInfo indexingDomainRole, string baseName);
abstract member SetUniqueName : Microsoft.VisualStudio.Modeling.ElementLink * Microsoft.VisualStudio.Modeling.DomainRoleInfo * string -> unit
override this.SetUniqueName : Microsoft.VisualStudio.Modeling.ElementLink * Microsoft.VisualStudio.Modeling.DomainRoleInfo * string -> unit
Public Overridable Sub SetUniqueName (link As ElementLink, indexingDomainRole As DomainRoleInfo, baseName As String)

Parameters

link
ElementLink

Element link to assign an unique name.

indexingDomainRole
DomainRoleInfo

Domain role at which link names are indexed (unique among sibling links).

baseName
String

String from which generated name should be derived.

Exceptions

link or embeddedDomainRole is a null reference.

When called outside of modeling transaction context, name property is calculated or other modeling constraints are not satisfied.

There are more than MaxValue elements in container.

Applies to

SetUniqueName(ModelElement, ModelElement, DomainRoleInfo, String)

Sets unique name on an element.

public:
 virtual void SetUniqueName(Microsoft::VisualStudio::Modeling::ModelElement ^ element, Microsoft::VisualStudio::Modeling::ModelElement ^ container, Microsoft::VisualStudio::Modeling::DomainRoleInfo ^ embeddedDomainRole, System::String ^ baseName);
public virtual void SetUniqueName (Microsoft.VisualStudio.Modeling.ModelElement element, Microsoft.VisualStudio.Modeling.ModelElement container, Microsoft.VisualStudio.Modeling.DomainRoleInfo embeddedDomainRole, string baseName);
abstract member SetUniqueName : Microsoft.VisualStudio.Modeling.ModelElement * Microsoft.VisualStudio.Modeling.ModelElement * Microsoft.VisualStudio.Modeling.DomainRoleInfo * string -> unit
override this.SetUniqueName : Microsoft.VisualStudio.Modeling.ModelElement * Microsoft.VisualStudio.Modeling.ModelElement * Microsoft.VisualStudio.Modeling.DomainRoleInfo * string -> unit
Public Overridable Sub SetUniqueName (element As ModelElement, container As ModelElement, embeddedDomainRole As DomainRoleInfo, baseName As String)

Parameters

element
ModelElement

Element to assign an unique name.

container
ModelElement

Container embedding the element.

embeddedDomainRole
DomainRoleInfo

Role played by the element in embedding relationship.

baseName
String

String from which generated name should be derived.

Exceptions

element, container or embeddedDomainRole is a null reference.

When called outside of modeling transaction context, name property is calculated or other modeling constraints are not satisfied.

There are more than MaxValue elements in container.

Applies to