EnumConstant

/**
* @brief An enum constant, also a class field.
*/

Inherit from EnumConstantDO

Primary key: element_hash_id: int

schema EnumConstant extends EnumConstantDO {
  @primary element_hash_id: int,
  name: string,
  parent_hash_id: int,
  location_hash_id: int,
  printable_text: string
}

EnumConstant::getName

/**
* @brief gets the name of this element.
* @return string
*/
pub fn getName(self: EnumConstant) -> string;

EnumConstant::getLocationHashId

/**
* @brief gets the location hash id of this element.
* @return int
*/
pub fn getLocationHashId(self: EnumConstant) -> int;

EnumConstant::getParentHashId

/**
* @brief gets the parent hash id of this element.
* @return int
*/
pub fn getParentHashId(self: EnumConstant) -> int;

EnumConstant::getParent

/**
* @brief gets the ast element parent of the element.
* @return ElementParent 
*/
pub fn getParent(self: EnumConstant) -> Class;

EnumConstant::getAnAncestor

/**
* @brief gets an ancestor of the element.
* @return ElementParent 
*/
pub fn getAnAncestor(self: EnumConstant) -> *ElementParent;

EnumConstant::getPrintableText

/**
* @brief gets a printed representation of this element, including its structure where applicable.
* @return string.
*/
pub fn getPrintableText(self: EnumConstant) -> string;

EnumConstant::getLocation

/**
* @brief gets the location for the element.
* @return Location
*/
pub fn getLocation(self: EnumConstant) -> Location;

EnumConstant::__all__

Data constraint method.

pub fn __all__(db: JavaDB) -> *EnumConstant;

EnumConstant::getType

/**
* @brief gets the type of the element.
* @return Type 
*/
pub fn getType(self: EnumConstant) -> Type;

EnumConstant::getMatchedFieldByIndex

/**
* @brief gets the corresponding field of the element by a given index, if any.
* @return Field 
*/
pub fn getMatchedFieldByIndex(self: EnumConstant, i: int) -> Field;

EnumConstant::getInitializer

/**
* @brief gets the class body attached to the enum constant declaration.
* @return AnonymousClass 
*/
pub fn getInitializer(self: EnumConstant) -> AnonymousClass;

EnumConstant::getValueByField

/**
* @brief gets the corresponding enum value of the element by a given field, if any.
* @return Expression 
*/
pub fn getValueByField(self: EnumConstant, f: Field) -> Expression;

EnumConstant::getValueList

/**
* @brief gets the value list of the element.
* @return ExpressionList 
*/
pub fn getValueList(self: EnumConstant) -> ExpressionList;

EnumConstant::getValueByIndex

/**
* @brief gets the value of the element by a given index.
* @return Expression 
*/
pub fn getValueByIndex(self: EnumConstant, i: int) -> Expression;

EnumConstant::getDefaultValue

/**
* @brief gets the default value of the element.
* @return string 
*/
pub fn getDefaultValue(self: EnumConstant) -> string;