All Downloads are FREE. Search and download functionalities are using the official Maven repository.

grpc.permission_messages.ExplicitPermissions Maven / Gradle / Ivy

There is a newer version: 0.119.4
Show newest version
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: permissionmessages.proto

package grpc.permission_messages;

/**
 * Protobuf type {@code permission_messages.ExplicitPermissions}
 */
public final class ExplicitPermissions extends
    com.google.protobuf.GeneratedMessageV3 implements
    // @@protoc_insertion_point(message_implements:permission_messages.ExplicitPermissions)
    ExplicitPermissionsOrBuilder {
private static final long serialVersionUID = 0L;
  // Use ExplicitPermissions.newBuilder() to construct.
  private ExplicitPermissions(com.google.protobuf.GeneratedMessageV3.Builder builder) {
    super(builder);
  }
  private ExplicitPermissions() {
    permissions_ = java.util.Collections.emptyList();
  }

  @java.lang.Override
  @SuppressWarnings({"unused"})
  protected java.lang.Object newInstance(
      UnusedPrivateParameter unused) {
    return new ExplicitPermissions();
  }

  public static final com.google.protobuf.Descriptors.Descriptor
      getDescriptor() {
    return grpc.permission_messages.Permissionmessages.internal_static_permission_messages_ExplicitPermissions_descriptor;
  }

  @java.lang.Override
  protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
      internalGetFieldAccessorTable() {
    return grpc.permission_messages.Permissionmessages.internal_static_permission_messages_ExplicitPermissions_fieldAccessorTable
        .ensureFieldAccessorsInitialized(
            grpc.permission_messages.ExplicitPermissions.class, grpc.permission_messages.ExplicitPermissions.Builder.class);
  }

  public static final int PERMISSIONS_FIELD_NUMBER = 1;
  @SuppressWarnings("serial")
  private java.util.List permissions_;
  /**
   * repeated .permission_messages.PermissionsType permissions = 1;
   */
  @java.lang.Override
  public java.util.List getPermissionsList() {
    return permissions_;
  }
  /**
   * repeated .permission_messages.PermissionsType permissions = 1;
   */
  @java.lang.Override
  public java.util.List 
      getPermissionsOrBuilderList() {
    return permissions_;
  }
  /**
   * repeated .permission_messages.PermissionsType permissions = 1;
   */
  @java.lang.Override
  public int getPermissionsCount() {
    return permissions_.size();
  }
  /**
   * repeated .permission_messages.PermissionsType permissions = 1;
   */
  @java.lang.Override
  public grpc.permission_messages.PermissionsType getPermissions(int index) {
    return permissions_.get(index);
  }
  /**
   * repeated .permission_messages.PermissionsType permissions = 1;
   */
  @java.lang.Override
  public grpc.permission_messages.PermissionsTypeOrBuilder getPermissionsOrBuilder(
      int index) {
    return permissions_.get(index);
  }

  private byte memoizedIsInitialized = -1;
  @java.lang.Override
  public final boolean isInitialized() {
    byte isInitialized = memoizedIsInitialized;
    if (isInitialized == 1) return true;
    if (isInitialized == 0) return false;

    memoizedIsInitialized = 1;
    return true;
  }

  @java.lang.Override
  public void writeTo(com.google.protobuf.CodedOutputStream output)
                      throws java.io.IOException {
    for (int i = 0; i < permissions_.size(); i++) {
      output.writeMessage(1, permissions_.get(i));
    }
    getUnknownFields().writeTo(output);
  }

  @java.lang.Override
  public int getSerializedSize() {
    int size = memoizedSize;
    if (size != -1) return size;

    size = 0;
    for (int i = 0; i < permissions_.size(); i++) {
      size += com.google.protobuf.CodedOutputStream
        .computeMessageSize(1, permissions_.get(i));
    }
    size += getUnknownFields().getSerializedSize();
    memoizedSize = size;
    return size;
  }

  @java.lang.Override
  public boolean equals(final java.lang.Object obj) {
    if (obj == this) {
     return true;
    }
    if (!(obj instanceof grpc.permission_messages.ExplicitPermissions)) {
      return super.equals(obj);
    }
    grpc.permission_messages.ExplicitPermissions other = (grpc.permission_messages.ExplicitPermissions) obj;

    if (!getPermissionsList()
        .equals(other.getPermissionsList())) return false;
    if (!getUnknownFields().equals(other.getUnknownFields())) return false;
    return true;
  }

  @java.lang.Override
  public int hashCode() {
    if (memoizedHashCode != 0) {
      return memoizedHashCode;
    }
    int hash = 41;
    hash = (19 * hash) + getDescriptor().hashCode();
    if (getPermissionsCount() > 0) {
      hash = (37 * hash) + PERMISSIONS_FIELD_NUMBER;
      hash = (53 * hash) + getPermissionsList().hashCode();
    }
    hash = (29 * hash) + getUnknownFields().hashCode();
    memoizedHashCode = hash;
    return hash;
  }

  public static grpc.permission_messages.ExplicitPermissions parseFrom(
      java.nio.ByteBuffer data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static grpc.permission_messages.ExplicitPermissions parseFrom(
      java.nio.ByteBuffer data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static grpc.permission_messages.ExplicitPermissions parseFrom(
      com.google.protobuf.ByteString data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static grpc.permission_messages.ExplicitPermissions parseFrom(
      com.google.protobuf.ByteString data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static grpc.permission_messages.ExplicitPermissions parseFrom(byte[] data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static grpc.permission_messages.ExplicitPermissions parseFrom(
      byte[] data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static grpc.permission_messages.ExplicitPermissions parseFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input);
  }
  public static grpc.permission_messages.ExplicitPermissions parseFrom(
      java.io.InputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input, extensionRegistry);
  }
  public static grpc.permission_messages.ExplicitPermissions parseDelimitedFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseDelimitedWithIOException(PARSER, input);
  }
  public static grpc.permission_messages.ExplicitPermissions parseDelimitedFrom(
      java.io.InputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
  }
  public static grpc.permission_messages.ExplicitPermissions parseFrom(
      com.google.protobuf.CodedInputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input);
  }
  public static grpc.permission_messages.ExplicitPermissions parseFrom(
      com.google.protobuf.CodedInputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input, extensionRegistry);
  }

  @java.lang.Override
  public Builder newBuilderForType() { return newBuilder(); }
  public static Builder newBuilder() {
    return DEFAULT_INSTANCE.toBuilder();
  }
  public static Builder newBuilder(grpc.permission_messages.ExplicitPermissions prototype) {
    return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
  }
  @java.lang.Override
  public Builder toBuilder() {
    return this == DEFAULT_INSTANCE
        ? new Builder() : new Builder().mergeFrom(this);
  }

  @java.lang.Override
  protected Builder newBuilderForType(
      com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
    Builder builder = new Builder(parent);
    return builder;
  }
  /**
   * Protobuf type {@code permission_messages.ExplicitPermissions}
   */
  public static final class Builder extends
      com.google.protobuf.GeneratedMessageV3.Builder implements
      // @@protoc_insertion_point(builder_implements:permission_messages.ExplicitPermissions)
      grpc.permission_messages.ExplicitPermissionsOrBuilder {
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return grpc.permission_messages.Permissionmessages.internal_static_permission_messages_ExplicitPermissions_descriptor;
    }

    @java.lang.Override
    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return grpc.permission_messages.Permissionmessages.internal_static_permission_messages_ExplicitPermissions_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              grpc.permission_messages.ExplicitPermissions.class, grpc.permission_messages.ExplicitPermissions.Builder.class);
    }

    // Construct using grpc.permission_messages.ExplicitPermissions.newBuilder()
    private Builder() {

    }

    private Builder(
        com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
      super(parent);

    }
    @java.lang.Override
    public Builder clear() {
      super.clear();
      bitField0_ = 0;
      if (permissionsBuilder_ == null) {
        permissions_ = java.util.Collections.emptyList();
      } else {
        permissions_ = null;
        permissionsBuilder_.clear();
      }
      bitField0_ = (bitField0_ & ~0x00000001);
      return this;
    }

    @java.lang.Override
    public com.google.protobuf.Descriptors.Descriptor
        getDescriptorForType() {
      return grpc.permission_messages.Permissionmessages.internal_static_permission_messages_ExplicitPermissions_descriptor;
    }

    @java.lang.Override
    public grpc.permission_messages.ExplicitPermissions getDefaultInstanceForType() {
      return grpc.permission_messages.ExplicitPermissions.getDefaultInstance();
    }

    @java.lang.Override
    public grpc.permission_messages.ExplicitPermissions build() {
      grpc.permission_messages.ExplicitPermissions result = buildPartial();
      if (!result.isInitialized()) {
        throw newUninitializedMessageException(result);
      }
      return result;
    }

    @java.lang.Override
    public grpc.permission_messages.ExplicitPermissions buildPartial() {
      grpc.permission_messages.ExplicitPermissions result = new grpc.permission_messages.ExplicitPermissions(this);
      buildPartialRepeatedFields(result);
      if (bitField0_ != 0) { buildPartial0(result); }
      onBuilt();
      return result;
    }

    private void buildPartialRepeatedFields(grpc.permission_messages.ExplicitPermissions result) {
      if (permissionsBuilder_ == null) {
        if (((bitField0_ & 0x00000001) != 0)) {
          permissions_ = java.util.Collections.unmodifiableList(permissions_);
          bitField0_ = (bitField0_ & ~0x00000001);
        }
        result.permissions_ = permissions_;
      } else {
        result.permissions_ = permissionsBuilder_.build();
      }
    }

    private void buildPartial0(grpc.permission_messages.ExplicitPermissions result) {
      int from_bitField0_ = bitField0_;
    }

    @java.lang.Override
    public Builder mergeFrom(com.google.protobuf.Message other) {
      if (other instanceof grpc.permission_messages.ExplicitPermissions) {
        return mergeFrom((grpc.permission_messages.ExplicitPermissions)other);
      } else {
        super.mergeFrom(other);
        return this;
      }
    }

    public Builder mergeFrom(grpc.permission_messages.ExplicitPermissions other) {
      if (other == grpc.permission_messages.ExplicitPermissions.getDefaultInstance()) return this;
      if (permissionsBuilder_ == null) {
        if (!other.permissions_.isEmpty()) {
          if (permissions_.isEmpty()) {
            permissions_ = other.permissions_;
            bitField0_ = (bitField0_ & ~0x00000001);
          } else {
            ensurePermissionsIsMutable();
            permissions_.addAll(other.permissions_);
          }
          onChanged();
        }
      } else {
        if (!other.permissions_.isEmpty()) {
          if (permissionsBuilder_.isEmpty()) {
            permissionsBuilder_.dispose();
            permissionsBuilder_ = null;
            permissions_ = other.permissions_;
            bitField0_ = (bitField0_ & ~0x00000001);
            permissionsBuilder_ = 
              com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
                 getPermissionsFieldBuilder() : null;
          } else {
            permissionsBuilder_.addAllMessages(other.permissions_);
          }
        }
      }
      this.mergeUnknownFields(other.getUnknownFields());
      onChanged();
      return this;
    }

    @java.lang.Override
    public final boolean isInitialized() {
      return true;
    }

    @java.lang.Override
    public Builder mergeFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      if (extensionRegistry == null) {
        throw new java.lang.NullPointerException();
      }
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            case 10: {
              grpc.permission_messages.PermissionsType m =
                  input.readMessage(
                      grpc.permission_messages.PermissionsType.parser(),
                      extensionRegistry);
              if (permissionsBuilder_ == null) {
                ensurePermissionsIsMutable();
                permissions_.add(m);
              } else {
                permissionsBuilder_.addMessage(m);
              }
              break;
            } // case 10
            default: {
              if (!super.parseUnknownField(input, extensionRegistry, tag)) {
                done = true; // was an endgroup tag
              }
              break;
            } // default:
          } // switch (tag)
        } // while (!done)
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.unwrapIOException();
      } finally {
        onChanged();
      } // finally
      return this;
    }
    private int bitField0_;

    private java.util.List permissions_ =
      java.util.Collections.emptyList();
    private void ensurePermissionsIsMutable() {
      if (!((bitField0_ & 0x00000001) != 0)) {
        permissions_ = new java.util.ArrayList(permissions_);
        bitField0_ |= 0x00000001;
       }
    }

    private com.google.protobuf.RepeatedFieldBuilderV3<
        grpc.permission_messages.PermissionsType, grpc.permission_messages.PermissionsType.Builder, grpc.permission_messages.PermissionsTypeOrBuilder> permissionsBuilder_;

    /**
     * repeated .permission_messages.PermissionsType permissions = 1;
     */
    public java.util.List getPermissionsList() {
      if (permissionsBuilder_ == null) {
        return java.util.Collections.unmodifiableList(permissions_);
      } else {
        return permissionsBuilder_.getMessageList();
      }
    }
    /**
     * repeated .permission_messages.PermissionsType permissions = 1;
     */
    public int getPermissionsCount() {
      if (permissionsBuilder_ == null) {
        return permissions_.size();
      } else {
        return permissionsBuilder_.getCount();
      }
    }
    /**
     * repeated .permission_messages.PermissionsType permissions = 1;
     */
    public grpc.permission_messages.PermissionsType getPermissions(int index) {
      if (permissionsBuilder_ == null) {
        return permissions_.get(index);
      } else {
        return permissionsBuilder_.getMessage(index);
      }
    }
    /**
     * repeated .permission_messages.PermissionsType permissions = 1;
     */
    public Builder setPermissions(
        int index, grpc.permission_messages.PermissionsType value) {
      if (permissionsBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        ensurePermissionsIsMutable();
        permissions_.set(index, value);
        onChanged();
      } else {
        permissionsBuilder_.setMessage(index, value);
      }
      return this;
    }
    /**
     * repeated .permission_messages.PermissionsType permissions = 1;
     */
    public Builder setPermissions(
        int index, grpc.permission_messages.PermissionsType.Builder builderForValue) {
      if (permissionsBuilder_ == null) {
        ensurePermissionsIsMutable();
        permissions_.set(index, builderForValue.build());
        onChanged();
      } else {
        permissionsBuilder_.setMessage(index, builderForValue.build());
      }
      return this;
    }
    /**
     * repeated .permission_messages.PermissionsType permissions = 1;
     */
    public Builder addPermissions(grpc.permission_messages.PermissionsType value) {
      if (permissionsBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        ensurePermissionsIsMutable();
        permissions_.add(value);
        onChanged();
      } else {
        permissionsBuilder_.addMessage(value);
      }
      return this;
    }
    /**
     * repeated .permission_messages.PermissionsType permissions = 1;
     */
    public Builder addPermissions(
        int index, grpc.permission_messages.PermissionsType value) {
      if (permissionsBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        ensurePermissionsIsMutable();
        permissions_.add(index, value);
        onChanged();
      } else {
        permissionsBuilder_.addMessage(index, value);
      }
      return this;
    }
    /**
     * repeated .permission_messages.PermissionsType permissions = 1;
     */
    public Builder addPermissions(
        grpc.permission_messages.PermissionsType.Builder builderForValue) {
      if (permissionsBuilder_ == null) {
        ensurePermissionsIsMutable();
        permissions_.add(builderForValue.build());
        onChanged();
      } else {
        permissionsBuilder_.addMessage(builderForValue.build());
      }
      return this;
    }
    /**
     * repeated .permission_messages.PermissionsType permissions = 1;
     */
    public Builder addPermissions(
        int index, grpc.permission_messages.PermissionsType.Builder builderForValue) {
      if (permissionsBuilder_ == null) {
        ensurePermissionsIsMutable();
        permissions_.add(index, builderForValue.build());
        onChanged();
      } else {
        permissionsBuilder_.addMessage(index, builderForValue.build());
      }
      return this;
    }
    /**
     * repeated .permission_messages.PermissionsType permissions = 1;
     */
    public Builder addAllPermissions(
        java.lang.Iterable values) {
      if (permissionsBuilder_ == null) {
        ensurePermissionsIsMutable();
        com.google.protobuf.AbstractMessageLite.Builder.addAll(
            values, permissions_);
        onChanged();
      } else {
        permissionsBuilder_.addAllMessages(values);
      }
      return this;
    }
    /**
     * repeated .permission_messages.PermissionsType permissions = 1;
     */
    public Builder clearPermissions() {
      if (permissionsBuilder_ == null) {
        permissions_ = java.util.Collections.emptyList();
        bitField0_ = (bitField0_ & ~0x00000001);
        onChanged();
      } else {
        permissionsBuilder_.clear();
      }
      return this;
    }
    /**
     * repeated .permission_messages.PermissionsType permissions = 1;
     */
    public Builder removePermissions(int index) {
      if (permissionsBuilder_ == null) {
        ensurePermissionsIsMutable();
        permissions_.remove(index);
        onChanged();
      } else {
        permissionsBuilder_.remove(index);
      }
      return this;
    }
    /**
     * repeated .permission_messages.PermissionsType permissions = 1;
     */
    public grpc.permission_messages.PermissionsType.Builder getPermissionsBuilder(
        int index) {
      return getPermissionsFieldBuilder().getBuilder(index);
    }
    /**
     * repeated .permission_messages.PermissionsType permissions = 1;
     */
    public grpc.permission_messages.PermissionsTypeOrBuilder getPermissionsOrBuilder(
        int index) {
      if (permissionsBuilder_ == null) {
        return permissions_.get(index);  } else {
        return permissionsBuilder_.getMessageOrBuilder(index);
      }
    }
    /**
     * repeated .permission_messages.PermissionsType permissions = 1;
     */
    public java.util.List 
         getPermissionsOrBuilderList() {
      if (permissionsBuilder_ != null) {
        return permissionsBuilder_.getMessageOrBuilderList();
      } else {
        return java.util.Collections.unmodifiableList(permissions_);
      }
    }
    /**
     * repeated .permission_messages.PermissionsType permissions = 1;
     */
    public grpc.permission_messages.PermissionsType.Builder addPermissionsBuilder() {
      return getPermissionsFieldBuilder().addBuilder(
          grpc.permission_messages.PermissionsType.getDefaultInstance());
    }
    /**
     * repeated .permission_messages.PermissionsType permissions = 1;
     */
    public grpc.permission_messages.PermissionsType.Builder addPermissionsBuilder(
        int index) {
      return getPermissionsFieldBuilder().addBuilder(
          index, grpc.permission_messages.PermissionsType.getDefaultInstance());
    }
    /**
     * repeated .permission_messages.PermissionsType permissions = 1;
     */
    public java.util.List 
         getPermissionsBuilderList() {
      return getPermissionsFieldBuilder().getBuilderList();
    }
    private com.google.protobuf.RepeatedFieldBuilderV3<
        grpc.permission_messages.PermissionsType, grpc.permission_messages.PermissionsType.Builder, grpc.permission_messages.PermissionsTypeOrBuilder> 
        getPermissionsFieldBuilder() {
      if (permissionsBuilder_ == null) {
        permissionsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
            grpc.permission_messages.PermissionsType, grpc.permission_messages.PermissionsType.Builder, grpc.permission_messages.PermissionsTypeOrBuilder>(
                permissions_,
                ((bitField0_ & 0x00000001) != 0),
                getParentForChildren(),
                isClean());
        permissions_ = null;
      }
      return permissionsBuilder_;
    }
    @java.lang.Override
    public final Builder setUnknownFields(
        final com.google.protobuf.UnknownFieldSet unknownFields) {
      return super.setUnknownFields(unknownFields);
    }

    @java.lang.Override
    public final Builder mergeUnknownFields(
        final com.google.protobuf.UnknownFieldSet unknownFields) {
      return super.mergeUnknownFields(unknownFields);
    }


    // @@protoc_insertion_point(builder_scope:permission_messages.ExplicitPermissions)
  }

  // @@protoc_insertion_point(class_scope:permission_messages.ExplicitPermissions)
  private static final grpc.permission_messages.ExplicitPermissions DEFAULT_INSTANCE;
  static {
    DEFAULT_INSTANCE = new grpc.permission_messages.ExplicitPermissions();
  }

  public static grpc.permission_messages.ExplicitPermissions getDefaultInstance() {
    return DEFAULT_INSTANCE;
  }

  private static final com.google.protobuf.Parser
      PARSER = new com.google.protobuf.AbstractParser() {
    @java.lang.Override
    public ExplicitPermissions parsePartialFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      Builder builder = newBuilder();
      try {
        builder.mergeFrom(input, extensionRegistry);
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(builder.buildPartial());
      } catch (com.google.protobuf.UninitializedMessageException e) {
        throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(e)
            .setUnfinishedMessage(builder.buildPartial());
      }
      return builder.buildPartial();
    }
  };

  public static com.google.protobuf.Parser parser() {
    return PARSER;
  }

  @java.lang.Override
  public com.google.protobuf.Parser getParserForType() {
    return PARSER;
  }

  @java.lang.Override
  public grpc.permission_messages.ExplicitPermissions getDefaultInstanceForType() {
    return DEFAULT_INSTANCE;
  }

}





© 2015 - 2024 Weber Informatics LLC | Privacy Policy