Package io.micronaut.sourcegen.model
Record Class TypeDef.AnnotatedTypeDef
java.lang.Object
java.lang.Record
io.micronaut.sourcegen.model.TypeDef.AnnotatedTypeDef
- Record Components:
typeDef- The raw type definitionannotations- List of annotations to associate
- All Implemented Interfaces:
TypeDef,TypeDef.Annotated
- Enclosing interface:
- TypeDef
public static record TypeDef.AnnotatedTypeDef(TypeDef typeDef, List<AnnotationDef> annotations)
extends Record
implements TypeDef.Annotated
A combined type for representing a TypeDef with annotations.
- Since:
- 1.4
- Author:
- Elif Kurtay
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.micronaut.sourcegen.model.TypeDef
TypeDef.Annotated, TypeDef.AnnotatedTypeDef, TypeDef.Array, TypeDef.Primitive, TypeDef.TypeVariable, TypeDef.Wildcard -
Field Summary
-
Constructor Summary
ConstructorsConstructorDescriptionAnnotatedTypeDef(TypeDef typeDef, List<AnnotationDef> annotations) Creates an instance of aAnnotatedTypeDefrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theannotationsrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.typeDef()Returns the value of thetypeDefrecord component.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface io.micronaut.sourcegen.model.TypeDef
annotated, annotated, instantiateArray, instantiateArray, instantiateArray, isArray, isNullable, isPrimitive, makeNullable
-
Constructor Details
-
AnnotatedTypeDef
Creates an instance of aAnnotatedTypeDefrecord class.- Parameters:
typeDef- the value for thetypeDefrecord componentannotations- the value for theannotationsrecord component
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
typeDef
Returns the value of thetypeDefrecord component.- Returns:
- the value of the
typeDefrecord component
-
annotations
Returns the value of theannotationsrecord component.- Returns:
- the value of the
annotationsrecord component
-