Class FetchMappedObjectDBMethodGenerator

All Implemented Interfaces:
MethodGenerator

public class FetchMappedObjectDBMethodGenerator extends NestedFetchDBMethodGenerator
Generator that creates the default data fetching methods
  • Constructor Details

  • Method Details

    • generate

      public no.sikt.graphitron.javapoet.MethodSpec generate(ObjectField target)
      Specified by:
      generate in class AbstractSchemaMethodGenerator<ObjectField,ObjectDefinition>
      Parameters:
      target - A ObjectField for which a method should be generated for. This must reference an object with the "table" directive set.
      Returns:
      The complete javapoet MethodSpec based on the provided reference field.
    • getHelperMethodCallForNestedField

      protected no.sikt.graphitron.javapoet.CodeBlock getHelperMethodCallForNestedField(ObjectField field, FetchContext context)
      Description copied from class: FetchDBMethodGenerator
      Override this method to provide a helper method call for nested record type fields. Return null to use inline generation.
      Overrides:
      getHelperMethodCallForNestedField in class FetchDBMethodGenerator
    • generateAll

      public List<no.sikt.graphitron.javapoet.MethodSpec> generateAll()
      Returns:
      List of complete javapoet MethodSpec that can be generated for this object.