Package org.eclipse.microprofile.graphql
Annotation Interface Type
Maps of the annotated Java class to a GraphQL type.
For example, a user might annotate a class as such:
For example, a user might annotate a class as such:
@Type("Starship")
@Description("A starship in Star Wars")
public class Starship {
private String id;
private String name;
private float length;
// getters/setters...
}
Schema generation of this would result in a stanza such as:
# A starship in Star Wars
type Starship {
id: String
name: String
length: Float
}
-
Optional Element Summary
Optional Elements
-
Element Details
-
value
String value- Returns:
- the name of the GraphQL type.
- Default:
- ""
-