Package org.acplt.oncrpc.apps.jrpcgen

# Class JrpcgenEnum.Element

java.lang.Object
org.acplt.oncrpc.apps.jrpcgen.JrpcgenDocumentable
org.acplt.oncrpc.apps.jrpcgen.JrpcgenXdrDefinition
org.acplt.oncrpc.apps.jrpcgen.JrpcgenConst
org.acplt.oncrpc.apps.jrpcgen.JrpcgenEnum.Element

All Implemented Interfaces:
  `JrpcgenItem`

Enclosing class:
  `JrpcgenEnum`

public static class JrpcgenEnum.Element extends JrpcgenConst

## Nested Class Summary

## Nested classes/interfaces inherited from class org.acplt.oncrpc.apps.jrpcgen.JrpcgenConst

`JrpcgenConst.Table`

## Nested classes/interfaces inherited from class org.acplt.oncrpc.apps.jrpcgen.JrpcgenXdrDefinition

`JrpcgenXdrDefinition.Type`

## Field Summary

### Fields inherited from class org.acplt.oncrpc.apps.jrpcgen.JrpcgenDocumentable

`documentation`

## Constructor Summary

Constructors
Constructor
Description
`Element(JrpcgenContext context, String identifier, String value)`

## Method Summary

Modifier and Type
Method
Description
`String`
`getAsCaseValue(String forEnclosure)`
Delivers a case value representation of the constant.
`String`
`getAsRValue(String forEnclosure)`
Delivers an r-value representation of the constant.
`void`
`writeDeclaration(JrpcgenJavaFile javaFile)`

### Methods inherited from class org.acplt.oncrpc.apps.jrpcgen.JrpcgenConst

`detectIdentifier, dump, dump, getAsCaseValue, getAsRValue, getAsRValue, getContext, getEnclosure, getForEnclosure, getValue, getValueAsRValue, resolveValue, setEnclosure, setValue, toString`

### Methods inherited from class org.acplt.oncrpc.apps.jrpcgen.JrpcgenXdrDefinition

`getIdentifier, getXdrType, isConst, isEnum, isStruct, isTypedef, isUnion`

### Methods inherited from class org.acplt.oncrpc.apps.jrpcgen.JrpcgenDocumentable

`appendDeprecatedOrNothing, appendDeprecatedOrNothing, documentationIsEmpty, documentationIsProvided, emptyDocumentation, getDocumentation, getIdentedDocu, getIdentedDocu, isDeprecated, writeDocumentation, writeDocumentation`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

## Constructor Details

### Element

public Element(JrpcgenContext context, String identifier, String value)

## Method Details

### writeDeclaration

public void writeDeclaration(JrpcgenJavaFile javaFile)

Overrides:
  `writeDeclaration` in class `JrpcgenConst`

### getAsRValue

public String getAsRValue(String forEnclosure)
Description copied from class: `JrpcgenConst`
Delivers an r-value representation of the constant.

The passed enclosure name identifies the target enclosure (namespace), where the requested constant representation is intended to be used.

Overrides:
  `getAsRValue` in class `JrpcgenConst`
Parameters:
  `forEnclosure` - The name of the target enclosure.
Returns:
  One of the following representations will be returned:
  - The value of the constant, if the constant is a global constant.
  - The identifier of the constant, if the constant lives in the target enclosure.
  - The joined version of the enclosure the constant lives in and the identifier of the constant, delimited by a dot.

### getAsCaseValue

public String getAsCaseValue(String forEnclosure)
Description copied from class: `JrpcgenConst`
Delivers a case value representation of the constant.

The passed enclosure name identifies the target enclosure (namespace), where the requested constant representation is intended to be used.

Overrides:
  `getAsCaseValue` in class `JrpcgenConst`
Parameters:
  `forEnclosure` - The name of the target enclosure.
Returns:
  One of the following representations will be returned:
  - The value of the constant, if the constant is a global constant.
  - The identifier of the constant, if the constant lives in the target enclosure.
  - The joined version of the enclosure the constant lives in and the identifier of the constant, delimited by a dot.