/** * * * <pre> * The group resource associated with the configuration. * </pre> * * <code>.google.monitoring.v3.UptimeCheckConfig.ResourceGroup resource_group = 4;</code> */ public com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup getResourceGroup() { if (resourceGroupBuilder_ == null) { if (resourceCase_ == 4) { return (com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup) resource_; } return com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup.getDefaultInstance(); } else { if (resourceCase_ == 4) { return resourceGroupBuilder_.getMessage(); } return com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup.getDefaultInstance(); } } /**
@java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + GROUP_ID_FIELD_NUMBER; hash = (53 * hash) + getGroupId().hashCode(); hash = (37 * hash) + RESOURCE_TYPE_FIELD_NUMBER; hash = (53 * hash) + resourceType_; hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; }
@java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (!getGroupIdBytes().isEmpty()) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, groupId_); } if (resourceType_ != com.google.monitoring.v3.GroupResourceType.RESOURCE_TYPE_UNSPECIFIED.getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, resourceType_); } size += unknownFields.getSerializedSize(); memoizedSize = size; return size; }
case 4: hash = (37 * hash) + RESOURCE_GROUP_FIELD_NUMBER; hash = (53 * hash) + getResourceGroup().hashCode(); break; case 0:
break; case 4: result = result && getResourceGroup().equals(other.getResourceGroup()); break; case 0:
if (!parseUnknownFieldProto3(input, unknownFields, extensionRegistry, tag)) { done = true; } finally { this.unknownFields = unknownFields.build(); makeExtensionsImmutable();
if (resourceCase_ == 4 && resource_ != com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup.getDefaultInstance()) { resource_ = com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup.newBuilder( (com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup) resource_) .mergeFrom(value)
if (resourceGroupBuilder_ == null) { if (!(resourceCase_ == 4)) { resource_ = com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup.getDefaultInstance();
/** * * * <pre> * The group resource associated with the configuration. * </pre> * * <code>.google.monitoring.v3.UptimeCheckConfig.ResourceGroup resource_group = 4;</code> */ public com.google.monitoring.v3.UptimeCheckConfig.ResourceGroupOrBuilder getResourceGroupOrBuilder() { if ((resourceCase_ == 4) && (resourceGroupBuilder_ != null)) { return resourceGroupBuilder_.getMessageOrBuilder(); } else { if (resourceCase_ == 4) { return (com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup) resource_; } return com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup.getDefaultInstance(); } } /**
/** * * * <pre> * The group resource associated with the configuration. * </pre> * * <code>.google.monitoring.v3.UptimeCheckConfig.ResourceGroup resource_group = 4;</code> */ public com.google.monitoring.v3.UptimeCheckConfig.ResourceGroupOrBuilder getResourceGroupOrBuilder() { if (resourceCase_ == 4) { return (com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup) resource_; } return com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup.getDefaultInstance(); }
/** * * * <pre> * The group resource associated with the configuration. * </pre> * * <code>.google.monitoring.v3.UptimeCheckConfig.ResourceGroup resource_group = 4;</code> */ public com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup getResourceGroup() { if (resourceCase_ == 4) { return (com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup) resource_; } return com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup.getDefaultInstance(); } /**
@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup)) { return super.equals(obj); } com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup other = (com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup) obj; boolean result = true; result = result && getGroupId().equals(other.getGroupId()); result = result && resourceType_ == other.resourceType_; result = result && unknownFields.equals(other.unknownFields); return result; }
/** * * * <pre> * The group of resources being monitored. Should be only the * group_id, not projects/<project_id>/groups/<group_id>. * </pre> * * <code>string group_id = 1;</code> */ public Builder clearGroupId() { groupId_ = getDefaultInstance().getGroupId(); onChanged(); return this; } /**
public Builder mergeFrom(com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup other) { if (other == com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup.getDefaultInstance()) return this; if (!other.getGroupId().isEmpty()) { groupId_ = other.groupId_; onChanged(); } if (other.resourceType_ != 0) { setResourceTypeValue(other.getResourceTypeValue()); } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; }
@java.lang.Override public com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup getDefaultInstanceForType() { return com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup.getDefaultInstance(); }
@java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!getGroupIdBytes().isEmpty()) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, groupId_); } if (resourceType_ != com.google.monitoring.v3.GroupResourceType.RESOURCE_TYPE_UNSPECIFIED.getNumber()) { output.writeEnum(2, resourceType_); } unknownFields.writeTo(output); }
@java.lang.Override public com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup buildPartial() { com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup result = new com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup(this); result.groupId_ = groupId_; result.resourceType_ = resourceType_; onBuilt(); return result; }
@java.lang.Override public com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup build() { com.google.monitoring.v3.UptimeCheckConfig.ResourceGroup result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; }