Class AdaptWithHelper
java.lang.Object
io.smallrye.graphql.schema.helper.AdaptWithHelper
Helping with object adapters.
This adds support for Adapting one type to another.
- Author:
- Phillip Kruger (phillip.kruger@redhat.com)
-
Method Summary
Modifier and TypeMethodDescriptiongetAdaptWith(Direction direction, ReferenceCreator referenceCreator, Field field, Annotations annotations) Get the adaptWith for a certain field (if any)getAdaptWith(Direction direction, ReferenceCreator referenceCreator, Reference r, Annotations annotations) Get the adapt with for a certain reference.getAdaptWith(Direction direction, ReferenceCreator referenceCreator, Reference r, Annotations annotations, io.smallrye.graphql.schema.helper.AdaptWithHelper.AdapterType adapterType) Get the adapt with for a certain reference.static booleanshouldCreateTypeInSchema(Annotations annotations)
-
Method Details
-
shouldCreateTypeInSchema
-
getAdaptWith
public static Optional<AdaptWith> getAdaptWith(Direction direction, ReferenceCreator referenceCreator, Field field, Annotations annotations) Get the adaptWith for a certain field (if any)- Parameters:
direction-referenceCreator-field-annotations- the annotations- Returns:
- Potentially an AdaptWith model
-
getAdaptWith
public static Optional<AdaptWith> getAdaptWith(Direction direction, ReferenceCreator referenceCreator, Reference r, Annotations annotations, io.smallrye.graphql.schema.helper.AdaptWithHelper.AdapterType adapterType) Get the adapt with for a certain reference.- Parameters:
direction-referenceCreator-r-annotations- the annotationsadapterType-- Returns:
- Potentially a AdaptWith model
-
getAdaptWith
public static Optional<AdaptWith> getAdaptWith(Direction direction, ReferenceCreator referenceCreator, Reference r, Annotations annotations) Get the adapt with for a certain reference.- Parameters:
direction-referenceCreator-r-annotations- the annotations- Returns:
- Potentially a AdaptWith model
-