public final class ProtoDomain
extends java.lang.Object
implements java.io.Serializable
Using a domain also grantees that all Descriptors have object equality, just like statically compiled Proto classes Descriptors. A lot of Java code isn't used to the new DynamicMessages an assume always Object equality. Because of this the domain class is immutable.
ProtoDomains aren't assumed to be used on with normal Message descriptors, only with DynamicMessage descriptors.
Modifier and Type | Field and Description |
---|---|
static long |
serialVersionUID |
Modifier and Type | Method and Description |
---|---|
static ProtoDomain |
buildFrom(DescriptorProtos.FileDescriptorSet fileDescriptorSet) |
static ProtoDomain |
buildFrom(Descriptors.Descriptor descriptor) |
static ProtoDomain |
buildFrom(Descriptors.FileDescriptor fileDescriptor) |
static ProtoDomain |
buildFrom(java.io.InputStream inputStream) |
boolean |
contains(Descriptors.Descriptor descriptor) |
boolean |
equals(@Nullable java.lang.Object o) |
Descriptors.Descriptor |
getDescriptor(java.lang.String fullName) |
Descriptors.FieldDescriptor |
getFieldOptionById(int id) |
Descriptors.FileDescriptor |
getFileDescriptor(java.lang.String name) |
int |
hashCode() |
public static final long serialVersionUID
public static ProtoDomain buildFrom(Descriptors.Descriptor descriptor)
public static ProtoDomain buildFrom(DescriptorProtos.FileDescriptorSet fileDescriptorSet)
public static ProtoDomain buildFrom(Descriptors.FileDescriptor fileDescriptor)
public static ProtoDomain buildFrom(java.io.InputStream inputStream) throws java.io.IOException
java.io.IOException
public Descriptors.FileDescriptor getFileDescriptor(java.lang.String name)
public Descriptors.Descriptor getDescriptor(java.lang.String fullName)
public Descriptors.FieldDescriptor getFieldOptionById(int id)
public boolean equals(@Nullable java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public boolean contains(Descriptors.Descriptor descriptor)