Class AdaptWithHelper
- java.lang.Object
-
- io.smallrye.graphql.schema.helper.AdaptWithHelper
-
public class AdaptWithHelper extends Object
Helping with object adapters. This adds support for Adapting one type to another.- Author:
- Phillip Kruger (phillip.kruger@redhat.com)
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Optional<AdaptWith>getAdaptWith(Direction direction, ReferenceCreator referenceCreator, Field field, Annotations annotations)Get the adaptWith for a certain field (if any)static Optional<AdaptWith>getAdaptWith(Direction direction, ReferenceCreator referenceCreator, Reference r, Annotations annotations)Get the adapt with for a certain reference.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.static booleanshouldCreateTypeInSchema(Annotations annotations)
-
-
-
Method Detail
-
shouldCreateTypeInSchema
public static boolean shouldCreateTypeInSchema(Annotations annotations)
-
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
-
-