@Immutable public class JMessage<T extends net.morimekta.providence.reflect.contained.CMessage<T>> extends Object
| Constructor and Description |
|---|
JMessage(net.morimekta.providence.descriptor.PMessageDescriptor<T> descriptor,
JHelper helper) |
| Modifier and Type | Method and Description |
|---|---|
List<JField> |
declaredOrderFields() |
net.morimekta.providence.descriptor.PMessageDescriptor<T> |
descriptor() |
String |
exceptionBaseClass() |
Optional<JField> |
exceptionMessageField()
If the message has a 'string' field named 'message', which can be used as the 'message' for exceptions.
|
String |
extraImplements() |
String |
getDescriptorClass() |
String |
getExceptionMessageFieldName() |
String |
getProviderClass() |
boolean |
hasAnnotation(net.morimekta.providence.descriptor.PAnnotation annotation)
Check if the annotation is present.
|
boolean |
hasAnnotation(String annotation)
Check if the annotation is present.
|
String |
instanceType()
The short class name of the message.
|
boolean |
isException() |
boolean |
isUnion() |
boolean |
jsonCompactible() |
List<JField> |
numericalOrderFields() |
net.morimekta.providence.PMessageVariant |
variant() |
public net.morimekta.providence.descriptor.PMessageDescriptor<T> descriptor()
public net.morimekta.providence.PMessageVariant variant()
public boolean isException()
public boolean isUnion()
public boolean jsonCompactible()
public String instanceType()
public String getDescriptorClass() throws net.morimekta.providence.generator.GeneratorException
net.morimekta.providence.generator.GeneratorExceptionpublic String getProviderClass() throws net.morimekta.providence.generator.GeneratorException
net.morimekta.providence.generator.GeneratorExceptionpublic String extraImplements()
public String exceptionBaseClass()
public Optional<JField> exceptionMessageField()
public boolean hasAnnotation(net.morimekta.providence.descriptor.PAnnotation annotation)
annotation - The annotation to check.public boolean hasAnnotation(String annotation)
annotation - The annotation to check.Copyright © 2015–2020 morimekta.net. All rights reserved.