Class JrpcgenEnum.Element

All Implemented Interfaces:
JrpcgenItem
Enclosing class:
JrpcgenEnum

public static class JrpcgenEnum.Element extends JrpcgenConst
  • Constructor Details

  • 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.