Class JsonCodecParseMethodGenerator

java.lang.Object
com.hedera.pbj.compiler.impl.generators.json.JsonCodecParseMethodGenerator

class JsonCodecParseMethodGenerator extends Object
Code to generate the parse method for Codec classes.
  • Constructor Details

    • JsonCodecParseMethodGenerator

      JsonCodecParseMethodGenerator()
  • Method Details

    • generateUnsetOneOfConstants

      static String generateUnsetOneOfConstants(List<Field> fields)
      Because all UNSET OneOf values are the same and we use them often we create a static constant for them and just reuse it throughout codec code.
      Parameters:
      fields - the fields to generate for
      Returns:
      code for constants
    • generateParseObjectMethod

      static String generateParseObjectMethod(String modelClassName, List<Field> fields)