◆ EnumToString()
Return string name of enum value.
DialogPriority prio = DialogPriority.WARNING;
proto void Print(void var, LogLevel level=LogLevel.NORMAL)
Prints content of variable to console/log.
static proto string EnumToString(TypeName e, int enumValue)
Return string name of enum value.
◆ GetAttributes()
| proto external void TypeName.GetAttributes |
( |
out notnull array< Class > | attributes | ) |
|
Return all attributes on class.
class ConfigExample
{
[
Attribute(desc:
"Some bla bla for m_Commands property")]
int m_Prop;
}
void Usage()
{
typename t = ConfigExample;
array<Class> attributes = {};
t.GetAttributes(attributes);
foreach (Class a: attributes)
{
BaseContainerCustomTitleField att = BaseContainerCustomTitleField.Cast(a);
if (att)
{
break;
}
}
}
Definition attributes.c:285
Attribute for setting any string property as custom title.
Definition attributes.c:439
string m_PropertyName
Definition attributes.c:440
◆ GetVariableAttributes()
| proto external void TypeName.GetVariableAttributes |
( |
int | vIdx, |
|
|
out notnull array< Class > | attributes ) |
Return all attributes on class member.
class ConfigExample
{
[
Attribute(desc:
"Some bla bla for m_Prop property")]
int m_Prop;
}
void Usage()
{
typename t = ConfigExample;
array<Class> attributes = {};
t.GetVariableAttributes(0, attributes);
foreach (Class a: attributes)
{
Attribute att = Attribute.Cast(a);
if (att)
{
break;
}
}
}
string m_Desc
Definition attributes.c:298
◆ GetVariableCount()
| proto external int TypeName.GetVariableCount |
( |
| ) |
|
◆ GetVariableName()
| proto external owned string TypeName.GetVariableName |
( |
int | vIdx | ) |
|
◆ GetVariableType()
| proto external TypeName TypeName.GetVariableType |
( |
int | vIdx | ) |
|
◆ GetVariableValue()
| proto external bool TypeName.GetVariableValue |
( |
Class | inst, |
|
|
int | vIdx, |
|
|
out void | val ) |
◆ IsInherited()
| proto external bool TypeName.IsInherited |
( |
TypeName | baseType | ) |
|
Returns true when type is the same as 'baseType', or inherited one.
- Parameters
-
- Returns
bool true when type is the same as 'baseType', or inherited one.
◆ Spawn()
| proto external ref Managed TypeName.Spawn |
( |
| ) |
|
Dynamic variant to new keyword.
It creates new instance of class.
- Returns
instance of class
◆ StringToEnum()
Return enum value from string name.
static proto int StringToEnum(TypeName e, string enumName)
Return enum value from string name.
◆ ToString()
| proto external string TypeName.ToString |
( |
| ) |
|
Returns type name of variable as string.
◆ Empty
The documentation for this interface was generated from the following file:
- Core/generated/Types/typename.c