// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: proto/config.proto
package com.google.crypto.tink.proto;
/**
*
* An entry that describes a key type to be used with Tink library,
* specifying the corresponding primitive, key manager, and deprecation status.
* All fields are required.
*
*
* Protobuf type {@code google.crypto.tink.KeyTypeEntry}
*/
@java.lang.Deprecated public final class KeyTypeEntry extends
com.google.protobuf.GeneratedMessageLite<
KeyTypeEntry, KeyTypeEntry.Builder> implements
// @@protoc_insertion_point(message_implements:google.crypto.tink.KeyTypeEntry)
KeyTypeEntryOrBuilder {
private KeyTypeEntry() {
primitiveName_ = "";
typeUrl_ = "";
catalogueName_ = "";
}
public static final int PRIMITIVE_NAME_FIELD_NUMBER = 1;
private java.lang.String primitiveName_;
/**
*
* E.g. “Aead”, “Mac”, ... (case-insensitive)
*
*
* string primitive_name = 1;
* @return The primitiveName.
*/
@java.lang.Override
public java.lang.String getPrimitiveName() {
return primitiveName_;
}
/**
*
* E.g. “Aead”, “Mac”, ... (case-insensitive)
*
*
* string primitive_name = 1;
* @return The bytes for primitiveName.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getPrimitiveNameBytes() {
return com.google.protobuf.ByteString.copyFromUtf8(primitiveName_);
}
/**
*
* E.g. “Aead”, “Mac”, ... (case-insensitive)
*
*
* string primitive_name = 1;
* @param value The primitiveName to set.
*/
private void setPrimitiveName(
java.lang.String value) {
java.lang.Class valueClass = value.getClass();
primitiveName_ = value;
}
/**
*
* E.g. “Aead”, “Mac”, ... (case-insensitive)
*
*
* string primitive_name = 1;
*/
private void clearPrimitiveName() {
primitiveName_ = getDefaultInstance().getPrimitiveName();
}
/**
*
* E.g. “Aead”, “Mac”, ... (case-insensitive)
*
*
* string primitive_name = 1;
* @param value The bytes for primitiveName to set.
*/
private void setPrimitiveNameBytes(
com.google.protobuf.ByteString value) {
checkByteStringIsUtf8(value);
primitiveName_ = value.toStringUtf8();
}
public static final int TYPE_URL_FIELD_NUMBER = 2;
private java.lang.String typeUrl_;
/**
*
* Name of the key type.
*
*
* string type_url = 2;
* @return The typeUrl.
*/
@java.lang.Override
public java.lang.String getTypeUrl() {
return typeUrl_;
}
/**
*
* Name of the key type.
*
*
* string type_url = 2;
* @return The bytes for typeUrl.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getTypeUrlBytes() {
return com.google.protobuf.ByteString.copyFromUtf8(typeUrl_);
}
/**
*
* Name of the key type.
*
*
* string type_url = 2;
* @param value The typeUrl to set.
*/
private void setTypeUrl(
java.lang.String value) {
java.lang.Class valueClass = value.getClass();
typeUrl_ = value;
}
/**
*
* Name of the key type.
*
*
* string type_url = 2;
*/
private void clearTypeUrl() {
typeUrl_ = getDefaultInstance().getTypeUrl();
}
/**
*
* Name of the key type.
*
*
* string type_url = 2;
* @param value The bytes for typeUrl to set.
*/
private void setTypeUrlBytes(
com.google.protobuf.ByteString value) {
checkByteStringIsUtf8(value);
typeUrl_ = value.toStringUtf8();
}
public static final int KEY_MANAGER_VERSION_FIELD_NUMBER = 3;
private int keyManagerVersion_;
/**
*
* Minimum required version of key manager.
*
*
* uint32 key_manager_version = 3;
* @return The keyManagerVersion.
*/
@java.lang.Override
public int getKeyManagerVersion() {
return keyManagerVersion_;
}
/**
*
* Minimum required version of key manager.
*
*
* uint32 key_manager_version = 3;
* @param value The keyManagerVersion to set.
*/
private void setKeyManagerVersion(int value) {
keyManagerVersion_ = value;
}
/**
*
* Minimum required version of key manager.
*
*
* uint32 key_manager_version = 3;
*/
private void clearKeyManagerVersion() {
keyManagerVersion_ = 0;
}
public static final int NEW_KEY_ALLOWED_FIELD_NUMBER = 4;
private boolean newKeyAllowed_;
/**
*
* Can the key manager create new keys?
*
*
* bool new_key_allowed = 4;
* @return The newKeyAllowed.
*/
@java.lang.Override
public boolean getNewKeyAllowed() {
return newKeyAllowed_;
}
/**
*
* Can the key manager create new keys?
*
*
* bool new_key_allowed = 4;
* @param value The newKeyAllowed to set.
*/
private void setNewKeyAllowed(boolean value) {
newKeyAllowed_ = value;
}
/**
*
* Can the key manager create new keys?
*
*
* bool new_key_allowed = 4;
*/
private void clearNewKeyAllowed() {
newKeyAllowed_ = false;
}
public static final int CATALOGUE_NAME_FIELD_NUMBER = 5;
private java.lang.String catalogueName_;
/**
*
* Catalogue to be queried for key manager,
*
*
* string catalogue_name = 5;
* @return The catalogueName.
*/
@java.lang.Override
public java.lang.String getCatalogueName() {
return catalogueName_;
}
/**
*
* Catalogue to be queried for key manager,
*
*
* string catalogue_name = 5;
* @return The bytes for catalogueName.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getCatalogueNameBytes() {
return com.google.protobuf.ByteString.copyFromUtf8(catalogueName_);
}
/**
*
* Catalogue to be queried for key manager,
*
*
* string catalogue_name = 5;
* @param value The catalogueName to set.
*/
private void setCatalogueName(
java.lang.String value) {
java.lang.Class valueClass = value.getClass();
catalogueName_ = value;
}
/**
*
* Catalogue to be queried for key manager,
*
*
* string catalogue_name = 5;
*/
private void clearCatalogueName() {
catalogueName_ = getDefaultInstance().getCatalogueName();
}
/**
*
* Catalogue to be queried for key manager,
*
*
* string catalogue_name = 5;
* @param value The bytes for catalogueName to set.
*/
private void setCatalogueNameBytes(
com.google.protobuf.ByteString value) {
checkByteStringIsUtf8(value);
catalogueName_ = value.toStringUtf8();
}
public static com.google.crypto.tink.proto.KeyTypeEntry parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return com.google.protobuf.GeneratedMessageLite.parseFrom(
DEFAULT_INSTANCE, data);
}
public static com.google.crypto.tink.proto.KeyTypeEntry parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return com.google.protobuf.GeneratedMessageLite.parseFrom(
DEFAULT_INSTANCE, data, extensionRegistry);
}
public static com.google.crypto.tink.proto.KeyTypeEntry parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return com.google.protobuf.GeneratedMessageLite.parseFrom(
DEFAULT_INSTANCE, data);
}
public static com.google.crypto.tink.proto.KeyTypeEntry parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return com.google.protobuf.GeneratedMessageLite.parseFrom(
DEFAULT_INSTANCE, data, extensionRegistry);
}
public static com.google.crypto.tink.proto.KeyTypeEntry parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return com.google.protobuf.GeneratedMessageLite.parseFrom(
DEFAULT_INSTANCE, data);
}
public static com.google.crypto.tink.proto.KeyTypeEntry parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return com.google.protobuf.GeneratedMessageLite.parseFrom(
DEFAULT_INSTANCE, data, extensionRegistry);
}
public static com.google.crypto.tink.proto.KeyTypeEntry parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageLite.parseFrom(
DEFAULT_INSTANCE, input);
}
public static com.google.crypto.tink.proto.KeyTypeEntry parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageLite.parseFrom(
DEFAULT_INSTANCE, input, extensionRegistry);
}
public static com.google.crypto.tink.proto.KeyTypeEntry parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return parseDelimitedFrom(DEFAULT_INSTANCE, input);
}
public static com.google.crypto.tink.proto.KeyTypeEntry parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return parseDelimitedFrom(DEFAULT_INSTANCE, input, extensionRegistry);
}
public static com.google.crypto.tink.proto.KeyTypeEntry parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageLite.parseFrom(
DEFAULT_INSTANCE, input);
}
public static com.google.crypto.tink.proto.KeyTypeEntry parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageLite.parseFrom(
DEFAULT_INSTANCE, input, extensionRegistry);
}
public static Builder newBuilder() {
return (Builder) DEFAULT_INSTANCE.createBuilder();
}
public static Builder newBuilder(com.google.crypto.tink.proto.KeyTypeEntry prototype) {
return (Builder) DEFAULT_INSTANCE.createBuilder(prototype);
}
/**
*
* An entry that describes a key type to be used with Tink library,
* specifying the corresponding primitive, key manager, and deprecation status.
* All fields are required.
*
*
* Protobuf type {@code google.crypto.tink.KeyTypeEntry}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageLite.Builder<
com.google.crypto.tink.proto.KeyTypeEntry, Builder> implements
// @@protoc_insertion_point(builder_implements:google.crypto.tink.KeyTypeEntry)
com.google.crypto.tink.proto.KeyTypeEntryOrBuilder {
// Construct using com.google.crypto.tink.proto.KeyTypeEntry.newBuilder()
private Builder() {
super(DEFAULT_INSTANCE);
}
/**
*
* E.g. “Aead”, “Mac”, ... (case-insensitive)
*
*
* string primitive_name = 1;
* @return The primitiveName.
*/
@java.lang.Override
public java.lang.String getPrimitiveName() {
return instance.getPrimitiveName();
}
/**
*
* E.g. “Aead”, “Mac”, ... (case-insensitive)
*
*
* string primitive_name = 1;
* @return The bytes for primitiveName.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getPrimitiveNameBytes() {
return instance.getPrimitiveNameBytes();
}
/**
*
* E.g. “Aead”, “Mac”, ... (case-insensitive)
*
*
* string primitive_name = 1;
* @param value The primitiveName to set.
* @return This builder for chaining.
*/
public Builder setPrimitiveName(
java.lang.String value) {
copyOnWrite();
instance.setPrimitiveName(value);
return this;
}
/**
*
* E.g. “Aead”, “Mac”, ... (case-insensitive)
*
*
* string primitive_name = 1;
* @return This builder for chaining.
*/
public Builder clearPrimitiveName() {
copyOnWrite();
instance.clearPrimitiveName();
return this;
}
/**
*
* E.g. “Aead”, “Mac”, ... (case-insensitive)
*
*
* string primitive_name = 1;
* @param value The bytes for primitiveName to set.
* @return This builder for chaining.
*/
public Builder setPrimitiveNameBytes(
com.google.protobuf.ByteString value) {
copyOnWrite();
instance.setPrimitiveNameBytes(value);
return this;
}
/**
*
* Name of the key type.
*
*
* string type_url = 2;
* @return The typeUrl.
*/
@java.lang.Override
public java.lang.String getTypeUrl() {
return instance.getTypeUrl();
}
/**
*
* Name of the key type.
*
*
* string type_url = 2;
* @return The bytes for typeUrl.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getTypeUrlBytes() {
return instance.getTypeUrlBytes();
}
/**
*
* Name of the key type.
*
*
* string type_url = 2;
* @param value The typeUrl to set.
* @return This builder for chaining.
*/
public Builder setTypeUrl(
java.lang.String value) {
copyOnWrite();
instance.setTypeUrl(value);
return this;
}
/**
*
* Name of the key type.
*
*
* string type_url = 2;
* @return This builder for chaining.
*/
public Builder clearTypeUrl() {
copyOnWrite();
instance.clearTypeUrl();
return this;
}
/**
*
* Name of the key type.
*
*
* string type_url = 2;
* @param value The bytes for typeUrl to set.
* @return This builder for chaining.
*/
public Builder setTypeUrlBytes(
com.google.protobuf.ByteString value) {
copyOnWrite();
instance.setTypeUrlBytes(value);
return this;
}
/**
*
* Minimum required version of key manager.
*
*
* uint32 key_manager_version = 3;
* @return The keyManagerVersion.
*/
@java.lang.Override
public int getKeyManagerVersion() {
return instance.getKeyManagerVersion();
}
/**
*
* Minimum required version of key manager.
*
*
* uint32 key_manager_version = 3;
* @param value The keyManagerVersion to set.
* @return This builder for chaining.
*/
public Builder setKeyManagerVersion(int value) {
copyOnWrite();
instance.setKeyManagerVersion(value);
return this;
}
/**
*
* Minimum required version of key manager.
*
*
* uint32 key_manager_version = 3;
* @return This builder for chaining.
*/
public Builder clearKeyManagerVersion() {
copyOnWrite();
instance.clearKeyManagerVersion();
return this;
}
/**
*
* Can the key manager create new keys?
*
*
* bool new_key_allowed = 4;
* @return The newKeyAllowed.
*/
@java.lang.Override
public boolean getNewKeyAllowed() {
return instance.getNewKeyAllowed();
}
/**
*
* Can the key manager create new keys?
*
*
* bool new_key_allowed = 4;
* @param value The newKeyAllowed to set.
* @return This builder for chaining.
*/
public Builder setNewKeyAllowed(boolean value) {
copyOnWrite();
instance.setNewKeyAllowed(value);
return this;
}
/**
*
* Can the key manager create new keys?
*
*
* bool new_key_allowed = 4;
* @return This builder for chaining.
*/
public Builder clearNewKeyAllowed() {
copyOnWrite();
instance.clearNewKeyAllowed();
return this;
}
/**
*
* Catalogue to be queried for key manager,
*
*
* string catalogue_name = 5;
* @return The catalogueName.
*/
@java.lang.Override
public java.lang.String getCatalogueName() {
return instance.getCatalogueName();
}
/**
*
* Catalogue to be queried for key manager,
*
*
* string catalogue_name = 5;
* @return The bytes for catalogueName.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getCatalogueNameBytes() {
return instance.getCatalogueNameBytes();
}
/**
*
* Catalogue to be queried for key manager,
*
*
* string catalogue_name = 5;
* @param value The catalogueName to set.
* @return This builder for chaining.
*/
public Builder setCatalogueName(
java.lang.String value) {
copyOnWrite();
instance.setCatalogueName(value);
return this;
}
/**
*
* Catalogue to be queried for key manager,
*
*
* string catalogue_name = 5;
* @return This builder for chaining.
*/
public Builder clearCatalogueName() {
copyOnWrite();
instance.clearCatalogueName();
return this;
}
/**
*
* Catalogue to be queried for key manager,
*
*
* string catalogue_name = 5;
* @param value The bytes for catalogueName to set.
* @return This builder for chaining.
*/
public Builder setCatalogueNameBytes(
com.google.protobuf.ByteString value) {
copyOnWrite();
instance.setCatalogueNameBytes(value);
return this;
}
// @@protoc_insertion_point(builder_scope:google.crypto.tink.KeyTypeEntry)
}
@java.lang.Override
@java.lang.SuppressWarnings({"unchecked", "fallthrough"})
protected final java.lang.Object dynamicMethod(
com.google.protobuf.GeneratedMessageLite.MethodToInvoke method,
java.lang.Object arg0, java.lang.Object arg1) {
switch (method) {
case NEW_MUTABLE_INSTANCE: {
return new com.google.crypto.tink.proto.KeyTypeEntry();
}
case NEW_BUILDER: {
return new Builder();
}
case BUILD_MESSAGE_INFO: {
java.lang.Object[] objects = new java.lang.Object[] {
"primitiveName_",
"typeUrl_",
"keyManagerVersion_",
"newKeyAllowed_",
"catalogueName_",
};
java.lang.String info =
"\u0000\u0005\u0000\u0000\u0001\u0005\u0005\u0000\u0000\u0000\u0001\u0208\u0002\u0208" +
"\u0003\u000b\u0004\u0007\u0005\u0208";
return newMessageInfo(DEFAULT_INSTANCE, info, objects);
}
// fall through
case GET_DEFAULT_INSTANCE: {
return DEFAULT_INSTANCE;
}
case GET_PARSER: {
com.google.protobuf.Parser parser = PARSER;
if (parser == null) {
synchronized (com.google.crypto.tink.proto.KeyTypeEntry.class) {
parser = PARSER;
if (parser == null) {
parser =
new DefaultInstanceBasedParser(
DEFAULT_INSTANCE);
PARSER = parser;
}
}
}
return parser;
}
case GET_MEMOIZED_IS_INITIALIZED: {
return (byte) 1;
}
case SET_MEMOIZED_IS_INITIALIZED: {
return null;
}
}
throw new UnsupportedOperationException();
}
// @@protoc_insertion_point(class_scope:google.crypto.tink.KeyTypeEntry)
private static final com.google.crypto.tink.proto.KeyTypeEntry DEFAULT_INSTANCE;
static {
KeyTypeEntry defaultInstance = new KeyTypeEntry();
// New instances are implicitly immutable so no need to make
// immutable.
DEFAULT_INSTANCE = defaultInstance;
com.google.protobuf.GeneratedMessageLite.registerDefaultInstance(
KeyTypeEntry.class, defaultInstance);
}
public static com.google.crypto.tink.proto.KeyTypeEntry getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static volatile com.google.protobuf.Parser PARSER;
public static com.google.protobuf.Parser parser() {
return DEFAULT_INSTANCE.getParserForType();
}
}