API reference
API reference
Select your platform
No SDKs available
No versions available

EnumCodeWrapper Class

Wraps around an Enum in code to allow querying and modifying its source code in a single source file.

Constructors

EnumCodeWrapper ( fileIo , enumType , entityName , sourceCodeFile )
Signature
Meta.Conduit.Editor.EnumCodeWrapper.EnumCodeWrapper(IFileIo fileIo, Type enumType, string entityName, string sourceCodeFile)
Parameters
fileIo: IFileIo
enumType: Type
entityName: string
sourceCodeFile: string
EnumCodeWrapper ( fileIo , enumType , sourceCodeFile )
Signature
Meta.Conduit.Editor.EnumCodeWrapper.EnumCodeWrapper(IFileIo fileIo, Type enumType, string sourceCodeFile)
Parameters
fileIo: IFileIo
enumType: Type
sourceCodeFile: string
EnumCodeWrapper ( fileIo , enumName , entityName , enumValues , enumNamespace , sourceCodeFile )
Signature
Meta.Conduit.Editor.EnumCodeWrapper.EnumCodeWrapper(IFileIo fileIo, string enumName, string entityName, IList< WitKeyword > enumValues, string enumNamespace=null, string sourceCodeFile=null)
Parameters
fileIo: IFileIo
enumName: string
entityName: string
enumValues: IList< WitKeyword >
enumNamespace: string
sourceCodeFile: string

Fields

DEFAULT_PATH : const string
Signature
const string Meta.Conduit.Editor.EnumCodeWrapper.DEFAULT_PATH

Methods

AddValue ( keyword )
Signature
void Meta.Conduit.Editor.EnumCodeWrapper.AddValue(WitKeyword keyword)
Parameters
keyword: WitKeyword
Returns
void
AddValue ( value , attribute )
Signature
void Meta.Conduit.Editor.EnumCodeWrapper.AddValue(string value, CodeAttributeDeclaration attribute=null)
Parameters
value: string
attribute: CodeAttributeDeclaration
Returns
void
AddValues ( values )
Adds the supplied values to the enum construct. Values that already exist are ignored.
Signature
void Meta.Conduit.Editor.EnumCodeWrapper.AddValues(IList< WitKeyword > values)
Parameters
values: IList< WitKeyword >  The values to add.
Returns
void
AddValues ( values )
Adds the supplied values to the enum construct. Values that already exist are ignored.
Signature
void Meta.Conduit.Editor.EnumCodeWrapper.AddValues(ICollection< string > values)
Parameters
values: ICollection< string >  The values to add.
Returns
void
ToSourceCode ()
Signature
string Meta.Conduit.Editor.EnumCodeWrapper.ToSourceCode()
Returns
string
WriteToFile ()
Signature
void Meta.Conduit.Editor.EnumCodeWrapper.WriteToFile()
Returns
void

Internal Methods

RemoveValues ( values )
Removes the supplied values to the enum construct. Values that do not exist in the enum are ignored.
Signature
void Meta.Conduit.Editor.EnumCodeWrapper.RemoveValues(IList< string > values)
Parameters
values: IList< string >  The values to remove.
Returns
void