Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 3 additions & 27 deletions reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -2822,15 +2822,7 @@ client.reactors().create(
<dl>
<dd>

**runtime:** `Optional<String>`

</dd>
</dl>

<dl>
<dd>

**options:** `Optional<RuntimeOptions>`
**runtime:** `Optional<Runtime>`

</dd>
</dl>
Expand Down Expand Up @@ -2957,15 +2949,7 @@ client.reactors().update(
<dl>
<dd>

**runtime:** `Optional<String>`

</dd>
</dl>

<dl>
<dd>

**options:** `Optional<RuntimeOptions>`
**runtime:** `Optional<Runtime>`

</dd>
</dl>
Expand Down Expand Up @@ -3090,15 +3074,7 @@ client.reactors().patch(
<dl>
<dd>

**runtime:** `Optional<String>`

</dd>
</dl>

<dl>
<dd>

**options:** `Optional<RuntimeOptions>`
**runtime:** `Optional<Runtime>`

</dd>
</dl>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

import com.basistheory.core.ObjectMappers;
import com.basistheory.types.Application;
import com.basistheory.types.RuntimeOptions;
import com.basistheory.types.Runtime;
import com.fasterxml.jackson.annotation.JsonAnyGetter;
import com.fasterxml.jackson.annotation.JsonAnySetter;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
Expand All @@ -31,9 +31,7 @@ public final class CreateReactorRequest {

private final Optional<Map<String, Optional<String>>> configuration;

private final Optional<String> runtime;

private final Optional<RuntimeOptions> options;
private final Optional<Runtime> runtime;

private final Map<String, Object> additionalProperties;

Expand All @@ -42,15 +40,13 @@ private CreateReactorRequest(
String code,
Optional<Application> application,
Optional<Map<String, Optional<String>>> configuration,
Optional<String> runtime,
Optional<RuntimeOptions> options,
Optional<Runtime> runtime,
Map<String, Object> additionalProperties) {
this.name = name;
this.code = code;
this.application = application;
this.configuration = configuration;
this.runtime = runtime;
this.options = options;
this.additionalProperties = additionalProperties;
}

Expand All @@ -75,15 +71,10 @@ public Optional<Map<String, Optional<String>>> getConfiguration() {
}

@JsonProperty("runtime")
public Optional<String> getRuntime() {
public Optional<Runtime> getRuntime() {
return runtime;
}

@JsonProperty("options")
public Optional<RuntimeOptions> getOptions() {
return options;
}

@java.lang.Override
public boolean equals(Object other) {
if (this == other) return true;
Expand All @@ -100,13 +91,12 @@ private boolean equalTo(CreateReactorRequest other) {
&& code.equals(other.code)
&& application.equals(other.application)
&& configuration.equals(other.configuration)
&& runtime.equals(other.runtime)
&& options.equals(other.options);
&& runtime.equals(other.runtime);
}

@java.lang.Override
public int hashCode() {
return Objects.hash(this.name, this.code, this.application, this.configuration, this.runtime, this.options);
return Objects.hash(this.name, this.code, this.application, this.configuration, this.runtime);
}

@java.lang.Override
Expand Down Expand Up @@ -139,13 +129,9 @@ public interface _FinalStage {

_FinalStage configuration(Map<String, Optional<String>> configuration);

_FinalStage runtime(Optional<String> runtime);

_FinalStage runtime(String runtime);
_FinalStage runtime(Optional<Runtime> runtime);

_FinalStage options(Optional<RuntimeOptions> options);

_FinalStage options(RuntimeOptions options);
_FinalStage runtime(Runtime runtime);
}

@JsonIgnoreProperties(ignoreUnknown = true)
Expand All @@ -154,9 +140,7 @@ public static final class Builder implements NameStage, CodeStage, _FinalStage {

private String code;

private Optional<RuntimeOptions> options = Optional.empty();

private Optional<String> runtime = Optional.empty();
private Optional<Runtime> runtime = Optional.empty();

private Optional<Map<String, Optional<String>>> configuration = Optional.empty();

Expand All @@ -174,7 +158,6 @@ public Builder from(CreateReactorRequest other) {
application(other.getApplication());
configuration(other.getConfiguration());
runtime(other.getRuntime());
options(other.getOptions());
return this;
}

Expand All @@ -193,27 +176,14 @@ public _FinalStage code(@NotNull String code) {
}

@java.lang.Override
public _FinalStage options(RuntimeOptions options) {
this.options = Optional.ofNullable(options);
return this;
}

@java.lang.Override
@JsonSetter(value = "options", nulls = Nulls.SKIP)
public _FinalStage options(Optional<RuntimeOptions> options) {
this.options = options;
return this;
}

@java.lang.Override
public _FinalStage runtime(String runtime) {
public _FinalStage runtime(Runtime runtime) {
this.runtime = Optional.ofNullable(runtime);
return this;
}

@java.lang.Override
@JsonSetter(value = "runtime", nulls = Nulls.SKIP)
public _FinalStage runtime(Optional<String> runtime) {
public _FinalStage runtime(Optional<Runtime> runtime) {
this.runtime = runtime;
return this;
}
Expand Down Expand Up @@ -246,8 +216,7 @@ public _FinalStage application(Optional<Application> application) {

@java.lang.Override
public CreateReactorRequest build() {
return new CreateReactorRequest(
name, code, application, configuration, runtime, options, additionalProperties);
return new CreateReactorRequest(name, code, application, configuration, runtime, additionalProperties);
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

import com.basistheory.core.ObjectMappers;
import com.basistheory.types.Application;
import com.basistheory.types.RuntimeOptions;
import com.basistheory.types.Runtime;
import com.fasterxml.jackson.annotation.JsonAnyGetter;
import com.fasterxml.jackson.annotation.JsonAnySetter;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
Expand All @@ -30,9 +30,7 @@ public final class PatchReactorRequest {

private final Optional<Map<String, Optional<String>>> configuration;

private final Optional<String> runtime;

private final Optional<RuntimeOptions> options;
private final Optional<Runtime> runtime;

private final Map<String, Object> additionalProperties;

Expand All @@ -41,15 +39,13 @@ private PatchReactorRequest(
Optional<Application> application,
Optional<String> code,
Optional<Map<String, Optional<String>>> configuration,
Optional<String> runtime,
Optional<RuntimeOptions> options,
Optional<Runtime> runtime,
Map<String, Object> additionalProperties) {
this.name = name;
this.application = application;
this.code = code;
this.configuration = configuration;
this.runtime = runtime;
this.options = options;
this.additionalProperties = additionalProperties;
}

Expand All @@ -74,15 +70,10 @@ public Optional<Map<String, Optional<String>>> getConfiguration() {
}

@JsonProperty("runtime")
public Optional<String> getRuntime() {
public Optional<Runtime> getRuntime() {
return runtime;
}

@JsonProperty("options")
public Optional<RuntimeOptions> getOptions() {
return options;
}

@java.lang.Override
public boolean equals(Object other) {
if (this == other) return true;
Expand All @@ -99,13 +90,12 @@ private boolean equalTo(PatchReactorRequest other) {
&& application.equals(other.application)
&& code.equals(other.code)
&& configuration.equals(other.configuration)
&& runtime.equals(other.runtime)
&& options.equals(other.options);
&& runtime.equals(other.runtime);
}

@java.lang.Override
public int hashCode() {
return Objects.hash(this.name, this.application, this.code, this.configuration, this.runtime, this.options);
return Objects.hash(this.name, this.application, this.code, this.configuration, this.runtime);
}

@java.lang.Override
Expand All @@ -127,9 +117,7 @@ public static final class Builder {

private Optional<Map<String, Optional<String>>> configuration = Optional.empty();

private Optional<String> runtime = Optional.empty();

private Optional<RuntimeOptions> options = Optional.empty();
private Optional<Runtime> runtime = Optional.empty();

@JsonAnySetter
private Map<String, Object> additionalProperties = new HashMap<>();
Expand All @@ -142,7 +130,6 @@ public Builder from(PatchReactorRequest other) {
code(other.getCode());
configuration(other.getConfiguration());
runtime(other.getRuntime());
options(other.getOptions());
return this;
}

Expand Down Expand Up @@ -191,30 +178,18 @@ public Builder configuration(Map<String, Optional<String>> configuration) {
}

@JsonSetter(value = "runtime", nulls = Nulls.SKIP)
public Builder runtime(Optional<String> runtime) {
public Builder runtime(Optional<Runtime> runtime) {
this.runtime = runtime;
return this;
}

public Builder runtime(String runtime) {
public Builder runtime(Runtime runtime) {
this.runtime = Optional.ofNullable(runtime);
return this;
}

@JsonSetter(value = "options", nulls = Nulls.SKIP)
public Builder options(Optional<RuntimeOptions> options) {
this.options = options;
return this;
}

public Builder options(RuntimeOptions options) {
this.options = Optional.ofNullable(options);
return this;
}

public PatchReactorRequest build() {
return new PatchReactorRequest(
name, application, code, configuration, runtime, options, additionalProperties);
return new PatchReactorRequest(name, application, code, configuration, runtime, additionalProperties);
}
}
}
Loading