Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
/*
* Copyright 2020 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/api/resource.proto
package org.apache.rocketmq.shaded.com.google.api;
/**
*
*
*
* A simple descriptor of a resource type.
* ResourceDescriptor annotates a resource message (either by means of a
* protobuf annotation or use in the service config), and associates the
* resource's schema, the resource type, and the pattern of the resource name.
* Example:
* message Topic {
* // Indicates this message defines a resource schema.
* // Declares the resource type in the format of {service}/{kind}.
* // For Kubernetes resources, the format is {api group}/{kind}.
* option (google.api.resource) = {
* type: "pubsub.googleapis.com/Topic"
* pattern: "projects/{project}/topics/{topic}"
* };
* }
* The ResourceDescriptor Yaml config will look like:
* resources:
* - type: "pubsub.googleapis.com/Topic"
* pattern: "projects/{project}/topics/{topic}"
* Sometimes, resources have multiple patterns, typically because they can
* live under multiple parents.
* Example:
* message LogEntry {
* option (google.api.resource) = {
* type: "logging.googleapis.com/LogEntry"
* pattern: "projects/{project}/logs/{log}"
* pattern: "folders/{folder}/logs/{log}"
* pattern: "organizations/{organization}/logs/{log}"
* pattern: "billingAccounts/{billing_account}/logs/{log}"
* };
* }
* The ResourceDescriptor Yaml config will look like:
* resources:
* - type: 'logging.googleapis.com/LogEntry'
* pattern: "projects/{project}/logs/{log}"
* pattern: "folders/{folder}/logs/{log}"
* pattern: "organizations/{organization}/logs/{log}"
* pattern: "billingAccounts/{billing_account}/logs/{log}"
*
*
* Protobuf type {@code google.api.ResourceDescriptor}
*/
public final class ResourceDescriptor extends org.apache.rocketmq.shaded.com.google.protobuf.GeneratedMessageV3
implements
// @@protoc_insertion_point(message_implements:google.api.ResourceDescriptor)
ResourceDescriptorOrBuilder {
private static final long serialVersionUID = 0L;
// Use ResourceDescriptor.newBuilder() to construct.
private ResourceDescriptor(org.apache.rocketmq.shaded.com.google.protobuf.GeneratedMessageV3.Builder builder) {
super(builder);
}
private ResourceDescriptor() {
type_ = "";
pattern_ = org.apache.rocketmq.shaded.com.google.protobuf.LazyStringArrayList.EMPTY;
nameField_ = "";
history_ = 0;
plural_ = "";
singular_ = "";
style_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(UnusedPrivateParameter unused) {
return new ResourceDescriptor();
}
@java.lang.Override
public final org.apache.rocketmq.shaded.com.google.protobuf.UnknownFieldSet getUnknownFields() {
return this.unknownFields;
}
private ResourceDescriptor(
org.apache.rocketmq.shaded.com.google.protobuf.CodedInputStream input,
org.apache.rocketmq.shaded.com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws org.apache.rocketmq.shaded.com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
org.apache.rocketmq.shaded.com.google.protobuf.UnknownFieldSet.Builder unknownFields =
org.apache.rocketmq.shaded.com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10:
{
java.lang.String s = input.readStringRequireUtf8();
type_ = s;
break;
}
case 18:
{
java.lang.String s = input.readStringRequireUtf8();
if (!((mutable_bitField0_ & 0x00000001) != 0)) {
pattern_ = new org.apache.rocketmq.shaded.com.google.protobuf.LazyStringArrayList();
mutable_bitField0_ |= 0x00000001;
}
pattern_.add(s);
break;
}
case 26:
{
java.lang.String s = input.readStringRequireUtf8();
nameField_ = s;
break;
}
case 32:
{
int rawValue = input.readEnum();
history_ = rawValue;
break;
}
case 42:
{
java.lang.String s = input.readStringRequireUtf8();
plural_ = s;
break;
}
case 50:
{
java.lang.String s = input.readStringRequireUtf8();
singular_ = s;
break;
}
case 80:
{
int rawValue = input.readEnum();
if (!((mutable_bitField0_ & 0x00000002) != 0)) {
style_ = new java.util.ArrayList();
mutable_bitField0_ |= 0x00000002;
}
style_.add(rawValue);
break;
}
case 82:
{
int length = input.readRawVarint32();
int oldLimit = input.pushLimit(length);
while (input.getBytesUntilLimit() > 0) {
int rawValue = input.readEnum();
if (!((mutable_bitField0_ & 0x00000002) != 0)) {
style_ = new java.util.ArrayList();
mutable_bitField0_ |= 0x00000002;
}
style_.add(rawValue);
}
input.popLimit(oldLimit);
break;
}
default:
{
if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (org.apache.rocketmq.shaded.com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (org.apache.rocketmq.shaded.com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new org.apache.rocketmq.shaded.com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
} finally {
if (((mutable_bitField0_ & 0x00000001) != 0)) {
pattern_ = pattern_.getUnmodifiableView();
}
if (((mutable_bitField0_ & 0x00000002) != 0)) {
style_ = java.util.Collections.unmodifiableList(style_);
}
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final org.apache.rocketmq.shaded.com.google.protobuf.Descriptors.Descriptor getDescriptor() {
return org.apache.rocketmq.shaded.com.google.api.ResourceProto.internal_static_google_api_ResourceDescriptor_descriptor;
}
@java.lang.Override
protected org.apache.rocketmq.shaded.com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.apache.rocketmq.shaded.com.google.api.ResourceProto
.internal_static_google_api_ResourceDescriptor_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.apache.rocketmq.shaded.com.google.api.ResourceDescriptor.class,
org.apache.rocketmq.shaded.com.google.api.ResourceDescriptor.Builder.class);
}
/**
*
*
*
* A description of the historical or future-looking state of the
* resource pattern.
*
*
* Protobuf enum {@code google.api.ResourceDescriptor.History}
*/
public enum History implements org.apache.rocketmq.shaded.com.google.protobuf.ProtocolMessageEnum {
/**
*
*
*
* The resource has one pattern, but the API owner expects to add more
* later. (This is the inverse of ORIGINALLY_SINGLE_PATTERN, and prevents
* that from being necessary once there are multiple patterns.)
*
*
* HISTORY_UNSPECIFIED = 0;
*/
public static final int HISTORY_UNSPECIFIED_VALUE = 0;
/**
*
*
*
* The resource originally had one pattern and launched as such, and
* additional patterns were added later.
*
*
* ORIGINALLY_SINGLE_PATTERN = 1;
*/
public static final int ORIGINALLY_SINGLE_PATTERN_VALUE = 1;
/**
*
*
*
* The resource has one pattern, but the API owner expects to add more
* later. (This is the inverse of ORIGINALLY_SINGLE_PATTERN, and prevents
* that from being necessary once there are multiple patterns.)
*
*
* FUTURE_MULTI_PATTERN = 2;
*/
public static final int FUTURE_MULTI_PATTERN_VALUE = 2;
public final int getNumber() {
if (this == UNRECOGNIZED) {
throw new java.lang.IllegalArgumentException(
"Can't get the number of an unknown enum value.");
}
return value;
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @return The enum associated with the given numeric wire value.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static History valueOf(int value) {
return forNumber(value);
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @return The enum associated with the given numeric wire value.
*/
public static History forNumber(int value) {
switch (value) {
case 0:
return HISTORY_UNSPECIFIED;
case 1:
return ORIGINALLY_SINGLE_PATTERN;
case 2:
return FUTURE_MULTI_PATTERN;
default:
return null;
}
}
public static org.apache.rocketmq.shaded.com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() {
return internalValueMap;
}
private static final org.apache.rocketmq.shaded.com.google.protobuf.Internal.EnumLiteMap internalValueMap =
new org.apache.rocketmq.shaded.com.google.protobuf.Internal.EnumLiteMap() {
public History findValueByNumber(int number) {
return History.forNumber(number);
}
};
public final org.apache.rocketmq.shaded.com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() {
if (this == UNRECOGNIZED) {
throw new java.lang.IllegalStateException(
"Can't get the descriptor of an unrecognized enum value.");
}
return getDescriptor().getValues().get(ordinal());
}
public final org.apache.rocketmq.shaded.com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() {
return getDescriptor();
}
public static final org.apache.rocketmq.shaded.com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() {
return org.apache.rocketmq.shaded.com.google.api.ResourceDescriptor.getDescriptor().getEnumTypes().get(0);
}
private static final History[] VALUES = values();
public static History valueOf(org.apache.rocketmq.shaded.com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
if (desc.getType() != getDescriptor()) {
throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type.");
}
if (desc.getIndex() == -1) {
return UNRECOGNIZED;
}
return VALUES[desc.getIndex()];
}
private final int value;
private History(int value) {
this.value = value;
}
// @@protoc_insertion_point(enum_scope:google.api.ResourceDescriptor.History)
}
/**
*
*
*
* A flag representing a specific style that a resource claims to conform to.
*
* This resource is intended to be "declarative-friendly".
* Declarative-friendly resources must be more strictly consistent, and
* setting this to true communicates to tools that this resource should
* adhere to declarative-friendly expectations.
* Note: This is used by the API linter (linter.aip.dev) to enable
* additional checks.
*
*
* STYLE_UNSPECIFIED = 0;
*/
public static final int STYLE_UNSPECIFIED_VALUE = 0;
/**
*
*
*
* This resource is intended to be "declarative-friendly".
* Declarative-friendly resources must be more strictly consistent, and
* setting this to true communicates to tools that this resource should
* adhere to declarative-friendly expectations.
* Note: This is used by the API linter (linter.aip.dev) to enable
* additional checks.
*
*
* DECLARATIVE_FRIENDLY = 1;
*/
public static final int DECLARATIVE_FRIENDLY_VALUE = 1;
public final int getNumber() {
if (this == UNRECOGNIZED) {
throw new java.lang.IllegalArgumentException(
"Can't get the number of an unknown enum value.");
}
return value;
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @return The enum associated with the given numeric wire value.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static Style valueOf(int value) {
return forNumber(value);
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @return The enum associated with the given numeric wire value.
*/
public static Style forNumber(int value) {
switch (value) {
case 0:
return STYLE_UNSPECIFIED;
case 1:
return DECLARATIVE_FRIENDLY;
default:
return null;
}
}
public static org.apache.rocketmq.shaded.com.google.protobuf.Internal.EnumLiteMap