Package com.linecorp.armeria.server.docs
Class StructInfo
java.lang.Object
com.linecorp.armeria.server.docs.StructInfo
- All Implemented Interfaces:
NamedTypeInfo
Metadata about a struct type.
-
Constructor Summary
ConstructorDescriptionStructInfo
(String name, @Nullable String alias, Iterable<FieldInfo> fields, DescriptionInfo descriptionInfo) Creates a new instance.StructInfo
(String name, Iterable<FieldInfo> fields) Creates a new instance.StructInfo
(String name, Iterable<FieldInfo> fields, DescriptionInfo descriptionInfo) Creates a new instance. -
Method Summary
Modifier and TypeMethodDescriptionalias()
Returns the alias of thename()
.Returns the description information of this struct.boolean
fields()
Returns the metadata about the fields of the type.Returns all enum, struct and exception types referred by this type.int
hashCode()
name()
Returns the fully qualified type name.toString()
Returns a newStructInfo
with the specifiedalias
.withDescriptionInfo
(DescriptionInfo descriptionInfo) Returns a newStructInfo
with the specifiedDescriptionInfo
.withFields
(Iterable<FieldInfo> fields) Returns a newStructInfo
with the specifiedFieldInfo
s.
-
Constructor Details
-
Method Details
-
name
Description copied from interface:NamedTypeInfo
Returns the fully qualified type name.- Specified by:
name
in interfaceNamedTypeInfo
-
alias
Returns the alias of thename()
. An alias could be set when aStructInfo
has two different names.For example, if a
StructInfo
is extracted from acom.google.protobuf.Message
, thename()
is set to the full name defined in the proto file and thealias()
is set to the name of the generatedClass
. -
withAlias
Returns a newStructInfo
with the specifiedalias
. Returnsthis
if thisStructInfo
has the sameFieldInfo
s. -
fields
Returns the metadata about the fields of the type. -
withFields
Returns a newStructInfo
with the specifiedFieldInfo
s. Returnsthis
if thisStructInfo
has the sameFieldInfo
s. -
descriptionInfo
Returns the description information of this struct.- Specified by:
descriptionInfo
in interfaceNamedTypeInfo
-
withDescriptionInfo
Returns a newStructInfo
with the specifiedDescriptionInfo
. Returnsthis
if thisStructInfo
has the sameDescriptionInfo
. -
findNamedTypes
Description copied from interface:NamedTypeInfo
Returns all enum, struct and exception types referred by this type.- Specified by:
findNamedTypes
in interfaceNamedTypeInfo
-
equals
-
hashCode
public int hashCode() -
toString
-