ElementHelpersRenameProperty Method |
Renames a property by removing the old key and adding the stored value to the new key.
If property does not exist, nothing occurs.
Namespace:
VelocityGraph.Frontenac.Blueprints.Util
Assembly:
VelocityGraph (in VelocityGraph.dll) Version: 11.1.0.0 (11.1)
Syntax public static void RenameProperty(
this IEnumerable<IElement> elements,
string oldKey,
string newKey
)
<ExtensionAttribute>
Public Shared Sub RenameProperty (
elements As IEnumerable(Of IElement),
oldKey As String,
newKey As String
)
public:
[ExtensionAttribute]
static void RenameProperty(
IEnumerable<IElement^>^ elements,
String^ oldKey,
String^ newKey
)
[<ExtensionAttribute>]
static member RenameProperty :
elements : IEnumerable<IElement> *
oldKey : string *
newKey : string -> unit
Parameters
- elements
- Type: System.Collections.GenericIEnumerableIElement
the elements to rename - oldKey
- Type: SystemString
the key to rename - newKey
- Type: SystemString
the key to rename to
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type
IEnumerableIElement. When you use instance method syntax to call this method, omit the first parameter. For more information, see
Extension Methods (Visual Basic) or
Extension Methods (C# Programming Guide).
See Also