com.google.protobuf.DescriptorProtos.OneofDescriptorProto Java Examples

The following examples show how to use com.google.protobuf.DescriptorProtos.OneofDescriptorProto. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: Descriptors.java    From play-store-api with GNU General Public License v3.0 5 votes vote down vote up
private OneofDescriptor(final OneofDescriptorProto proto,
                        final FileDescriptor file,
                        final Descriptor parent,
                        final int index)
                 throws DescriptorValidationException {
  this.proto = proto;
  fullName = computeFullName(file, parent, proto.getName());
  this.file = file;
  this.index = index;

  containingType = parent;
  fieldCount = 0;
}
 
Example #2
Source File: Oneof.java    From api-compiler with Apache License 2.0 4 votes vote down vote up
public static Oneof create(ProtoContainerElement parent, OneofDescriptorProto proto,
    String path) {
  return new Oneof(parent, proto, path);
}
 
Example #3
Source File: Oneof.java    From api-compiler with Apache License 2.0 4 votes vote down vote up
private Oneof(ProtoContainerElement parent, OneofDescriptorProto proto, String path) {
  super(parent, proto.getName(), path);
  this.proto = proto;
}
 
Example #4
Source File: Descriptors.java    From play-store-api with GNU General Public License v3.0 4 votes vote down vote up
private void setProto(final OneofDescriptorProto proto) {
  this.proto = proto;
}
 
Example #5
Source File: MessageDefinition.java    From protobuf-dynamic with Apache License 2.0 4 votes vote down vote up
public OneofBuilder addOneof(String oneofName) {
	mMsgTypeBuilder.addOneofDecl(OneofDescriptorProto.newBuilder().setName(oneofName).build());
	return new OneofBuilder(this, mOneofIndex++);
}