Package com.google.api
Class ResourceReference.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder<MessageType,BuilderType>
com.google.protobuf.GeneratedMessageLite.Builder<ResourceReference,ResourceReference.Builder>
com.google.api.ResourceReference.Builder
- All Implemented Interfaces:
ResourceReferenceOrBuilder
,com.google.protobuf.MessageLite.Builder
,com.google.protobuf.MessageLiteOrBuilder
,Cloneable
- Enclosing class:
- ResourceReference
public static final class ResourceReference.Builder
extends com.google.protobuf.GeneratedMessageLite.Builder<ResourceReference,ResourceReference.Builder>
implements ResourceReferenceOrBuilder
Defines a proto annotation that describes a string field that refers to an API resource.Protobuf type
google.api.ResourceReference
-
Field Summary
Fields inherited from class com.google.protobuf.GeneratedMessageLite.Builder
instance
-
Method Summary
Modifier and TypeMethodDescriptionThe resource type of a child collection that the annotated field references.The resource type that the annotated field references.The resource type of a child collection that the annotated field references.com.google.protobuf.ByteString
The resource type of a child collection that the annotated field references.getType()
The resource type that the annotated field references.com.google.protobuf.ByteString
The resource type that the annotated field references.setChildType
(String value) The resource type of a child collection that the annotated field references.setChildTypeBytes
(com.google.protobuf.ByteString value) The resource type of a child collection that the annotated field references.The resource type that the annotated field references.setTypeBytes
(com.google.protobuf.ByteString value) The resource type that the annotated field references.Methods inherited from class com.google.protobuf.GeneratedMessageLite.Builder
build, buildPartial, clear, clone, copyOnWrite, copyOnWriteInternal, getDefaultInstanceForType, internalMergeFrom, isInitialized, mergeFrom, mergeFrom, mergeFrom, mergeFrom
Methods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.google.protobuf.MessageLiteOrBuilder
getDefaultInstanceForType, isInitialized
-
Method Details
-
getType
The resource type that the annotated field references. Example: message Subscription { string topic = 2 [(google.api.resource_reference) = { type: "pubsub.googleapis.com/Topic" }]; } Occasionally, a field may reference an arbitrary resource. In this case, APIs use the special value * in their resource reference. Example: message GetIamPolicyRequest { string resource = 2 [(google.api.resource_reference) = { type: "*" }]; }
string type = 1 [json_name = "type"];
- Specified by:
getType
in interfaceResourceReferenceOrBuilder
- Returns:
- The type.
-
getTypeBytes
public com.google.protobuf.ByteString getTypeBytes()The resource type that the annotated field references. Example: message Subscription { string topic = 2 [(google.api.resource_reference) = { type: "pubsub.googleapis.com/Topic" }]; } Occasionally, a field may reference an arbitrary resource. In this case, APIs use the special value * in their resource reference. Example: message GetIamPolicyRequest { string resource = 2 [(google.api.resource_reference) = { type: "*" }]; }
string type = 1 [json_name = "type"];
- Specified by:
getTypeBytes
in interfaceResourceReferenceOrBuilder
- Returns:
- The bytes for type.
-
setType
The resource type that the annotated field references. Example: message Subscription { string topic = 2 [(google.api.resource_reference) = { type: "pubsub.googleapis.com/Topic" }]; } Occasionally, a field may reference an arbitrary resource. In this case, APIs use the special value * in their resource reference. Example: message GetIamPolicyRequest { string resource = 2 [(google.api.resource_reference) = { type: "*" }]; }
string type = 1 [json_name = "type"];
- Parameters:
value
- The type to set.- Returns:
- This builder for chaining.
-
clearType
The resource type that the annotated field references. Example: message Subscription { string topic = 2 [(google.api.resource_reference) = { type: "pubsub.googleapis.com/Topic" }]; } Occasionally, a field may reference an arbitrary resource. In this case, APIs use the special value * in their resource reference. Example: message GetIamPolicyRequest { string resource = 2 [(google.api.resource_reference) = { type: "*" }]; }
string type = 1 [json_name = "type"];
- Returns:
- This builder for chaining.
-
setTypeBytes
The resource type that the annotated field references. Example: message Subscription { string topic = 2 [(google.api.resource_reference) = { type: "pubsub.googleapis.com/Topic" }]; } Occasionally, a field may reference an arbitrary resource. In this case, APIs use the special value * in their resource reference. Example: message GetIamPolicyRequest { string resource = 2 [(google.api.resource_reference) = { type: "*" }]; }
string type = 1 [json_name = "type"];
- Parameters:
value
- The bytes for type to set.- Returns:
- This builder for chaining.
-
getChildType
The resource type of a child collection that the annotated field references. This is useful for annotating the `parent` field that doesn't have a fixed resource type. Example: message ListLogEntriesRequest { string parent = 1 [(google.api.resource_reference) = { child_type: "logging.googleapis.com/LogEntry" }; }
string child_type = 2 [json_name = "childType"];
- Specified by:
getChildType
in interfaceResourceReferenceOrBuilder
- Returns:
- The childType.
-
getChildTypeBytes
public com.google.protobuf.ByteString getChildTypeBytes()The resource type of a child collection that the annotated field references. This is useful for annotating the `parent` field that doesn't have a fixed resource type. Example: message ListLogEntriesRequest { string parent = 1 [(google.api.resource_reference) = { child_type: "logging.googleapis.com/LogEntry" }; }
string child_type = 2 [json_name = "childType"];
- Specified by:
getChildTypeBytes
in interfaceResourceReferenceOrBuilder
- Returns:
- The bytes for childType.
-
setChildType
The resource type of a child collection that the annotated field references. This is useful for annotating the `parent` field that doesn't have a fixed resource type. Example: message ListLogEntriesRequest { string parent = 1 [(google.api.resource_reference) = { child_type: "logging.googleapis.com/LogEntry" }; }
string child_type = 2 [json_name = "childType"];
- Parameters:
value
- The childType to set.- Returns:
- This builder for chaining.
-
clearChildType
The resource type of a child collection that the annotated field references. This is useful for annotating the `parent` field that doesn't have a fixed resource type. Example: message ListLogEntriesRequest { string parent = 1 [(google.api.resource_reference) = { child_type: "logging.googleapis.com/LogEntry" }; }
string child_type = 2 [json_name = "childType"];
- Returns:
- This builder for chaining.
-
setChildTypeBytes
The resource type of a child collection that the annotated field references. This is useful for annotating the `parent` field that doesn't have a fixed resource type. Example: message ListLogEntriesRequest { string parent = 1 [(google.api.resource_reference) = { child_type: "logging.googleapis.com/LogEntry" }; }
string child_type = 2 [json_name = "childType"];
- Parameters:
value
- The bytes for childType to set.- Returns:
- This builder for chaining.
-