Class InterfaceType
java.lang.Object
software.amazon.jsii.JsiiObject
software.amazon.awscdk.services.appsync.InterfaceType
- All Implemented Interfaces:
IIntermediateType
,software.amazon.jsii.JsiiSerializable
- Direct Known Subclasses:
ObjectType
@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)",
date="2023-06-19T16:30:49.521Z")
@Stability(Experimental)
public class InterfaceType
extends software.amazon.jsii.JsiiObject
implements IIntermediateType
(experimental) Interface Types are abstract types that includes a certain set of fields that other types must include if they implement the interface.
Example:
InterfaceType node = InterfaceType.Builder.create("Node") .definition(Map.of( "id", GraphqlType.string(BaseTypeOptions.builder().isRequired(true).build()))) .build(); ObjectType demo = ObjectType.Builder.create("Demo") .interfaceTypes(List.of(node)) .definition(Map.of( "version", GraphqlType.string(BaseTypeOptions.builder().isRequired(true).build()))) .build();
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final class
(experimental) A fluent builder forInterfaceType
.Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationMode
Nested classes/interfaces inherited from interface software.amazon.awscdk.services.appsync.IIntermediateType
IIntermediateType.Jsii$Default, IIntermediateType.Jsii$Proxy
-
Constructor Summary
ConstructorsModifierConstructorDescriptionInterfaceType
(String name, IntermediateTypeOptions props) protected
InterfaceType
(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protected
InterfaceType
(software.amazon.jsii.JsiiObjectRef objRef) -
Method Summary
Modifier and TypeMethodDescriptionvoid
addField
(AddFieldOptions options) (experimental) Add a field to this Interface Type.(experimental) Create a GraphQL Type representing this Intermediate Type.attribute
(BaseTypeOptions options) (experimental) Create a GraphQL Type representing this Intermediate Type.(experimental) the attributes of this type.(experimental) the directives for this object type.protected List<AuthorizationType>
getModes()
(experimental) the authorization modes for this intermediate type.getName()
(experimental) the name of this type.protected void
setModes
(List<AuthorizationType> value) (experimental) the authorization modes for this intermediate type.toString()
(experimental) Generate the string of this object type.Methods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface software.amazon.awscdk.services.appsync.IIntermediateType
getInterfaceTypes, getIntermediateType, getResolvers, setResolvers
Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Constructor Details
-
InterfaceType
protected InterfaceType(software.amazon.jsii.JsiiObjectRef objRef) -
InterfaceType
protected InterfaceType(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
InterfaceType
@Stability(Experimental) public InterfaceType(@NotNull String name, @NotNull IntermediateTypeOptions props) - Parameters:
name
- This parameter is required.props
- This parameter is required.
-
-
Method Details
-
addField
(experimental) Add a field to this Interface Type.Interface Types must have both fieldName and field options.
- Specified by:
addField
in interfaceIIntermediateType
- Parameters:
options
- the options to add a field. This parameter is required.
-
attribute
(experimental) Create a GraphQL Type representing this Intermediate Type.- Specified by:
attribute
in interfaceIIntermediateType
- Parameters:
options
- the options to configure this attribute.
-
attribute
(experimental) Create a GraphQL Type representing this Intermediate Type.- Specified by:
attribute
in interfaceIIntermediateType
-
toString
(experimental) Generate the string of this object type.- Specified by:
toString
in interfaceIIntermediateType
- Overrides:
toString
in classObject
-
getDefinition
(experimental) the attributes of this type.- Specified by:
getDefinition
in interfaceIIntermediateType
-
getName
(experimental) the name of this type.- Specified by:
getName
in interfaceIIntermediateType
-
getDirectives
(experimental) the directives for this object type.Default: - no directives
- Specified by:
getDirectives
in interfaceIIntermediateType
-
getModes
(experimental) the authorization modes for this intermediate type. -
setModes
(experimental) the authorization modes for this intermediate type.
-