public Builder mergeFrom(com.google.cloud.iot.v1.DeviceRegistry other) { if (other == com.google.cloud.iot.v1.DeviceRegistry.getDefaultInstance()) return this; if (!other.getId().isEmpty()) { id_ = other.id_; onChanged(); if (!other.getName().isEmpty()) { name_ = other.name_; onChanged(); if (other.hasStateNotificationConfig()) { mergeStateNotificationConfig(other.getStateNotificationConfig()); if (other.hasMqttConfig()) { mergeMqttConfig(other.getMqttConfig()); if (other.hasHttpConfig()) { mergeHttpConfig(other.getHttpConfig()); setLogLevelValue(other.getLogLevelValue());
@java.lang.Override public Builder newBuilderForType() { return newBuilder(); }
@java.lang.Override public com.google.cloud.iot.v1.DeviceRegistry buildPartial() { com.google.cloud.iot.v1.DeviceRegistry result = new com.google.cloud.iot.v1.DeviceRegistry(this); int from_bitField0_ = bitField0_; int to_bitField0_ = 0;
/** * * * <pre> * The identifier of this device registry. For example, `myRegistry`. * </pre> * * <code>string id = 1;</code> */ public Builder clearId() { id_ = getDefaultInstance().getId(); onChanged(); return this; } /**
/** * * * <pre> * The resource path name. For example, * `projects/example-project/locations/us-central1/registries/my-registry`. * </pre> * * <code>string name = 2;</code> */ public Builder clearName() { name_ = getDefaultInstance().getName(); onChanged(); return this; } /**
result = result && getId().equals(other.getId()); result = result && getName().equals(other.getName()); result = result && getEventNotificationConfigsList().equals(other.getEventNotificationConfigsList()); result = result && (hasStateNotificationConfig() == other.hasStateNotificationConfig()); if (hasStateNotificationConfig()) { result = result && getStateNotificationConfig().equals(other.getStateNotificationConfig()); result = result && (hasMqttConfig() == other.hasMqttConfig()); if (hasMqttConfig()) { result = result && getMqttConfig().equals(other.getMqttConfig()); result = result && (hasHttpConfig() == other.hasHttpConfig()); if (hasHttpConfig()) { result = result && getHttpConfig().equals(other.getHttpConfig()); result = result && getCredentialsList().equals(other.getCredentialsList()); result = result && unknownFields.equals(other.unknownFields); return result;
hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + ID_FIELD_NUMBER; hash = (53 * hash) + getId().hashCode(); hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); if (getEventNotificationConfigsCount() > 0) { hash = (37 * hash) + EVENT_NOTIFICATION_CONFIGS_FIELD_NUMBER; hash = (53 * hash) + getEventNotificationConfigsList().hashCode(); if (hasStateNotificationConfig()) { hash = (37 * hash) + STATE_NOTIFICATION_CONFIG_FIELD_NUMBER; hash = (53 * hash) + getStateNotificationConfig().hashCode(); if (hasMqttConfig()) { hash = (37 * hash) + MQTT_CONFIG_FIELD_NUMBER; hash = (53 * hash) + getMqttConfig().hashCode(); if (hasHttpConfig()) { hash = (37 * hash) + HTTP_CONFIG_FIELD_NUMBER; hash = (53 * hash) + getHttpConfig().hashCode(); if (getCredentialsCount() > 0) { hash = (37 * hash) + CREDENTIALS_FIELD_NUMBER; hash = (53 * hash) + getCredentialsList().hashCode();
@java.lang.Override public com.google.cloud.iot.v1.DeviceRegistry getDefaultInstanceForType() { return com.google.cloud.iot.v1.DeviceRegistry.getDefaultInstance(); }
@Override public Map<String, String> extract(UpdateDeviceRegistryRequest request) { ImmutableMap.Builder<String, String> params = ImmutableMap.builder(); params.put( "device_registry.name", String.valueOf(request.getDeviceRegistry().getName())); return params.build(); } })
@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.cloud.iot.v1.CreateDeviceRegistryRequest)) { return super.equals(obj); } com.google.cloud.iot.v1.CreateDeviceRegistryRequest other = (com.google.cloud.iot.v1.CreateDeviceRegistryRequest) obj; boolean result = true; result = result && getParent().equals(other.getParent()); result = result && (hasDeviceRegistry() == other.hasDeviceRegistry()); if (hasDeviceRegistry()) { result = result && getDeviceRegistry().equals(other.getDeviceRegistry()); } result = result && unknownFields.equals(other.unknownFields); return result; }
hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + ID_FIELD_NUMBER; hash = (53 * hash) + getId().hashCode(); hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); if (getEventNotificationConfigsCount() > 0) { hash = (37 * hash) + EVENT_NOTIFICATION_CONFIGS_FIELD_NUMBER; hash = (53 * hash) + getEventNotificationConfigsList().hashCode(); if (hasStateNotificationConfig()) { hash = (37 * hash) + STATE_NOTIFICATION_CONFIG_FIELD_NUMBER; hash = (53 * hash) + getStateNotificationConfig().hashCode(); if (hasMqttConfig()) { hash = (37 * hash) + MQTT_CONFIG_FIELD_NUMBER; hash = (53 * hash) + getMqttConfig().hashCode(); if (hasHttpConfig()) { hash = (37 * hash) + HTTP_CONFIG_FIELD_NUMBER; hash = (53 * hash) + getHttpConfig().hashCode(); if (getCredentialsCount() > 0) { hash = (37 * hash) + CREDENTIALS_FIELD_NUMBER; hash = (53 * hash) + getCredentialsList().hashCode();
result = result && getId().equals(other.getId()); result = result && getName().equals(other.getName()); result = result && getEventNotificationConfigsList().equals(other.getEventNotificationConfigsList()); result = result && (hasStateNotificationConfig() == other.hasStateNotificationConfig()); if (hasStateNotificationConfig()) { result = result && getStateNotificationConfig().equals(other.getStateNotificationConfig()); result = result && (hasMqttConfig() == other.hasMqttConfig()); if (hasMqttConfig()) { result = result && getMqttConfig().equals(other.getMqttConfig()); result = result && (hasHttpConfig() == other.hasHttpConfig()); if (hasHttpConfig()) { result = result && getHttpConfig().equals(other.getHttpConfig()); result = result && getCredentialsList().equals(other.getCredentialsList()); result = result && unknownFields.equals(other.unknownFields); return result;
/** * * * <pre> * The device registry. The field `name` must be empty. The server will * generate that field from the device registry `id` provided and the * `parent` field. * </pre> * * <code>.google.cloud.iot.v1.DeviceRegistry device_registry = 2;</code> */ public com.google.cloud.iot.v1.DeviceRegistry getDeviceRegistry() { return deviceRegistry_ == null ? com.google.cloud.iot.v1.DeviceRegistry.getDefaultInstance() : deviceRegistry_; } /**
/** * * * <pre> * The resource path name. For example, * `projects/example-project/locations/us-central1/registries/my-registry`. * </pre> * * <code>string name = 2;</code> */ public Builder clearName() { name_ = getDefaultInstance().getName(); onChanged(); return this; } /**
/** * * * <pre> * The identifier of this device registry. For example, `myRegistry`. * </pre> * * <code>string id = 1;</code> */ public Builder clearId() { id_ = getDefaultInstance().getId(); onChanged(); return this; } /**
@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.cloud.iot.v1.UpdateDeviceRegistryRequest)) { return super.equals(obj); } com.google.cloud.iot.v1.UpdateDeviceRegistryRequest other = (com.google.cloud.iot.v1.UpdateDeviceRegistryRequest) obj; boolean result = true; result = result && (hasDeviceRegistry() == other.hasDeviceRegistry()); if (hasDeviceRegistry()) { result = result && getDeviceRegistry().equals(other.getDeviceRegistry()); } result = result && (hasUpdateMask() == other.hasUpdateMask()); if (hasUpdateMask()) { result = result && getUpdateMask().equals(other.getUpdateMask()); } result = result && unknownFields.equals(other.unknownFields); return result; }
public Builder mergeFrom(com.google.cloud.iot.v1.DeviceRegistry other) { if (other == com.google.cloud.iot.v1.DeviceRegistry.getDefaultInstance()) return this; if (!other.getId().isEmpty()) { id_ = other.id_; onChanged(); if (!other.getName().isEmpty()) { name_ = other.name_; onChanged(); if (other.hasStateNotificationConfig()) { mergeStateNotificationConfig(other.getStateNotificationConfig()); if (other.hasMqttConfig()) { mergeMqttConfig(other.getMqttConfig()); if (other.hasHttpConfig()) { mergeHttpConfig(other.getHttpConfig()); setLogLevelValue(other.getLogLevelValue());
/** * * * <pre> * The new values for the device registry. The `id` field must be empty, and * the `name` field must indicate the path of the resource. For example, * `projects/example-project/locations/us-central1/registries/my-registry`. * </pre> * * <code>.google.cloud.iot.v1.DeviceRegistry device_registry = 1;</code> */ public com.google.cloud.iot.v1.DeviceRegistry getDeviceRegistry() { return deviceRegistry_ == null ? com.google.cloud.iot.v1.DeviceRegistry.getDefaultInstance() : deviceRegistry_; } /**
/** * * * <pre> * The new values for the device registry. The `id` field must be empty, and * the `name` field must indicate the path of the resource. For example, * `projects/example-project/locations/us-central1/registries/my-registry`. * </pre> * * <code>.google.cloud.iot.v1.DeviceRegistry device_registry = 1;</code> */ public Builder mergeDeviceRegistry(com.google.cloud.iot.v1.DeviceRegistry value) { if (deviceRegistryBuilder_ == null) { if (deviceRegistry_ != null) { deviceRegistry_ = com.google.cloud.iot.v1.DeviceRegistry.newBuilder(deviceRegistry_) .mergeFrom(value) .buildPartial(); } else { deviceRegistry_ = value; } onChanged(); } else { deviceRegistryBuilder_.mergeFrom(value); } return this; } /**
@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.cloud.iot.v1.CreateDeviceRegistryRequest)) { return super.equals(obj); } com.google.cloud.iot.v1.CreateDeviceRegistryRequest other = (com.google.cloud.iot.v1.CreateDeviceRegistryRequest) obj; boolean result = true; result = result && getParent().equals(other.getParent()); result = result && (hasDeviceRegistry() == other.hasDeviceRegistry()); if (hasDeviceRegistry()) { result = result && getDeviceRegistry().equals(other.getDeviceRegistry()); } result = result && unknownFields.equals(other.unknownFields); return result; }