Package no.sikt.graphitron.generators.db
Class FetchMultiTableDBMethodGenerator
java.lang.Object
no.sikt.graphitron.generators.abstractions.AbstractSchemaMethodGenerator<ObjectField,ObjectDefinition>
no.sikt.graphitron.generators.abstractions.DBMethodGenerator<ObjectField>
no.sikt.graphitron.generators.db.FetchDBMethodGenerator
no.sikt.graphitron.generators.db.FetchMultiTableDBMethodGenerator
- All Implemented Interfaces:
MethodGenerator
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final StringFields inherited from class no.sikt.graphitron.generators.db.FetchDBMethodGenerator
conditionsShouldFallbackToFalse, ELEMENT_NAME, resolverKeyParamNameFields inherited from class no.sikt.graphitron.generators.abstractions.AbstractSchemaMethodGenerator
dependencyMap, localObject, processedSchema -
Constructor Summary
ConstructorsConstructorDescriptionFetchMultiTableDBMethodGenerator(ObjectDefinition localObject, ProcessedSchema processedSchema) -
Method Summary
Modifier and TypeMethodDescriptionno.sikt.graphitron.javapoet.MethodSpecgenerate(ObjectField target) List<no.sikt.graphitron.javapoet.MethodSpec> List<no.sikt.graphitron.javapoet.MethodSpec> protected no.sikt.graphitron.javapoet.CodeBlockgetHelperMethodCallForNestedField(ObjectField field, FetchContext context) Generates a helper method call for nested record type fields.Methods inherited from class no.sikt.graphitron.generators.db.FetchDBMethodGenerator
createAliasDeclarations, createAliasDeclarations, createOrderFieldsBlock, createOrderFieldsDeclarationBlock, createSeekAndLimitBlock, createSelectConditions, createSelectJoins, createSelectJoins, formatJooqConditions, formatWhereContents, generateCorrelatedSubquery, generateForField, generateForField, generateForUnionField, generateHelperMethodName, generateNestedMethodName, generateSelectRow, getInitialKey, getInputConditions, getReturnType, getSelectCode, getSpecBuilder, inferFieldNamingConvention, isRoot, wrapInField, wrapInMultisetMethods inherited from class no.sikt.graphitron.generators.abstractions.DBMethodGenerator
getDefaultSpecBuilder, getDefaultSpecBuilderMethods inherited from class no.sikt.graphitron.generators.abstractions.AbstractSchemaMethodGenerator
createServiceDependency, declareAllServiceClasses, declareAllServiceClasses, declareAllServiceClassesInAliasSet, getDataFetcherWiring, getDependencyMap, getLocalObject, getLocalTable, getTypeResolverWiring
-
Field Details
-
UNION_KEYS_QUERY
-
VAR_REPRESENTATIONS
-
VAR_FILTERED_REPRESENTATIONS
-
TYPE_FIELD
- See Also:
-
DATA_FIELD
- See Also:
-
PK_FIELDS
- See Also:
-
INNER_ROW_NUM
- See Also:
-
-
Constructor Details
-
FetchMultiTableDBMethodGenerator
public FetchMultiTableDBMethodGenerator(ObjectDefinition localObject, ProcessedSchema processedSchema)
-
-
Method Details
-
generate
- Specified by:
generatein classAbstractSchemaMethodGenerator<ObjectField,ObjectDefinition> - Returns:
- The complete javapoet
MethodSpecbased on the provided target.
-
getHelperMethodCallForNestedField
protected no.sikt.graphitron.javapoet.CodeBlock getHelperMethodCallForNestedField(ObjectField field, FetchContext context) Description copied from class:FetchDBMethodGeneratorGenerates a helper method call for nested record type fields. This base implementation generates the root-level helper method call.- Overrides:
getHelperMethodCallForNestedFieldin classFetchDBMethodGenerator- Parameters:
field- The field to generate the helper method call forcontext- The fetch context (unused in base implementation)- Returns:
- CodeBlock containing the helper method call, or null to use inline generation
-
generateWithSubselectMethods
public List<no.sikt.graphitron.javapoet.MethodSpec> generateWithSubselectMethods(ObjectField target) -
generateAll
- Returns:
- List of complete javapoet
MethodSpecthat can be generated for this object.
-