/** * Updates the GCRule of existing ColumnFamily * * @param familyId * @param gcRule * @return */ public ModifyColumnFamiliesRequest updateFamily(String familyId, GCRule gcRule) { Preconditions.checkNotNull(gcRule); Modification.Builder modification = Modification.newBuilder().setId(familyId); modification.getUpdateBuilder().setGcRule(gcRule.toProto()); modFamilyRequest.addModifications(modification.build()); return this; }
@java.lang.Override public com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification buildPartial() { com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification result = new com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification(this); result.id_ = id_; if (modCase_ == 2) { if (createBuilder_ == null) { result.mod_ = mod_; } else { result.mod_ = createBuilder_.build(); } } if (modCase_ == 3) { if (updateBuilder_ == null) { result.mod_ = mod_; } else { result.mod_ = updateBuilder_.build(); } } if (modCase_ == 4) { result.mod_ = mod_; } result.modCase_ = modCase_; onBuilt(); return result; }
@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification)) { return super.equals(obj); } com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification other = (com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification) obj; boolean result = true; result = result && getId().equals(other.getId()); result = result && getModCase().equals(other.getModCase()); if (!result) return false; switch (modCase_) { case 2: result = result && getCreate().equals(other.getCreate()); break; case 3: result = result && getUpdate().equals(other.getUpdate()); break; case 4: result = result && (getDrop() == other.getDrop()); break; case 0: default: } result = result && unknownFields.equals(other.unknownFields); return result; }
if (other == com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification .getDefaultInstance()) return this; if (!other.getId().isEmpty()) { id_ = other.id_; onChanged(); switch (other.getModCase()) { case CREATE: mergeCreate(other.getCreate()); break; mergeUpdate(other.getUpdate()); break; setDrop(other.getDrop()); break;
result = result && getId() .equals(other.getId()); result = result && getModCase().equals( other.getModCase()); if (!result) return false; switch (modCase_) { case 2: result = result && getCreate() .equals(other.getCreate()); break; case 3: result = result && getUpdate() .equals(other.getUpdate()); break; case 4: result = result && (getDrop() == other.getDrop()); break; case 0:
@java.lang.Override public com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification buildPartial() { com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification result = new com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification(this); result.id_ = id_; if (modCase_ == 2) { if (createBuilder_ == null) { result.mod_ = mod_; } else { result.mod_ = createBuilder_.build(); } } if (modCase_ == 3) { if (updateBuilder_ == null) { result.mod_ = mod_; } else { result.mod_ = updateBuilder_.build(); } } if (modCase_ == 4) { result.mod_ = mod_; } result.modCase_ = modCase_; onBuilt(); return result; }
@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(); switch (modCase_) { case 2: hash = (37 * hash) + CREATE_FIELD_NUMBER; hash = (53 * hash) + getCreate().hashCode(); break; case 3: hash = (37 * hash) + UPDATE_FIELD_NUMBER; hash = (53 * hash) + getUpdate().hashCode(); break; case 4: hash = (37 * hash) + DROP_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getDrop()); break; case 0: default: } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; }
@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(); switch (modCase_) { case 2: hash = (37 * hash) + CREATE_FIELD_NUMBER; hash = (53 * hash) + getCreate().hashCode(); break; case 3: hash = (37 * hash) + UPDATE_FIELD_NUMBER; hash = (53 * hash) + getUpdate().hashCode(); break; case 4: hash = (37 * hash) + DROP_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( getDrop()); break; case 0: default: } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; }
@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification)) { return super.equals(obj); } com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification other = (com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification) obj; boolean result = true; result = result && getId().equals(other.getId()); result = result && getModCase().equals(other.getModCase()); if (!result) return false; switch (modCase_) { case 2: result = result && getCreate().equals(other.getCreate()); break; case 3: result = result && getUpdate().equals(other.getUpdate()); break; case 4: result = result && (getDrop() == other.getDrop()); break; case 0: default: } result = result && unknownFields.equals(other.unknownFields); return result; }
public com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification buildPartial() { com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification result = new com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification(this); result.id_ = id_; if (modCase_ == 2) { if (createBuilder_ == null) { result.mod_ = mod_; } else { result.mod_ = createBuilder_.build(); } } if (modCase_ == 3) { if (updateBuilder_ == null) { result.mod_ = mod_; } else { result.mod_ = updateBuilder_.build(); } } if (modCase_ == 4) { result.mod_ = mod_; } result.modCase_ = modCase_; onBuilt(); return result; }
public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (!getIdBytes().isEmpty()) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, id_); } if (modCase_ == 2) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(2, (com.google.bigtable.admin.v2.ColumnFamily) mod_); } if (modCase_ == 3) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(3, (com.google.bigtable.admin.v2.ColumnFamily) mod_); } if (modCase_ == 4) { size += com.google.protobuf.CodedOutputStream .computeBoolSize( 4, (boolean)((java.lang.Boolean) mod_)); } memoizedSize = size; return size; }
@java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (!getIdBytes().isEmpty()) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, id_); } if (modCase_ == 2) { size += com.google.protobuf.CodedOutputStream.computeMessageSize( 2, (com.google.bigtable.admin.v2.ColumnFamily) mod_); } if (modCase_ == 3) { size += com.google.protobuf.CodedOutputStream.computeMessageSize( 3, (com.google.bigtable.admin.v2.ColumnFamily) mod_); } if (modCase_ == 4) { size += com.google.protobuf.CodedOutputStream.computeBoolSize( 4, (boolean) ((java.lang.Boolean) mod_)); } size += unknownFields.getSerializedSize(); memoizedSize = size; return size; }
public Builder mergeFrom(com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification other) { if (other == com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification.getDefaultInstance()) return this; if (!other.getId().isEmpty()) { id_ = other.id_; onChanged(); } switch (other.getModCase()) { case CREATE: { mergeCreate(other.getCreate()); break; } case UPDATE: { mergeUpdate(other.getUpdate()); break; } case DROP: { setDrop(other.getDrop()); break; } case MOD_NOT_SET: { break; } } onChanged(); return this; }
/** * * * <pre> * Modifications to be atomically applied to the specified table's families. * Entries are applied in order, meaning that earlier modifications can be * masked by later ones (in the case of repeated updates to the same family, * for example). * </pre> * * <code> * repeated .google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification modifications = 2; * </code> */ public com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification.Builder addModificationsBuilder(int index) { return getModificationsFieldBuilder() .addBuilder( index, com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification .getDefaultInstance()); } /**
/** * * * <pre> * Modifications to be atomically applied to the specified table's families. * Entries are applied in order, meaning that earlier modifications can be * masked by later ones (in the case of repeated updates to the same family, * for example). * </pre> * * <code> * repeated .google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification modifications = 2; * </code> */ public com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification.Builder addModificationsBuilder() { return getModificationsFieldBuilder() .addBuilder( com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification .getDefaultInstance()); } /**
@java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!getIdBytes().isEmpty()) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, id_); } if (modCase_ == 2) { output.writeMessage(2, (com.google.bigtable.admin.v2.ColumnFamily) mod_); } if (modCase_ == 3) { output.writeMessage(3, (com.google.bigtable.admin.v2.ColumnFamily) mod_); } if (modCase_ == 4) { output.writeBool(4, (boolean) ((java.lang.Boolean) mod_)); } unknownFields.writeTo(output); }
/** * <pre> * Modifications to be atomically applied to the specified table's families. * Entries are applied in order, meaning that earlier modifications can be * masked by later ones (in the case of repeated updates to the same family, * for example). * </pre> * * <code>repeated .google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification modifications = 2;</code> */ public com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification.Builder addModificationsBuilder( int index) { return getModificationsFieldBuilder().addBuilder( index, com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification.getDefaultInstance()); } /**
public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!getIdBytes().isEmpty()) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, id_); } if (modCase_ == 2) { output.writeMessage(2, (com.google.bigtable.admin.v2.ColumnFamily) mod_); } if (modCase_ == 3) { output.writeMessage(3, (com.google.bigtable.admin.v2.ColumnFamily) mod_); } if (modCase_ == 4) { output.writeBool( 4, (boolean)((java.lang.Boolean) mod_)); } }
/** * <pre> * Modifications to be atomically applied to the specified table's families. * Entries are applied in order, meaning that earlier modifications can be * masked by later ones (in the case of repeated updates to the same family, * for example). * </pre> * * <code>repeated .google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification modifications = 2;</code> */ public com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification.Builder addModificationsBuilder() { return getModificationsFieldBuilder().addBuilder( com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification.getDefaultInstance()); } /**
public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() {