yandex.cloud.api.compute.v1.PlacementGroupOuterClass Maven / Gradle / Ivy
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: yandex/cloud/compute/v1/placement_group.proto
package yandex.cloud.api.compute.v1;
public final class PlacementGroupOuterClass {
private PlacementGroupOuterClass() {}
public static void registerAllExtensions(
com.google.protobuf.ExtensionRegistryLite registry) {
}
public static void registerAllExtensions(
com.google.protobuf.ExtensionRegistry registry) {
registerAllExtensions(
(com.google.protobuf.ExtensionRegistryLite) registry);
}
public interface PlacementGroupOrBuilder extends
// @@protoc_insertion_point(interface_extends:yandex.cloud.compute.v1.PlacementGroup)
com.google.protobuf.MessageOrBuilder {
/**
*
* ID of the placement group. Generated at creation time.
*
*
* string id = 1;
* @return The id.
*/
java.lang.String getId();
/**
*
* ID of the placement group. Generated at creation time.
*
*
* string id = 1;
* @return The bytes for id.
*/
com.google.protobuf.ByteString
getIdBytes();
/**
*
* ID of the folder that the placement group belongs to.
*
*
* string folder_id = 2;
* @return The folderId.
*/
java.lang.String getFolderId();
/**
*
* ID of the folder that the placement group belongs to.
*
*
* string folder_id = 2;
* @return The bytes for folderId.
*/
com.google.protobuf.ByteString
getFolderIdBytes();
/**
*
* Creation timestamp.
*
*
* .google.protobuf.Timestamp created_at = 3;
* @return Whether the createdAt field is set.
*/
boolean hasCreatedAt();
/**
*
* Creation timestamp.
*
*
* .google.protobuf.Timestamp created_at = 3;
* @return The createdAt.
*/
com.google.protobuf.Timestamp getCreatedAt();
/**
*
* Creation timestamp.
*
*
* .google.protobuf.Timestamp created_at = 3;
*/
com.google.protobuf.TimestampOrBuilder getCreatedAtOrBuilder();
/**
*
* Name of the placement group.
* The name is unique within the folder.
*
*
* string name = 4;
* @return The name.
*/
java.lang.String getName();
/**
*
* Name of the placement group.
* The name is unique within the folder.
*
*
* string name = 4;
* @return The bytes for name.
*/
com.google.protobuf.ByteString
getNameBytes();
/**
*
* Description of the placement group. 0-256 characters long.
*
*
* string description = 5;
* @return The description.
*/
java.lang.String getDescription();
/**
*
* Description of the placement group. 0-256 characters long.
*
*
* string description = 5;
* @return The bytes for description.
*/
com.google.protobuf.ByteString
getDescriptionBytes();
/**
*
* Placement group labels as `key:value` pairs.
*
*
* map<string, string> labels = 6;
*/
int getLabelsCount();
/**
*
* Placement group labels as `key:value` pairs.
*
*
* map<string, string> labels = 6;
*/
boolean containsLabels(
java.lang.String key);
/**
* Use {@link #getLabelsMap()} instead.
*/
@java.lang.Deprecated
java.util.Map
getLabels();
/**
*
* Placement group labels as `key:value` pairs.
*
*
* map<string, string> labels = 6;
*/
java.util.Map
getLabelsMap();
/**
*
* Placement group labels as `key:value` pairs.
*
*
* map<string, string> labels = 6;
*/
java.lang.String getLabelsOrDefault(
java.lang.String key,
java.lang.String defaultValue);
/**
*
* Placement group labels as `key:value` pairs.
*
*
* map<string, string> labels = 6;
*/
java.lang.String getLabelsOrThrow(
java.lang.String key);
/**
*
* Anti-affinity placement strategy (`spread`). Instances are distributed
* over distinct failure domains.
*
*
* .yandex.cloud.compute.v1.SpreadPlacementStrategy spread_placement_strategy = 7;
* @return Whether the spreadPlacementStrategy field is set.
*/
boolean hasSpreadPlacementStrategy();
/**
*
* Anti-affinity placement strategy (`spread`). Instances are distributed
* over distinct failure domains.
*
*
* .yandex.cloud.compute.v1.SpreadPlacementStrategy spread_placement_strategy = 7;
* @return The spreadPlacementStrategy.
*/
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy getSpreadPlacementStrategy();
/**
*
* Anti-affinity placement strategy (`spread`). Instances are distributed
* over distinct failure domains.
*
*
* .yandex.cloud.compute.v1.SpreadPlacementStrategy spread_placement_strategy = 7;
*/
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategyOrBuilder getSpreadPlacementStrategyOrBuilder();
/**
* .yandex.cloud.compute.v1.PartitionPlacementStrategy partition_placement_strategy = 8;
* @return Whether the partitionPlacementStrategy field is set.
*/
boolean hasPartitionPlacementStrategy();
/**
* .yandex.cloud.compute.v1.PartitionPlacementStrategy partition_placement_strategy = 8;
* @return The partitionPlacementStrategy.
*/
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy getPartitionPlacementStrategy();
/**
* .yandex.cloud.compute.v1.PartitionPlacementStrategy partition_placement_strategy = 8;
*/
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategyOrBuilder getPartitionPlacementStrategyOrBuilder();
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup.PlacementStrategyCase getPlacementStrategyCase();
}
/**
* Protobuf type {@code yandex.cloud.compute.v1.PlacementGroup}
*/
public static final class PlacementGroup extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:yandex.cloud.compute.v1.PlacementGroup)
PlacementGroupOrBuilder {
private static final long serialVersionUID = 0L;
// Use PlacementGroup.newBuilder() to construct.
private PlacementGroup(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private PlacementGroup() {
id_ = "";
folderId_ = "";
name_ = "";
description_ = "";
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new PlacementGroup();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private PlacementGroup(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
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();
id_ = s;
break;
}
case 18: {
java.lang.String s = input.readStringRequireUtf8();
folderId_ = s;
break;
}
case 26: {
com.google.protobuf.Timestamp.Builder subBuilder = null;
if (createdAt_ != null) {
subBuilder = createdAt_.toBuilder();
}
createdAt_ = input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(createdAt_);
createdAt_ = subBuilder.buildPartial();
}
break;
}
case 34: {
java.lang.String s = input.readStringRequireUtf8();
name_ = s;
break;
}
case 42: {
java.lang.String s = input.readStringRequireUtf8();
description_ = s;
break;
}
case 50: {
if (!((mutable_bitField0_ & 0x00000001) != 0)) {
labels_ = com.google.protobuf.MapField.newMapField(
LabelsDefaultEntryHolder.defaultEntry);
mutable_bitField0_ |= 0x00000001;
}
com.google.protobuf.MapEntry
labels__ = input.readMessage(
LabelsDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry);
labels_.getMutableMap().put(
labels__.getKey(), labels__.getValue());
break;
}
case 58: {
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.Builder subBuilder = null;
if (placementStrategyCase_ == 7) {
subBuilder = ((yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy) placementStrategy_).toBuilder();
}
placementStrategy_ =
input.readMessage(yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom((yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy) placementStrategy_);
placementStrategy_ = subBuilder.buildPartial();
}
placementStrategyCase_ = 7;
break;
}
case 66: {
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.Builder subBuilder = null;
if (placementStrategyCase_ == 8) {
subBuilder = ((yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy) placementStrategy_).toBuilder();
}
placementStrategy_ =
input.readMessage(yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom((yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy) placementStrategy_);
placementStrategy_ = subBuilder.buildPartial();
}
placementStrategyCase_ = 8;
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.internal_static_yandex_cloud_compute_v1_PlacementGroup_descriptor;
}
@SuppressWarnings({"rawtypes"})
@java.lang.Override
protected com.google.protobuf.MapField internalGetMapField(
int number) {
switch (number) {
case 6:
return internalGetLabels();
default:
throw new RuntimeException(
"Invalid map field number: " + number);
}
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.internal_static_yandex_cloud_compute_v1_PlacementGroup_fieldAccessorTable
.ensureFieldAccessorsInitialized(
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup.class, yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup.Builder.class);
}
private int placementStrategyCase_ = 0;
private java.lang.Object placementStrategy_;
public enum PlacementStrategyCase
implements com.google.protobuf.Internal.EnumLite,
com.google.protobuf.AbstractMessage.InternalOneOfEnum {
SPREAD_PLACEMENT_STRATEGY(7),
PARTITION_PLACEMENT_STRATEGY(8),
PLACEMENTSTRATEGY_NOT_SET(0);
private final int value;
private PlacementStrategyCase(int value) {
this.value = value;
}
/**
* @param value The number of the enum to look for.
* @return The enum associated with the given number.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static PlacementStrategyCase valueOf(int value) {
return forNumber(value);
}
public static PlacementStrategyCase forNumber(int value) {
switch (value) {
case 7: return SPREAD_PLACEMENT_STRATEGY;
case 8: return PARTITION_PLACEMENT_STRATEGY;
case 0: return PLACEMENTSTRATEGY_NOT_SET;
default: return null;
}
}
public int getNumber() {
return this.value;
}
};
public PlacementStrategyCase
getPlacementStrategyCase() {
return PlacementStrategyCase.forNumber(
placementStrategyCase_);
}
public static final int ID_FIELD_NUMBER = 1;
private volatile java.lang.Object id_;
/**
*
* ID of the placement group. Generated at creation time.
*
*
* string id = 1;
* @return The id.
*/
@java.lang.Override
public java.lang.String getId() {
java.lang.Object ref = id_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
id_ = s;
return s;
}
}
/**
*
* ID of the placement group. Generated at creation time.
*
*
* string id = 1;
* @return The bytes for id.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getIdBytes() {
java.lang.Object ref = id_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
id_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int FOLDER_ID_FIELD_NUMBER = 2;
private volatile java.lang.Object folderId_;
/**
*
* ID of the folder that the placement group belongs to.
*
*
* string folder_id = 2;
* @return The folderId.
*/
@java.lang.Override
public java.lang.String getFolderId() {
java.lang.Object ref = folderId_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
folderId_ = s;
return s;
}
}
/**
*
* ID of the folder that the placement group belongs to.
*
*
* string folder_id = 2;
* @return The bytes for folderId.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getFolderIdBytes() {
java.lang.Object ref = folderId_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
folderId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int CREATED_AT_FIELD_NUMBER = 3;
private com.google.protobuf.Timestamp createdAt_;
/**
*
* Creation timestamp.
*
*
* .google.protobuf.Timestamp created_at = 3;
* @return Whether the createdAt field is set.
*/
@java.lang.Override
public boolean hasCreatedAt() {
return createdAt_ != null;
}
/**
*
* Creation timestamp.
*
*
* .google.protobuf.Timestamp created_at = 3;
* @return The createdAt.
*/
@java.lang.Override
public com.google.protobuf.Timestamp getCreatedAt() {
return createdAt_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createdAt_;
}
/**
*
* Creation timestamp.
*
*
* .google.protobuf.Timestamp created_at = 3;
*/
@java.lang.Override
public com.google.protobuf.TimestampOrBuilder getCreatedAtOrBuilder() {
return getCreatedAt();
}
public static final int NAME_FIELD_NUMBER = 4;
private volatile java.lang.Object name_;
/**
*
* Name of the placement group.
* The name is unique within the folder.
*
*
* string name = 4;
* @return The name.
*/
@java.lang.Override
public java.lang.String getName() {
java.lang.Object ref = name_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
name_ = s;
return s;
}
}
/**
*
* Name of the placement group.
* The name is unique within the folder.
*
*
* string name = 4;
* @return The bytes for name.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getNameBytes() {
java.lang.Object ref = name_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
name_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int DESCRIPTION_FIELD_NUMBER = 5;
private volatile java.lang.Object description_;
/**
*
* Description of the placement group. 0-256 characters long.
*
*
* string description = 5;
* @return The description.
*/
@java.lang.Override
public java.lang.String getDescription() {
java.lang.Object ref = description_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
description_ = s;
return s;
}
}
/**
*
* Description of the placement group. 0-256 characters long.
*
*
* string description = 5;
* @return The bytes for description.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getDescriptionBytes() {
java.lang.Object ref = description_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
description_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int LABELS_FIELD_NUMBER = 6;
private static final class LabelsDefaultEntryHolder {
static final com.google.protobuf.MapEntry<
java.lang.String, java.lang.String> defaultEntry =
com.google.protobuf.MapEntry
.newDefaultInstance(
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.internal_static_yandex_cloud_compute_v1_PlacementGroup_LabelsEntry_descriptor,
com.google.protobuf.WireFormat.FieldType.STRING,
"",
com.google.protobuf.WireFormat.FieldType.STRING,
"");
}
private com.google.protobuf.MapField<
java.lang.String, java.lang.String> labels_;
private com.google.protobuf.MapField
internalGetLabels() {
if (labels_ == null) {
return com.google.protobuf.MapField.emptyMapField(
LabelsDefaultEntryHolder.defaultEntry);
}
return labels_;
}
public int getLabelsCount() {
return internalGetLabels().getMap().size();
}
/**
*
* Placement group labels as `key:value` pairs.
*
*
* map<string, string> labels = 6;
*/
@java.lang.Override
public boolean containsLabels(
java.lang.String key) {
if (key == null) { throw new NullPointerException("map key"); }
return internalGetLabels().getMap().containsKey(key);
}
/**
* Use {@link #getLabelsMap()} instead.
*/
@java.lang.Override
@java.lang.Deprecated
public java.util.Map getLabels() {
return getLabelsMap();
}
/**
*
* Placement group labels as `key:value` pairs.
*
*
* map<string, string> labels = 6;
*/
@java.lang.Override
public java.util.Map getLabelsMap() {
return internalGetLabels().getMap();
}
/**
*
* Placement group labels as `key:value` pairs.
*
*
* map<string, string> labels = 6;
*/
@java.lang.Override
public java.lang.String getLabelsOrDefault(
java.lang.String key,
java.lang.String defaultValue) {
if (key == null) { throw new NullPointerException("map key"); }
java.util.Map map =
internalGetLabels().getMap();
return map.containsKey(key) ? map.get(key) : defaultValue;
}
/**
*
* Placement group labels as `key:value` pairs.
*
*
* map<string, string> labels = 6;
*/
@java.lang.Override
public java.lang.String getLabelsOrThrow(
java.lang.String key) {
if (key == null) { throw new NullPointerException("map key"); }
java.util.Map map =
internalGetLabels().getMap();
if (!map.containsKey(key)) {
throw new java.lang.IllegalArgumentException();
}
return map.get(key);
}
public static final int SPREAD_PLACEMENT_STRATEGY_FIELD_NUMBER = 7;
/**
*
* Anti-affinity placement strategy (`spread`). Instances are distributed
* over distinct failure domains.
*
*
* .yandex.cloud.compute.v1.SpreadPlacementStrategy spread_placement_strategy = 7;
* @return Whether the spreadPlacementStrategy field is set.
*/
@java.lang.Override
public boolean hasSpreadPlacementStrategy() {
return placementStrategyCase_ == 7;
}
/**
*
* Anti-affinity placement strategy (`spread`). Instances are distributed
* over distinct failure domains.
*
*
* .yandex.cloud.compute.v1.SpreadPlacementStrategy spread_placement_strategy = 7;
* @return The spreadPlacementStrategy.
*/
@java.lang.Override
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy getSpreadPlacementStrategy() {
if (placementStrategyCase_ == 7) {
return (yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy) placementStrategy_;
}
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.getDefaultInstance();
}
/**
*
* Anti-affinity placement strategy (`spread`). Instances are distributed
* over distinct failure domains.
*
*
* .yandex.cloud.compute.v1.SpreadPlacementStrategy spread_placement_strategy = 7;
*/
@java.lang.Override
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategyOrBuilder getSpreadPlacementStrategyOrBuilder() {
if (placementStrategyCase_ == 7) {
return (yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy) placementStrategy_;
}
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.getDefaultInstance();
}
public static final int PARTITION_PLACEMENT_STRATEGY_FIELD_NUMBER = 8;
/**
* .yandex.cloud.compute.v1.PartitionPlacementStrategy partition_placement_strategy = 8;
* @return Whether the partitionPlacementStrategy field is set.
*/
@java.lang.Override
public boolean hasPartitionPlacementStrategy() {
return placementStrategyCase_ == 8;
}
/**
* .yandex.cloud.compute.v1.PartitionPlacementStrategy partition_placement_strategy = 8;
* @return The partitionPlacementStrategy.
*/
@java.lang.Override
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy getPartitionPlacementStrategy() {
if (placementStrategyCase_ == 8) {
return (yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy) placementStrategy_;
}
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.getDefaultInstance();
}
/**
* .yandex.cloud.compute.v1.PartitionPlacementStrategy partition_placement_strategy = 8;
*/
@java.lang.Override
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategyOrBuilder getPartitionPlacementStrategyOrBuilder() {
if (placementStrategyCase_ == 8) {
return (yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy) placementStrategy_;
}
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.getDefaultInstance();
}
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 {
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(id_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, id_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(folderId_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, folderId_);
}
if (createdAt_ != null) {
output.writeMessage(3, getCreatedAt());
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 4, name_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 5, description_);
}
com.google.protobuf.GeneratedMessageV3
.serializeStringMapTo(
output,
internalGetLabels(),
LabelsDefaultEntryHolder.defaultEntry,
6);
if (placementStrategyCase_ == 7) {
output.writeMessage(7, (yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy) placementStrategy_);
}
if (placementStrategyCase_ == 8) {
output.writeMessage(8, (yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy) placementStrategy_);
}
unknownFields.writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(id_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, id_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(folderId_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, folderId_);
}
if (createdAt_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, getCreatedAt());
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, name_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, description_);
}
for (java.util.Map.Entry entry
: internalGetLabels().getMap().entrySet()) {
com.google.protobuf.MapEntry
labels__ = LabelsDefaultEntryHolder.defaultEntry.newBuilderForType()
.setKey(entry.getKey())
.setValue(entry.getValue())
.build();
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(6, labels__);
}
if (placementStrategyCase_ == 7) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(7, (yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy) placementStrategy_);
}
if (placementStrategyCase_ == 8) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(8, (yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy) placementStrategy_);
}
size += unknownFields.getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup)) {
return super.equals(obj);
}
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup other = (yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup) obj;
if (!getId()
.equals(other.getId())) return false;
if (!getFolderId()
.equals(other.getFolderId())) return false;
if (hasCreatedAt() != other.hasCreatedAt()) return false;
if (hasCreatedAt()) {
if (!getCreatedAt()
.equals(other.getCreatedAt())) return false;
}
if (!getName()
.equals(other.getName())) return false;
if (!getDescription()
.equals(other.getDescription())) return false;
if (!internalGetLabels().equals(
other.internalGetLabels())) return false;
if (!getPlacementStrategyCase().equals(other.getPlacementStrategyCase())) return false;
switch (placementStrategyCase_) {
case 7:
if (!getSpreadPlacementStrategy()
.equals(other.getSpreadPlacementStrategy())) return false;
break;
case 8:
if (!getPartitionPlacementStrategy()
.equals(other.getPartitionPlacementStrategy())) return false;
break;
case 0:
default:
}
if (!unknownFields.equals(other.unknownFields)) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + ID_FIELD_NUMBER;
hash = (53 * hash) + getId().hashCode();
hash = (37 * hash) + FOLDER_ID_FIELD_NUMBER;
hash = (53 * hash) + getFolderId().hashCode();
if (hasCreatedAt()) {
hash = (37 * hash) + CREATED_AT_FIELD_NUMBER;
hash = (53 * hash) + getCreatedAt().hashCode();
}
hash = (37 * hash) + NAME_FIELD_NUMBER;
hash = (53 * hash) + getName().hashCode();
hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER;
hash = (53 * hash) + getDescription().hashCode();
if (!internalGetLabels().getMap().isEmpty()) {
hash = (37 * hash) + LABELS_FIELD_NUMBER;
hash = (53 * hash) + internalGetLabels().hashCode();
}
switch (placementStrategyCase_) {
case 7:
hash = (37 * hash) + SPREAD_PLACEMENT_STRATEGY_FIELD_NUMBER;
hash = (53 * hash) + getSpreadPlacementStrategy().hashCode();
break;
case 8:
hash = (37 * hash) + PARTITION_PLACEMENT_STRATEGY_FIELD_NUMBER;
hash = (53 * hash) + getPartitionPlacementStrategy().hashCode();
break;
case 0:
default:
}
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup 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 yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup 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 yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup 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(yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup 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 yandex.cloud.compute.v1.PlacementGroup}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:yandex.cloud.compute.v1.PlacementGroup)
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroupOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.internal_static_yandex_cloud_compute_v1_PlacementGroup_descriptor;
}
@SuppressWarnings({"rawtypes"})
protected com.google.protobuf.MapField internalGetMapField(
int number) {
switch (number) {
case 6:
return internalGetLabels();
default:
throw new RuntimeException(
"Invalid map field number: " + number);
}
}
@SuppressWarnings({"rawtypes"})
protected com.google.protobuf.MapField internalGetMutableMapField(
int number) {
switch (number) {
case 6:
return internalGetMutableLabels();
default:
throw new RuntimeException(
"Invalid map field number: " + number);
}
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.internal_static_yandex_cloud_compute_v1_PlacementGroup_fieldAccessorTable
.ensureFieldAccessorsInitialized(
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup.class, yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup.Builder.class);
}
// Construct using yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
}
@java.lang.Override
public Builder clear() {
super.clear();
id_ = "";
folderId_ = "";
if (createdAtBuilder_ == null) {
createdAt_ = null;
} else {
createdAt_ = null;
createdAtBuilder_ = null;
}
name_ = "";
description_ = "";
internalGetMutableLabels().clear();
placementStrategyCase_ = 0;
placementStrategy_ = null;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.internal_static_yandex_cloud_compute_v1_PlacementGroup_descriptor;
}
@java.lang.Override
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup getDefaultInstanceForType() {
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup.getDefaultInstance();
}
@java.lang.Override
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup build() {
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup buildPartial() {
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup result = new yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup(this);
int from_bitField0_ = bitField0_;
result.id_ = id_;
result.folderId_ = folderId_;
if (createdAtBuilder_ == null) {
result.createdAt_ = createdAt_;
} else {
result.createdAt_ = createdAtBuilder_.build();
}
result.name_ = name_;
result.description_ = description_;
result.labels_ = internalGetLabels();
result.labels_.makeImmutable();
if (placementStrategyCase_ == 7) {
if (spreadPlacementStrategyBuilder_ == null) {
result.placementStrategy_ = placementStrategy_;
} else {
result.placementStrategy_ = spreadPlacementStrategyBuilder_.build();
}
}
if (placementStrategyCase_ == 8) {
if (partitionPlacementStrategyBuilder_ == null) {
result.placementStrategy_ = placementStrategy_;
} else {
result.placementStrategy_ = partitionPlacementStrategyBuilder_.build();
}
}
result.placementStrategyCase_ = placementStrategyCase_;
onBuilt();
return result;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup) {
return mergeFrom((yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup other) {
if (other == yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup.getDefaultInstance()) return this;
if (!other.getId().isEmpty()) {
id_ = other.id_;
onChanged();
}
if (!other.getFolderId().isEmpty()) {
folderId_ = other.folderId_;
onChanged();
}
if (other.hasCreatedAt()) {
mergeCreatedAt(other.getCreatedAt());
}
if (!other.getName().isEmpty()) {
name_ = other.name_;
onChanged();
}
if (!other.getDescription().isEmpty()) {
description_ = other.description_;
onChanged();
}
internalGetMutableLabels().mergeFrom(
other.internalGetLabels());
switch (other.getPlacementStrategyCase()) {
case SPREAD_PLACEMENT_STRATEGY: {
mergeSpreadPlacementStrategy(other.getSpreadPlacementStrategy());
break;
}
case PARTITION_PLACEMENT_STRATEGY: {
mergePartitionPlacementStrategy(other.getPartitionPlacementStrategy());
break;
}
case PLACEMENTSTRATEGY_NOT_SET: {
break;
}
}
this.mergeUnknownFields(other.unknownFields);
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 {
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private int placementStrategyCase_ = 0;
private java.lang.Object placementStrategy_;
public PlacementStrategyCase
getPlacementStrategyCase() {
return PlacementStrategyCase.forNumber(
placementStrategyCase_);
}
public Builder clearPlacementStrategy() {
placementStrategyCase_ = 0;
placementStrategy_ = null;
onChanged();
return this;
}
private int bitField0_;
private java.lang.Object id_ = "";
/**
*
* ID of the placement group. Generated at creation time.
*
*
* string id = 1;
* @return The id.
*/
public java.lang.String getId() {
java.lang.Object ref = id_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
id_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* ID of the placement group. Generated at creation time.
*
*
* string id = 1;
* @return The bytes for id.
*/
public com.google.protobuf.ByteString
getIdBytes() {
java.lang.Object ref = id_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
id_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* ID of the placement group. Generated at creation time.
*
*
* string id = 1;
* @param value The id to set.
* @return This builder for chaining.
*/
public Builder setId(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
id_ = value;
onChanged();
return this;
}
/**
*
* ID of the placement group. Generated at creation time.
*
*
* string id = 1;
* @return This builder for chaining.
*/
public Builder clearId() {
id_ = getDefaultInstance().getId();
onChanged();
return this;
}
/**
*
* ID of the placement group. Generated at creation time.
*
*
* string id = 1;
* @param value The bytes for id to set.
* @return This builder for chaining.
*/
public Builder setIdBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
id_ = value;
onChanged();
return this;
}
private java.lang.Object folderId_ = "";
/**
*
* ID of the folder that the placement group belongs to.
*
*
* string folder_id = 2;
* @return The folderId.
*/
public java.lang.String getFolderId() {
java.lang.Object ref = folderId_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
folderId_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* ID of the folder that the placement group belongs to.
*
*
* string folder_id = 2;
* @return The bytes for folderId.
*/
public com.google.protobuf.ByteString
getFolderIdBytes() {
java.lang.Object ref = folderId_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
folderId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* ID of the folder that the placement group belongs to.
*
*
* string folder_id = 2;
* @param value The folderId to set.
* @return This builder for chaining.
*/
public Builder setFolderId(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
folderId_ = value;
onChanged();
return this;
}
/**
*
* ID of the folder that the placement group belongs to.
*
*
* string folder_id = 2;
* @return This builder for chaining.
*/
public Builder clearFolderId() {
folderId_ = getDefaultInstance().getFolderId();
onChanged();
return this;
}
/**
*
* ID of the folder that the placement group belongs to.
*
*
* string folder_id = 2;
* @param value The bytes for folderId to set.
* @return This builder for chaining.
*/
public Builder setFolderIdBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
folderId_ = value;
onChanged();
return this;
}
private com.google.protobuf.Timestamp createdAt_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> createdAtBuilder_;
/**
*
* Creation timestamp.
*
*
* .google.protobuf.Timestamp created_at = 3;
* @return Whether the createdAt field is set.
*/
public boolean hasCreatedAt() {
return createdAtBuilder_ != null || createdAt_ != null;
}
/**
*
* Creation timestamp.
*
*
* .google.protobuf.Timestamp created_at = 3;
* @return The createdAt.
*/
public com.google.protobuf.Timestamp getCreatedAt() {
if (createdAtBuilder_ == null) {
return createdAt_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createdAt_;
} else {
return createdAtBuilder_.getMessage();
}
}
/**
*
* Creation timestamp.
*
*
* .google.protobuf.Timestamp created_at = 3;
*/
public Builder setCreatedAt(com.google.protobuf.Timestamp value) {
if (createdAtBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
createdAt_ = value;
onChanged();
} else {
createdAtBuilder_.setMessage(value);
}
return this;
}
/**
*
* Creation timestamp.
*
*
* .google.protobuf.Timestamp created_at = 3;
*/
public Builder setCreatedAt(
com.google.protobuf.Timestamp.Builder builderForValue) {
if (createdAtBuilder_ == null) {
createdAt_ = builderForValue.build();
onChanged();
} else {
createdAtBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
*
* Creation timestamp.
*
*
* .google.protobuf.Timestamp created_at = 3;
*/
public Builder mergeCreatedAt(com.google.protobuf.Timestamp value) {
if (createdAtBuilder_ == null) {
if (createdAt_ != null) {
createdAt_ =
com.google.protobuf.Timestamp.newBuilder(createdAt_).mergeFrom(value).buildPartial();
} else {
createdAt_ = value;
}
onChanged();
} else {
createdAtBuilder_.mergeFrom(value);
}
return this;
}
/**
*
* Creation timestamp.
*
*
* .google.protobuf.Timestamp created_at = 3;
*/
public Builder clearCreatedAt() {
if (createdAtBuilder_ == null) {
createdAt_ = null;
onChanged();
} else {
createdAt_ = null;
createdAtBuilder_ = null;
}
return this;
}
/**
*
* Creation timestamp.
*
*
* .google.protobuf.Timestamp created_at = 3;
*/
public com.google.protobuf.Timestamp.Builder getCreatedAtBuilder() {
onChanged();
return getCreatedAtFieldBuilder().getBuilder();
}
/**
*
* Creation timestamp.
*
*
* .google.protobuf.Timestamp created_at = 3;
*/
public com.google.protobuf.TimestampOrBuilder getCreatedAtOrBuilder() {
if (createdAtBuilder_ != null) {
return createdAtBuilder_.getMessageOrBuilder();
} else {
return createdAt_ == null ?
com.google.protobuf.Timestamp.getDefaultInstance() : createdAt_;
}
}
/**
*
* Creation timestamp.
*
*
* .google.protobuf.Timestamp created_at = 3;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>
getCreatedAtFieldBuilder() {
if (createdAtBuilder_ == null) {
createdAtBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>(
getCreatedAt(),
getParentForChildren(),
isClean());
createdAt_ = null;
}
return createdAtBuilder_;
}
private java.lang.Object name_ = "";
/**
*
* Name of the placement group.
* The name is unique within the folder.
*
*
* string name = 4;
* @return The name.
*/
public java.lang.String getName() {
java.lang.Object ref = name_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
name_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Name of the placement group.
* The name is unique within the folder.
*
*
* string name = 4;
* @return The bytes for name.
*/
public com.google.protobuf.ByteString
getNameBytes() {
java.lang.Object ref = name_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
name_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Name of the placement group.
* The name is unique within the folder.
*
*
* string name = 4;
* @param value The name to set.
* @return This builder for chaining.
*/
public Builder setName(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
name_ = value;
onChanged();
return this;
}
/**
*
* Name of the placement group.
* The name is unique within the folder.
*
*
* string name = 4;
* @return This builder for chaining.
*/
public Builder clearName() {
name_ = getDefaultInstance().getName();
onChanged();
return this;
}
/**
*
* Name of the placement group.
* The name is unique within the folder.
*
*
* string name = 4;
* @param value The bytes for name to set.
* @return This builder for chaining.
*/
public Builder setNameBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
name_ = value;
onChanged();
return this;
}
private java.lang.Object description_ = "";
/**
*
* Description of the placement group. 0-256 characters long.
*
*
* string description = 5;
* @return The description.
*/
public java.lang.String getDescription() {
java.lang.Object ref = description_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
description_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Description of the placement group. 0-256 characters long.
*
*
* string description = 5;
* @return The bytes for description.
*/
public com.google.protobuf.ByteString
getDescriptionBytes() {
java.lang.Object ref = description_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
description_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Description of the placement group. 0-256 characters long.
*
*
* string description = 5;
* @param value The description to set.
* @return This builder for chaining.
*/
public Builder setDescription(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
description_ = value;
onChanged();
return this;
}
/**
*
* Description of the placement group. 0-256 characters long.
*
*
* string description = 5;
* @return This builder for chaining.
*/
public Builder clearDescription() {
description_ = getDefaultInstance().getDescription();
onChanged();
return this;
}
/**
*
* Description of the placement group. 0-256 characters long.
*
*
* string description = 5;
* @param value The bytes for description to set.
* @return This builder for chaining.
*/
public Builder setDescriptionBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
description_ = value;
onChanged();
return this;
}
private com.google.protobuf.MapField<
java.lang.String, java.lang.String> labels_;
private com.google.protobuf.MapField
internalGetLabels() {
if (labels_ == null) {
return com.google.protobuf.MapField.emptyMapField(
LabelsDefaultEntryHolder.defaultEntry);
}
return labels_;
}
private com.google.protobuf.MapField
internalGetMutableLabels() {
onChanged();;
if (labels_ == null) {
labels_ = com.google.protobuf.MapField.newMapField(
LabelsDefaultEntryHolder.defaultEntry);
}
if (!labels_.isMutable()) {
labels_ = labels_.copy();
}
return labels_;
}
public int getLabelsCount() {
return internalGetLabels().getMap().size();
}
/**
*
* Placement group labels as `key:value` pairs.
*
*
* map<string, string> labels = 6;
*/
@java.lang.Override
public boolean containsLabels(
java.lang.String key) {
if (key == null) { throw new NullPointerException("map key"); }
return internalGetLabels().getMap().containsKey(key);
}
/**
* Use {@link #getLabelsMap()} instead.
*/
@java.lang.Override
@java.lang.Deprecated
public java.util.Map getLabels() {
return getLabelsMap();
}
/**
*
* Placement group labels as `key:value` pairs.
*
*
* map<string, string> labels = 6;
*/
@java.lang.Override
public java.util.Map getLabelsMap() {
return internalGetLabels().getMap();
}
/**
*
* Placement group labels as `key:value` pairs.
*
*
* map<string, string> labels = 6;
*/
@java.lang.Override
public java.lang.String getLabelsOrDefault(
java.lang.String key,
java.lang.String defaultValue) {
if (key == null) { throw new NullPointerException("map key"); }
java.util.Map map =
internalGetLabels().getMap();
return map.containsKey(key) ? map.get(key) : defaultValue;
}
/**
*
* Placement group labels as `key:value` pairs.
*
*
* map<string, string> labels = 6;
*/
@java.lang.Override
public java.lang.String getLabelsOrThrow(
java.lang.String key) {
if (key == null) { throw new NullPointerException("map key"); }
java.util.Map map =
internalGetLabels().getMap();
if (!map.containsKey(key)) {
throw new java.lang.IllegalArgumentException();
}
return map.get(key);
}
public Builder clearLabels() {
internalGetMutableLabels().getMutableMap()
.clear();
return this;
}
/**
*
* Placement group labels as `key:value` pairs.
*
*
* map<string, string> labels = 6;
*/
public Builder removeLabels(
java.lang.String key) {
if (key == null) { throw new NullPointerException("map key"); }
internalGetMutableLabels().getMutableMap()
.remove(key);
return this;
}
/**
* Use alternate mutation accessors instead.
*/
@java.lang.Deprecated
public java.util.Map
getMutableLabels() {
return internalGetMutableLabels().getMutableMap();
}
/**
*
* Placement group labels as `key:value` pairs.
*
*
* map<string, string> labels = 6;
*/
public Builder putLabels(
java.lang.String key,
java.lang.String value) {
if (key == null) { throw new NullPointerException("map key"); }
if (value == null) {
throw new NullPointerException("map value");
}
internalGetMutableLabels().getMutableMap()
.put(key, value);
return this;
}
/**
*
* Placement group labels as `key:value` pairs.
*
*
* map<string, string> labels = 6;
*/
public Builder putAllLabels(
java.util.Map values) {
internalGetMutableLabels().getMutableMap()
.putAll(values);
return this;
}
private com.google.protobuf.SingleFieldBuilderV3<
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy, yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.Builder, yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategyOrBuilder> spreadPlacementStrategyBuilder_;
/**
*
* Anti-affinity placement strategy (`spread`). Instances are distributed
* over distinct failure domains.
*
*
* .yandex.cloud.compute.v1.SpreadPlacementStrategy spread_placement_strategy = 7;
* @return Whether the spreadPlacementStrategy field is set.
*/
@java.lang.Override
public boolean hasSpreadPlacementStrategy() {
return placementStrategyCase_ == 7;
}
/**
*
* Anti-affinity placement strategy (`spread`). Instances are distributed
* over distinct failure domains.
*
*
* .yandex.cloud.compute.v1.SpreadPlacementStrategy spread_placement_strategy = 7;
* @return The spreadPlacementStrategy.
*/
@java.lang.Override
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy getSpreadPlacementStrategy() {
if (spreadPlacementStrategyBuilder_ == null) {
if (placementStrategyCase_ == 7) {
return (yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy) placementStrategy_;
}
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.getDefaultInstance();
} else {
if (placementStrategyCase_ == 7) {
return spreadPlacementStrategyBuilder_.getMessage();
}
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.getDefaultInstance();
}
}
/**
*
* Anti-affinity placement strategy (`spread`). Instances are distributed
* over distinct failure domains.
*
*
* .yandex.cloud.compute.v1.SpreadPlacementStrategy spread_placement_strategy = 7;
*/
public Builder setSpreadPlacementStrategy(yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy value) {
if (spreadPlacementStrategyBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
placementStrategy_ = value;
onChanged();
} else {
spreadPlacementStrategyBuilder_.setMessage(value);
}
placementStrategyCase_ = 7;
return this;
}
/**
*
* Anti-affinity placement strategy (`spread`). Instances are distributed
* over distinct failure domains.
*
*
* .yandex.cloud.compute.v1.SpreadPlacementStrategy spread_placement_strategy = 7;
*/
public Builder setSpreadPlacementStrategy(
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.Builder builderForValue) {
if (spreadPlacementStrategyBuilder_ == null) {
placementStrategy_ = builderForValue.build();
onChanged();
} else {
spreadPlacementStrategyBuilder_.setMessage(builderForValue.build());
}
placementStrategyCase_ = 7;
return this;
}
/**
*
* Anti-affinity placement strategy (`spread`). Instances are distributed
* over distinct failure domains.
*
*
* .yandex.cloud.compute.v1.SpreadPlacementStrategy spread_placement_strategy = 7;
*/
public Builder mergeSpreadPlacementStrategy(yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy value) {
if (spreadPlacementStrategyBuilder_ == null) {
if (placementStrategyCase_ == 7 &&
placementStrategy_ != yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.getDefaultInstance()) {
placementStrategy_ = yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.newBuilder((yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy) placementStrategy_)
.mergeFrom(value).buildPartial();
} else {
placementStrategy_ = value;
}
onChanged();
} else {
if (placementStrategyCase_ == 7) {
spreadPlacementStrategyBuilder_.mergeFrom(value);
}
spreadPlacementStrategyBuilder_.setMessage(value);
}
placementStrategyCase_ = 7;
return this;
}
/**
*
* Anti-affinity placement strategy (`spread`). Instances are distributed
* over distinct failure domains.
*
*
* .yandex.cloud.compute.v1.SpreadPlacementStrategy spread_placement_strategy = 7;
*/
public Builder clearSpreadPlacementStrategy() {
if (spreadPlacementStrategyBuilder_ == null) {
if (placementStrategyCase_ == 7) {
placementStrategyCase_ = 0;
placementStrategy_ = null;
onChanged();
}
} else {
if (placementStrategyCase_ == 7) {
placementStrategyCase_ = 0;
placementStrategy_ = null;
}
spreadPlacementStrategyBuilder_.clear();
}
return this;
}
/**
*
* Anti-affinity placement strategy (`spread`). Instances are distributed
* over distinct failure domains.
*
*
* .yandex.cloud.compute.v1.SpreadPlacementStrategy spread_placement_strategy = 7;
*/
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.Builder getSpreadPlacementStrategyBuilder() {
return getSpreadPlacementStrategyFieldBuilder().getBuilder();
}
/**
*
* Anti-affinity placement strategy (`spread`). Instances are distributed
* over distinct failure domains.
*
*
* .yandex.cloud.compute.v1.SpreadPlacementStrategy spread_placement_strategy = 7;
*/
@java.lang.Override
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategyOrBuilder getSpreadPlacementStrategyOrBuilder() {
if ((placementStrategyCase_ == 7) && (spreadPlacementStrategyBuilder_ != null)) {
return spreadPlacementStrategyBuilder_.getMessageOrBuilder();
} else {
if (placementStrategyCase_ == 7) {
return (yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy) placementStrategy_;
}
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.getDefaultInstance();
}
}
/**
*
* Anti-affinity placement strategy (`spread`). Instances are distributed
* over distinct failure domains.
*
*
* .yandex.cloud.compute.v1.SpreadPlacementStrategy spread_placement_strategy = 7;
*/
private com.google.protobuf.SingleFieldBuilderV3<
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy, yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.Builder, yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategyOrBuilder>
getSpreadPlacementStrategyFieldBuilder() {
if (spreadPlacementStrategyBuilder_ == null) {
if (!(placementStrategyCase_ == 7)) {
placementStrategy_ = yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.getDefaultInstance();
}
spreadPlacementStrategyBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy, yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.Builder, yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategyOrBuilder>(
(yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy) placementStrategy_,
getParentForChildren(),
isClean());
placementStrategy_ = null;
}
placementStrategyCase_ = 7;
onChanged();;
return spreadPlacementStrategyBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy, yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.Builder, yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategyOrBuilder> partitionPlacementStrategyBuilder_;
/**
* .yandex.cloud.compute.v1.PartitionPlacementStrategy partition_placement_strategy = 8;
* @return Whether the partitionPlacementStrategy field is set.
*/
@java.lang.Override
public boolean hasPartitionPlacementStrategy() {
return placementStrategyCase_ == 8;
}
/**
* .yandex.cloud.compute.v1.PartitionPlacementStrategy partition_placement_strategy = 8;
* @return The partitionPlacementStrategy.
*/
@java.lang.Override
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy getPartitionPlacementStrategy() {
if (partitionPlacementStrategyBuilder_ == null) {
if (placementStrategyCase_ == 8) {
return (yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy) placementStrategy_;
}
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.getDefaultInstance();
} else {
if (placementStrategyCase_ == 8) {
return partitionPlacementStrategyBuilder_.getMessage();
}
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.getDefaultInstance();
}
}
/**
* .yandex.cloud.compute.v1.PartitionPlacementStrategy partition_placement_strategy = 8;
*/
public Builder setPartitionPlacementStrategy(yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy value) {
if (partitionPlacementStrategyBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
placementStrategy_ = value;
onChanged();
} else {
partitionPlacementStrategyBuilder_.setMessage(value);
}
placementStrategyCase_ = 8;
return this;
}
/**
* .yandex.cloud.compute.v1.PartitionPlacementStrategy partition_placement_strategy = 8;
*/
public Builder setPartitionPlacementStrategy(
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.Builder builderForValue) {
if (partitionPlacementStrategyBuilder_ == null) {
placementStrategy_ = builderForValue.build();
onChanged();
} else {
partitionPlacementStrategyBuilder_.setMessage(builderForValue.build());
}
placementStrategyCase_ = 8;
return this;
}
/**
* .yandex.cloud.compute.v1.PartitionPlacementStrategy partition_placement_strategy = 8;
*/
public Builder mergePartitionPlacementStrategy(yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy value) {
if (partitionPlacementStrategyBuilder_ == null) {
if (placementStrategyCase_ == 8 &&
placementStrategy_ != yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.getDefaultInstance()) {
placementStrategy_ = yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.newBuilder((yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy) placementStrategy_)
.mergeFrom(value).buildPartial();
} else {
placementStrategy_ = value;
}
onChanged();
} else {
if (placementStrategyCase_ == 8) {
partitionPlacementStrategyBuilder_.mergeFrom(value);
}
partitionPlacementStrategyBuilder_.setMessage(value);
}
placementStrategyCase_ = 8;
return this;
}
/**
* .yandex.cloud.compute.v1.PartitionPlacementStrategy partition_placement_strategy = 8;
*/
public Builder clearPartitionPlacementStrategy() {
if (partitionPlacementStrategyBuilder_ == null) {
if (placementStrategyCase_ == 8) {
placementStrategyCase_ = 0;
placementStrategy_ = null;
onChanged();
}
} else {
if (placementStrategyCase_ == 8) {
placementStrategyCase_ = 0;
placementStrategy_ = null;
}
partitionPlacementStrategyBuilder_.clear();
}
return this;
}
/**
* .yandex.cloud.compute.v1.PartitionPlacementStrategy partition_placement_strategy = 8;
*/
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.Builder getPartitionPlacementStrategyBuilder() {
return getPartitionPlacementStrategyFieldBuilder().getBuilder();
}
/**
* .yandex.cloud.compute.v1.PartitionPlacementStrategy partition_placement_strategy = 8;
*/
@java.lang.Override
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategyOrBuilder getPartitionPlacementStrategyOrBuilder() {
if ((placementStrategyCase_ == 8) && (partitionPlacementStrategyBuilder_ != null)) {
return partitionPlacementStrategyBuilder_.getMessageOrBuilder();
} else {
if (placementStrategyCase_ == 8) {
return (yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy) placementStrategy_;
}
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.getDefaultInstance();
}
}
/**
* .yandex.cloud.compute.v1.PartitionPlacementStrategy partition_placement_strategy = 8;
*/
private com.google.protobuf.SingleFieldBuilderV3<
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy, yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.Builder, yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategyOrBuilder>
getPartitionPlacementStrategyFieldBuilder() {
if (partitionPlacementStrategyBuilder_ == null) {
if (!(placementStrategyCase_ == 8)) {
placementStrategy_ = yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.getDefaultInstance();
}
partitionPlacementStrategyBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy, yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.Builder, yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategyOrBuilder>(
(yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy) placementStrategy_,
getParentForChildren(),
isClean());
placementStrategy_ = null;
}
placementStrategyCase_ = 8;
onChanged();;
return partitionPlacementStrategyBuilder_;
}
@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:yandex.cloud.compute.v1.PlacementGroup)
}
// @@protoc_insertion_point(class_scope:yandex.cloud.compute.v1.PlacementGroup)
private static final yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup();
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public PlacementGroup parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new PlacementGroup(input, extensionRegistry);
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PlacementGroup getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface SpreadPlacementStrategyOrBuilder extends
// @@protoc_insertion_point(interface_extends:yandex.cloud.compute.v1.SpreadPlacementStrategy)
com.google.protobuf.MessageOrBuilder {
}
/**
*
* This is an empty structure that must be passed to explicitly
* specify the required placement strategy.
*
*
* Protobuf type {@code yandex.cloud.compute.v1.SpreadPlacementStrategy}
*/
public static final class SpreadPlacementStrategy extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:yandex.cloud.compute.v1.SpreadPlacementStrategy)
SpreadPlacementStrategyOrBuilder {
private static final long serialVersionUID = 0L;
// Use SpreadPlacementStrategy.newBuilder() to construct.
private SpreadPlacementStrategy(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private SpreadPlacementStrategy() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new SpreadPlacementStrategy();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private SpreadPlacementStrategy(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.internal_static_yandex_cloud_compute_v1_SpreadPlacementStrategy_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.internal_static_yandex_cloud_compute_v1_SpreadPlacementStrategy_fieldAccessorTable
.ensureFieldAccessorsInitialized(
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.class, yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.Builder.class);
}
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 {
unknownFields.writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
size += unknownFields.getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy)) {
return super.equals(obj);
}
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy other = (yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy) obj;
if (!unknownFields.equals(other.unknownFields)) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy 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 yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy 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 yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy 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(yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy 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;
}
/**
*
* This is an empty structure that must be passed to explicitly
* specify the required placement strategy.
*
*
* Protobuf type {@code yandex.cloud.compute.v1.SpreadPlacementStrategy}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:yandex.cloud.compute.v1.SpreadPlacementStrategy)
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategyOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.internal_static_yandex_cloud_compute_v1_SpreadPlacementStrategy_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.internal_static_yandex_cloud_compute_v1_SpreadPlacementStrategy_fieldAccessorTable
.ensureFieldAccessorsInitialized(
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.class, yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.Builder.class);
}
// Construct using yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
}
@java.lang.Override
public Builder clear() {
super.clear();
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.internal_static_yandex_cloud_compute_v1_SpreadPlacementStrategy_descriptor;
}
@java.lang.Override
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy getDefaultInstanceForType() {
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.getDefaultInstance();
}
@java.lang.Override
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy build() {
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy buildPartial() {
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy result = new yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy(this);
onBuilt();
return result;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy) {
return mergeFrom((yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy other) {
if (other == yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy.getDefaultInstance()) return this;
this.mergeUnknownFields(other.unknownFields);
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 {
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
@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:yandex.cloud.compute.v1.SpreadPlacementStrategy)
}
// @@protoc_insertion_point(class_scope:yandex.cloud.compute.v1.SpreadPlacementStrategy)
private static final yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy();
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public SpreadPlacementStrategy parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new SpreadPlacementStrategy(input, extensionRegistry);
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.SpreadPlacementStrategy getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface PartitionPlacementStrategyOrBuilder extends
// @@protoc_insertion_point(interface_extends:yandex.cloud.compute.v1.PartitionPlacementStrategy)
com.google.protobuf.MessageOrBuilder {
/**
* int64 partitions = 1 [(.yandex.cloud.value) = "2-5"];
* @return The partitions.
*/
long getPartitions();
}
/**
* Protobuf type {@code yandex.cloud.compute.v1.PartitionPlacementStrategy}
*/
public static final class PartitionPlacementStrategy extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:yandex.cloud.compute.v1.PartitionPlacementStrategy)
PartitionPlacementStrategyOrBuilder {
private static final long serialVersionUID = 0L;
// Use PartitionPlacementStrategy.newBuilder() to construct.
private PartitionPlacementStrategy(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private PartitionPlacementStrategy() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new PartitionPlacementStrategy();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private PartitionPlacementStrategy(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
partitions_ = input.readInt64();
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.internal_static_yandex_cloud_compute_v1_PartitionPlacementStrategy_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.internal_static_yandex_cloud_compute_v1_PartitionPlacementStrategy_fieldAccessorTable
.ensureFieldAccessorsInitialized(
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.class, yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.Builder.class);
}
public static final int PARTITIONS_FIELD_NUMBER = 1;
private long partitions_;
/**
* int64 partitions = 1 [(.yandex.cloud.value) = "2-5"];
* @return The partitions.
*/
@java.lang.Override
public long getPartitions() {
return partitions_;
}
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 {
if (partitions_ != 0L) {
output.writeInt64(1, partitions_);
}
unknownFields.writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (partitions_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(1, partitions_);
}
size += unknownFields.getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy)) {
return super.equals(obj);
}
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy other = (yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy) obj;
if (getPartitions()
!= other.getPartitions()) return false;
if (!unknownFields.equals(other.unknownFields)) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + PARTITIONS_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getPartitions());
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy 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 yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy 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 yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy 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(yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy 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 yandex.cloud.compute.v1.PartitionPlacementStrategy}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:yandex.cloud.compute.v1.PartitionPlacementStrategy)
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategyOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.internal_static_yandex_cloud_compute_v1_PartitionPlacementStrategy_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.internal_static_yandex_cloud_compute_v1_PartitionPlacementStrategy_fieldAccessorTable
.ensureFieldAccessorsInitialized(
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.class, yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.Builder.class);
}
// Construct using yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
}
@java.lang.Override
public Builder clear() {
super.clear();
partitions_ = 0L;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.internal_static_yandex_cloud_compute_v1_PartitionPlacementStrategy_descriptor;
}
@java.lang.Override
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy getDefaultInstanceForType() {
return yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.getDefaultInstance();
}
@java.lang.Override
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy build() {
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy buildPartial() {
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy result = new yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy(this);
result.partitions_ = partitions_;
onBuilt();
return result;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy) {
return mergeFrom((yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy other) {
if (other == yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy.getDefaultInstance()) return this;
if (other.getPartitions() != 0L) {
setPartitions(other.getPartitions());
}
this.mergeUnknownFields(other.unknownFields);
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 {
yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private long partitions_ ;
/**
* int64 partitions = 1 [(.yandex.cloud.value) = "2-5"];
* @return The partitions.
*/
@java.lang.Override
public long getPartitions() {
return partitions_;
}
/**
* int64 partitions = 1 [(.yandex.cloud.value) = "2-5"];
* @param value The partitions to set.
* @return This builder for chaining.
*/
public Builder setPartitions(long value) {
partitions_ = value;
onChanged();
return this;
}
/**
* int64 partitions = 1 [(.yandex.cloud.value) = "2-5"];
* @return This builder for chaining.
*/
public Builder clearPartitions() {
partitions_ = 0L;
onChanged();
return this;
}
@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:yandex.cloud.compute.v1.PartitionPlacementStrategy)
}
// @@protoc_insertion_point(class_scope:yandex.cloud.compute.v1.PartitionPlacementStrategy)
private static final yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy();
}
public static yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public PartitionPlacementStrategy parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new PartitionPlacementStrategy(input, extensionRegistry);
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public yandex.cloud.api.compute.v1.PlacementGroupOuterClass.PartitionPlacementStrategy getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_yandex_cloud_compute_v1_PlacementGroup_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_yandex_cloud_compute_v1_PlacementGroup_fieldAccessorTable;
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_yandex_cloud_compute_v1_PlacementGroup_LabelsEntry_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_yandex_cloud_compute_v1_PlacementGroup_LabelsEntry_fieldAccessorTable;
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_yandex_cloud_compute_v1_SpreadPlacementStrategy_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_yandex_cloud_compute_v1_SpreadPlacementStrategy_fieldAccessorTable;
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_yandex_cloud_compute_v1_PartitionPlacementStrategy_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_yandex_cloud_compute_v1_PartitionPlacementStrategy_fieldAccessorTable;
public static com.google.protobuf.Descriptors.FileDescriptor
getDescriptor() {
return descriptor;
}
private static com.google.protobuf.Descriptors.FileDescriptor
descriptor;
static {
java.lang.String[] descriptorData = {
"\n-yandex/cloud/compute/v1/placement_grou" +
"p.proto\022\027yandex.cloud.compute.v1\032\037google" +
"/protobuf/timestamp.proto\032\035yandex/cloud/" +
"validation.proto\"\306\003\n\016PlacementGroup\022\n\n\002i" +
"d\030\001 \001(\t\022\021\n\tfolder_id\030\002 \001(\t\022.\n\ncreated_at" +
"\030\003 \001(\0132\032.google.protobuf.Timestamp\022\014\n\004na" +
"me\030\004 \001(\t\022\023\n\013description\030\005 \001(\t\022C\n\006labels\030" +
"\006 \003(\01323.yandex.cloud.compute.v1.Placemen" +
"tGroup.LabelsEntry\022U\n\031spread_placement_s" +
"trategy\030\007 \001(\01320.yandex.cloud.compute.v1." +
"SpreadPlacementStrategyH\000\022[\n\034partition_p" +
"lacement_strategy\030\010 \001(\01323.yandex.cloud.c" +
"ompute.v1.PartitionPlacementStrategyH\000\032-" +
"\n\013LabelsEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(" +
"\t:\0028\001B\032\n\022placement_strategy\022\004\300\3011\001\"\031\n\027Spr" +
"eadPlacementStrategy\"9\n\032PartitionPlaceme" +
"ntStrategy\022\033\n\npartitions\030\001 \001(\003B\007\372\3071\0032-5B" +
"b\n\033yandex.cloud.api.compute.v1ZCgithub.c" +
"om/yandex-cloud/go-genproto/yandex/cloud" +
"/compute/v1;computeb\006proto3"
};
descriptor = com.google.protobuf.Descriptors.FileDescriptor
.internalBuildGeneratedFileFrom(descriptorData,
new com.google.protobuf.Descriptors.FileDescriptor[] {
com.google.protobuf.TimestampProto.getDescriptor(),
yandex.cloud.api.Validation.getDescriptor(),
});
internal_static_yandex_cloud_compute_v1_PlacementGroup_descriptor =
getDescriptor().getMessageTypes().get(0);
internal_static_yandex_cloud_compute_v1_PlacementGroup_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_yandex_cloud_compute_v1_PlacementGroup_descriptor,
new java.lang.String[] { "Id", "FolderId", "CreatedAt", "Name", "Description", "Labels", "SpreadPlacementStrategy", "PartitionPlacementStrategy", "PlacementStrategy", });
internal_static_yandex_cloud_compute_v1_PlacementGroup_LabelsEntry_descriptor =
internal_static_yandex_cloud_compute_v1_PlacementGroup_descriptor.getNestedTypes().get(0);
internal_static_yandex_cloud_compute_v1_PlacementGroup_LabelsEntry_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_yandex_cloud_compute_v1_PlacementGroup_LabelsEntry_descriptor,
new java.lang.String[] { "Key", "Value", });
internal_static_yandex_cloud_compute_v1_SpreadPlacementStrategy_descriptor =
getDescriptor().getMessageTypes().get(1);
internal_static_yandex_cloud_compute_v1_SpreadPlacementStrategy_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_yandex_cloud_compute_v1_SpreadPlacementStrategy_descriptor,
new java.lang.String[] { });
internal_static_yandex_cloud_compute_v1_PartitionPlacementStrategy_descriptor =
getDescriptor().getMessageTypes().get(2);
internal_static_yandex_cloud_compute_v1_PartitionPlacementStrategy_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_yandex_cloud_compute_v1_PartitionPlacementStrategy_descriptor,
new java.lang.String[] { "Partitions", });
com.google.protobuf.ExtensionRegistry registry =
com.google.protobuf.ExtensionRegistry.newInstance();
registry.add(yandex.cloud.api.Validation.exactlyOne);
registry.add(yandex.cloud.api.Validation.value);
com.google.protobuf.Descriptors.FileDescriptor
.internalUpdateFileDescriptor(descriptor, registry);
com.google.protobuf.TimestampProto.getDescriptor();
yandex.cloud.api.Validation.getDescriptor();
}
// @@protoc_insertion_point(outer_class_scope)
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy