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
ConstructorDescriptionAnnotatedTypeDef
(TypeDef typeDef, List<AnnotationDef> annotations) Creates an instance of aAnnotatedTypeDef
record class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theannotations
record component.final boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.final String
toString()
Returns a string representation of this record class.typeDef()
Returns the value of thetypeDef
record component.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface io.micronaut.sourcegen.model.TypeDef
annotated, annotated, instantiateArray, instantiateArray, instantiateArray, isArray, isNullable, isPrimitive, makeNullable
-
Constructor Details
-
AnnotatedTypeDef
Creates an instance of aAnnotatedTypeDef
record class.- Parameters:
typeDef
- the value for thetypeDef
record componentannotations
- the value for theannotations
record 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 thetypeDef
record component.- Returns:
- the value of the
typeDef
record component
-
annotations
Returns the value of theannotations
record component.- Returns:
- the value of the
annotations
record component
-