Skip to content

Commit

Permalink
Regenerate compute client (#4527)
Browse files Browse the repository at this point in the history
  • Loading branch information
yoshi-automation authored and sduskis committed Feb 21, 2019
1 parent 9e56353 commit 19bafcd
Show file tree
Hide file tree
Showing 12 changed files with 284 additions and 101 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -158,10 +158,7 @@ public String getFields() {
return fields;
}

/**
* Whether to force attach the disk even if it's currently attached to another instance. This is
* only available for regional disks.
*/
/** Whether to force attach the disk even if it's currently attached to another instance. */
public Boolean getForceAttach() {
return forceAttach;
}
Expand Down Expand Up @@ -348,18 +345,12 @@ public Builder setFields(String fields) {
return this;
}

/**
* Whether to force attach the disk even if it's currently attached to another instance. This is
* only available for regional disks.
*/
/** Whether to force attach the disk even if it's currently attached to another instance. */
public Boolean getForceAttach() {
return forceAttach;
}

/**
* Whether to force attach the disk even if it's currently attached to another instance. This is
* only available for regional disks.
*/
/** Whether to force attach the disk even if it's currently attached to another instance. */
public Builder setForceAttach(Boolean forceAttach) {
this.forceAttach = forceAttach;
return this;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,25 +31,21 @@ public final class Condition implements ApiMessage {
private final String op;
private final String svc;
private final String sys;
private final String value;
private final List<String> values;

private Condition() {
this.iam = null;
this.op = null;
this.svc = null;
this.sys = null;
this.value = null;
this.values = null;
}

private Condition(
String iam, String op, String svc, String sys, String value, List<String> values) {
private Condition(String iam, String op, String svc, String sys, List<String> values) {
this.iam = iam;
this.op = op;
this.svc = svc;
this.sys = sys;
this.value = value;
this.values = values;
}

Expand All @@ -67,9 +63,6 @@ public Object getFieldValue(String fieldName) {
if ("sys".equals(fieldName)) {
return sys;
}
if ("value".equals(fieldName)) {
return value;
}
if ("values".equals(fieldName)) {
return values;
}
Expand Down Expand Up @@ -117,12 +110,7 @@ public String getSys() {
return sys;
}

/** DEPRECATED. Use 'values' instead. */
public String getValue() {
return value;
}

/** The objects of the condition. This is mutually exclusive with 'value'. */
/** The objects of the condition. */
public List<String> getValuesList() {
return values;
}
Expand Down Expand Up @@ -154,7 +142,6 @@ public static class Builder {
private String op;
private String svc;
private String sys;
private String value;
private List<String> values;

Builder() {}
Expand All @@ -173,9 +160,6 @@ public Builder mergeFrom(Condition other) {
if (other.getSys() != null) {
this.sys = other.sys;
}
if (other.getValue() != null) {
this.value = other.value;
}
if (other.getValuesList() != null) {
this.values = other.values;
}
Expand All @@ -187,7 +171,6 @@ public Builder mergeFrom(Condition other) {
this.op = source.op;
this.svc = source.svc;
this.sys = source.sys;
this.value = source.value;
this.values = source.values;
}

Expand Down Expand Up @@ -241,23 +224,12 @@ public Builder setSys(String sys) {
return this;
}

/** DEPRECATED. Use 'values' instead. */
public String getValue() {
return value;
}

/** DEPRECATED. Use 'values' instead. */
public Builder setValue(String value) {
this.value = value;
return this;
}

/** The objects of the condition. This is mutually exclusive with 'value'. */
/** The objects of the condition. */
public List<String> getValuesList() {
return values;
}

/** The objects of the condition. This is mutually exclusive with 'value'. */
/** The objects of the condition. */
public Builder addAllValues(List<String> values) {
if (this.values == null) {
this.values = new LinkedList<>();
Expand All @@ -266,7 +238,7 @@ public Builder addAllValues(List<String> values) {
return this;
}

/** The objects of the condition. This is mutually exclusive with 'value'. */
/** The objects of the condition. */
public Builder addValues(String values) {
if (this.values == null) {
this.values = new LinkedList<>();
Expand All @@ -277,7 +249,7 @@ public Builder addValues(String values) {

public Condition build() {

return new Condition(iam, op, svc, sys, value, values);
return new Condition(iam, op, svc, sys, values);
}

public Builder clone() {
Expand All @@ -286,7 +258,6 @@ public Builder clone() {
newBuilder.setOp(this.op);
newBuilder.setSvc(this.svc);
newBuilder.setSys(this.sys);
newBuilder.setValue(this.value);
newBuilder.addAllValues(this.values);
return newBuilder;
}
Expand All @@ -307,9 +278,6 @@ public String toString() {
+ "sys="
+ sys
+ ", "
+ "value="
+ value
+ ", "
+ "values="
+ values
+ "}";
Expand All @@ -326,14 +294,13 @@ public boolean equals(Object o) {
&& Objects.equals(this.op, that.getOp())
&& Objects.equals(this.svc, that.getSvc())
&& Objects.equals(this.sys, that.getSys())
&& Objects.equals(this.value, that.getValue())
&& Objects.equals(this.values, that.getValuesList());
}
return false;
}

@Override
public int hashCode() {
return Objects.hash(iam, op, svc, sys, value, values);
return Objects.hash(iam, op, svc, sys, values);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
* beta.regionForwardingRules ==) (== resource_for v1.regionForwardingRules ==)
*/
public final class ForwardingRule implements ApiMessage {
private final Boolean allPorts;
private final String backendService;
private final String creationTimestamp;
private final String description;
Expand Down Expand Up @@ -61,6 +62,7 @@ public final class ForwardingRule implements ApiMessage {
private final String target;

private ForwardingRule() {
this.allPorts = null;
this.backendService = null;
this.creationTimestamp = null;
this.description = null;
Expand All @@ -84,6 +86,7 @@ private ForwardingRule() {
}

private ForwardingRule(
Boolean allPorts,
String backendService,
String creationTimestamp,
String description,
Expand All @@ -104,6 +107,7 @@ private ForwardingRule(
String serviceName,
String subnetwork,
String target) {
this.allPorts = allPorts;
this.backendService = backendService;
this.creationTimestamp = creationTimestamp;
this.description = description;
Expand All @@ -128,6 +132,9 @@ private ForwardingRule(

@Override
public Object getFieldValue(String fieldName) {
if ("allPorts".equals(fieldName)) {
return allPorts;
}
if ("backendService".equals(fieldName)) {
return backendService;
}
Expand Down Expand Up @@ -209,6 +216,19 @@ public List<String> getFieldMask() {
return null;
}

/**
* This field is used along with the backend_service field for internal load balancing or with the
* target field for internal TargetInstance. This field cannot be used with port or portRange
* fields.
*
* <p>When the load balancing scheme is INTERNAL and protocol is TCP/UDP, specify this field to
* allow packets addressed to any ports will be forwarded to the backends configured with this
* forwarding rule.
*/
public Boolean getAllPorts() {
return allPorts;
}

/**
* This field is only used for INTERNAL load balancing.
*
Expand Down Expand Up @@ -427,8 +447,8 @@ public String getSubnetwork() {
* The URL of the target resource to receive the matched traffic. For regional forwarding rules,
* this target must live in the same region as the forwarding rule. For global forwarding rules,
* this target must be a global load balancing resource. The forwarded traffic must be of a type
* appropriate to the target object. For INTERNAL_SELF_MANAGED" load balancing, only HTTP and
* HTTPS targets are valid.
* appropriate to the target object. For INTERNAL_SELF_MANAGED load balancing, only HTTP and HTTPS
* targets are valid.
*/
public String getTarget() {
return target;
Expand Down Expand Up @@ -457,6 +477,7 @@ public static ForwardingRule getDefaultInstance() {
}

public static class Builder {
private Boolean allPorts;
private String backendService;
private String creationTimestamp;
private String description;
Expand All @@ -482,6 +503,9 @@ public static class Builder {

public Builder mergeFrom(ForwardingRule other) {
if (other == ForwardingRule.getDefaultInstance()) return this;
if (other.getAllPorts() != null) {
this.allPorts = other.allPorts;
}
if (other.getBackendService() != null) {
this.backendService = other.backendService;
}
Expand Down Expand Up @@ -546,6 +570,7 @@ public Builder mergeFrom(ForwardingRule other) {
}

Builder(ForwardingRule source) {
this.allPorts = source.allPorts;
this.backendService = source.backendService;
this.creationTimestamp = source.creationTimestamp;
this.description = source.description;
Expand All @@ -568,6 +593,33 @@ public Builder mergeFrom(ForwardingRule other) {
this.target = source.target;
}

/**
* This field is used along with the backend_service field for internal load balancing or with
* the target field for internal TargetInstance. This field cannot be used with port or
* portRange fields.
*
* <p>When the load balancing scheme is INTERNAL and protocol is TCP/UDP, specify this field to
* allow packets addressed to any ports will be forwarded to the backends configured with this
* forwarding rule.
*/
public Boolean getAllPorts() {
return allPorts;
}

/**
* This field is used along with the backend_service field for internal load balancing or with
* the target field for internal TargetInstance. This field cannot be used with port or
* portRange fields.
*
* <p>When the load balancing scheme is INTERNAL and protocol is TCP/UDP, specify this field to
* allow packets addressed to any ports will be forwarded to the backends configured with this
* forwarding rule.
*/
public Builder setAllPorts(Boolean allPorts) {
this.allPorts = allPorts;
return this;
}

/**
* This field is only used for INTERNAL load balancing.
*
Expand Down Expand Up @@ -1045,7 +1097,7 @@ public Builder setSubnetwork(String subnetwork) {
* The URL of the target resource to receive the matched traffic. For regional forwarding rules,
* this target must live in the same region as the forwarding rule. For global forwarding rules,
* this target must be a global load balancing resource. The forwarded traffic must be of a type
* appropriate to the target object. For INTERNAL_SELF_MANAGED" load balancing, only HTTP and
* appropriate to the target object. For INTERNAL_SELF_MANAGED load balancing, only HTTP and
* HTTPS targets are valid.
*/
public String getTarget() {
Expand All @@ -1056,7 +1108,7 @@ public String getTarget() {
* The URL of the target resource to receive the matched traffic. For regional forwarding rules,
* this target must live in the same region as the forwarding rule. For global forwarding rules,
* this target must be a global load balancing resource. The forwarded traffic must be of a type
* appropriate to the target object. For INTERNAL_SELF_MANAGED" load balancing, only HTTP and
* appropriate to the target object. For INTERNAL_SELF_MANAGED load balancing, only HTTP and
* HTTPS targets are valid.
*/
public Builder setTarget(String target) {
Expand All @@ -1067,6 +1119,7 @@ public Builder setTarget(String target) {
public ForwardingRule build() {

return new ForwardingRule(
allPorts,
backendService,
creationTimestamp,
description,
Expand All @@ -1091,6 +1144,7 @@ public ForwardingRule build() {

public Builder clone() {
Builder newBuilder = new Builder();
newBuilder.setAllPorts(this.allPorts);
newBuilder.setBackendService(this.backendService);
newBuilder.setCreationTimestamp(this.creationTimestamp);
newBuilder.setDescription(this.description);
Expand Down Expand Up @@ -1118,6 +1172,9 @@ public Builder clone() {
@Override
public String toString() {
return "ForwardingRule{"
+ "allPorts="
+ allPorts
+ ", "
+ "backendService="
+ backendService
+ ", "
Expand Down Expand Up @@ -1187,7 +1244,8 @@ public boolean equals(Object o) {
}
if (o instanceof ForwardingRule) {
ForwardingRule that = (ForwardingRule) o;
return Objects.equals(this.backendService, that.getBackendService())
return Objects.equals(this.allPorts, that.getAllPorts())
&& Objects.equals(this.backendService, that.getBackendService())
&& Objects.equals(this.creationTimestamp, that.getCreationTimestamp())
&& Objects.equals(this.description, that.getDescription())
&& Objects.equals(this.iPAddress, that.getIPAddress())
Expand All @@ -1214,6 +1272,7 @@ public boolean equals(Object o) {
@Override
public int hashCode() {
return Objects.hash(
allPorts,
backendService,
creationTimestamp,
description,
Expand Down
Loading

0 comments on commit 19bafcd

Please sign in to comment.