mirror of
https://github.com/OpenAPITools/openapi-generator.git
synced 2025-12-08 13:36:11 +00:00
immutable Pair, better performant HttpBearerAuth, consistent code-style (#20743)
* make Pair immutable and in google-code-style * apply google-code-style to JavaTimeFormatter (to make it consistent with most other auto-generated java) * move upperCaseBearer to ctor (scheme is final and private; only needs to be fixed once); also replaced Optional with ternary (perf and cleaner code) * apply google-code-style to Authentication to make it consistent with rest of auth code * fresh samples
This commit is contained in:
@@ -11,43 +11,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
{{>generatedAnnotation}}
|
{{>generatedAnnotation}}
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -4,43 +4,23 @@ package {{invokerPackage}};
|
|||||||
|
|
||||||
{{>generatedAnnotation}}
|
{{>generatedAnnotation}}
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -9,12 +9,12 @@ import java.util.List;
|
|||||||
|
|
||||||
{{>generatedAnnotation}}
|
{{>generatedAnnotation}}
|
||||||
public interface Authentication {
|
public interface Authentication {
|
||||||
/**
|
/**
|
||||||
* Apply authentication settings to header and query params.
|
* Apply authentication settings to header and query params.
|
||||||
*
|
*
|
||||||
* @param queryParams List of query parameters
|
* @param queryParams List of query parameters
|
||||||
* @param headerParams Map of header parameters
|
* @param headerParams Map of header parameters
|
||||||
* @param cookieParams Map of cookie parameters
|
* @param cookieParams Map of cookie parameters
|
||||||
*/
|
*/
|
||||||
void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams);
|
void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -6,7 +6,6 @@ import {{invokerPackage}}.Pair;
|
|||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.Optional;
|
|
||||||
import java.util.function.Supplier;
|
import java.util.function.Supplier;
|
||||||
|
|
||||||
{{>generatedAnnotation}}
|
{{>generatedAnnotation}}
|
||||||
@@ -15,7 +14,7 @@ public class HttpBearerAuth implements Authentication {
|
|||||||
private Supplier<String> tokenSupplier;
|
private Supplier<String> tokenSupplier;
|
||||||
|
|
||||||
public HttpBearerAuth(String scheme) {
|
public HttpBearerAuth(String scheme) {
|
||||||
this.scheme = scheme;
|
this.scheme = upperCaseBearer(scheme);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -47,15 +46,14 @@ public class HttpBearerAuth implements Authentication {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams) {
|
public void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams) {
|
||||||
String bearerToken = Optional.ofNullable(tokenSupplier).map(Supplier::get).orElse(null);
|
String bearerToken = tokenSupplier != null ? tokenSupplier.get() : null;
|
||||||
if (bearerToken == null) {
|
if (bearerToken == null) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
headerParams.put("Authorization", (scheme != null ? scheme + " " : "") + bearerToken);
|
||||||
headerParams.put("Authorization", (scheme != null ? upperCaseBearer(scheme) + " " : "") + bearerToken);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private static String upperCaseBearer(String scheme) {
|
private static String upperCaseBearer(String scheme) {
|
||||||
return ("bearer".equalsIgnoreCase(scheme)) ? "Bearer" : scheme;
|
return "bearer".equalsIgnoreCase(scheme) ? "Bearer" : scheme;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -20,12 +20,12 @@ import java.util.List;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public interface Authentication {
|
public interface Authentication {
|
||||||
/**
|
/**
|
||||||
* Apply authentication settings to header and query params.
|
* Apply authentication settings to header and query params.
|
||||||
*
|
*
|
||||||
* @param queryParams List of query parameters
|
* @param queryParams List of query parameters
|
||||||
* @param headerParams Map of header parameters
|
* @param headerParams Map of header parameters
|
||||||
* @param cookieParams Map of cookie parameters
|
* @param cookieParams Map of cookie parameters
|
||||||
*/
|
*/
|
||||||
void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams);
|
void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -17,7 +17,6 @@ import org.openapitools.client.Pair;
|
|||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.Optional;
|
|
||||||
import java.util.function.Supplier;
|
import java.util.function.Supplier;
|
||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
@@ -26,7 +25,7 @@ public class HttpBearerAuth implements Authentication {
|
|||||||
private Supplier<String> tokenSupplier;
|
private Supplier<String> tokenSupplier;
|
||||||
|
|
||||||
public HttpBearerAuth(String scheme) {
|
public HttpBearerAuth(String scheme) {
|
||||||
this.scheme = scheme;
|
this.scheme = upperCaseBearer(scheme);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -58,15 +57,14 @@ public class HttpBearerAuth implements Authentication {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams) {
|
public void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams) {
|
||||||
String bearerToken = Optional.ofNullable(tokenSupplier).map(Supplier::get).orElse(null);
|
String bearerToken = tokenSupplier != null ? tokenSupplier.get() : null;
|
||||||
if (bearerToken == null) {
|
if (bearerToken == null) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
headerParams.put("Authorization", (scheme != null ? scheme + " " : "") + bearerToken);
|
||||||
headerParams.put("Authorization", (scheme != null ? upperCaseBearer(scheme) + " " : "") + bearerToken);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private static String upperCaseBearer(String scheme) {
|
private static String upperCaseBearer(String scheme) {
|
||||||
return ("bearer".equalsIgnoreCase(scheme)) ? "Bearer" : scheme;
|
return "bearer".equalsIgnoreCase(scheme) ? "Bearer" : scheme;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -20,12 +20,12 @@ import java.util.List;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public interface Authentication {
|
public interface Authentication {
|
||||||
/**
|
/**
|
||||||
* Apply authentication settings to header and query params.
|
* Apply authentication settings to header and query params.
|
||||||
*
|
*
|
||||||
* @param queryParams List of query parameters
|
* @param queryParams List of query parameters
|
||||||
* @param headerParams Map of header parameters
|
* @param headerParams Map of header parameters
|
||||||
* @param cookieParams Map of cookie parameters
|
* @param cookieParams Map of cookie parameters
|
||||||
*/
|
*/
|
||||||
void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams);
|
void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -17,7 +17,6 @@ import org.openapitools.client.Pair;
|
|||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.Optional;
|
|
||||||
import java.util.function.Supplier;
|
import java.util.function.Supplier;
|
||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
@@ -26,7 +25,7 @@ public class HttpBearerAuth implements Authentication {
|
|||||||
private Supplier<String> tokenSupplier;
|
private Supplier<String> tokenSupplier;
|
||||||
|
|
||||||
public HttpBearerAuth(String scheme) {
|
public HttpBearerAuth(String scheme) {
|
||||||
this.scheme = scheme;
|
this.scheme = upperCaseBearer(scheme);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -58,15 +57,14 @@ public class HttpBearerAuth implements Authentication {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams) {
|
public void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams) {
|
||||||
String bearerToken = Optional.ofNullable(tokenSupplier).map(Supplier::get).orElse(null);
|
String bearerToken = tokenSupplier != null ? tokenSupplier.get() : null;
|
||||||
if (bearerToken == null) {
|
if (bearerToken == null) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
headerParams.put("Authorization", (scheme != null ? scheme + " " : "") + bearerToken);
|
||||||
headerParams.put("Authorization", (scheme != null ? upperCaseBearer(scheme) + " " : "") + bearerToken);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private static String upperCaseBearer(String scheme) {
|
private static String upperCaseBearer(String scheme) {
|
||||||
return ("bearer".equalsIgnoreCase(scheme)) ? "Bearer" : scheme;
|
return "bearer".equalsIgnoreCase(scheme) ? "Bearer" : scheme;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -20,12 +20,12 @@ import java.util.List;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public interface Authentication {
|
public interface Authentication {
|
||||||
/**
|
/**
|
||||||
* Apply authentication settings to header and query params.
|
* Apply authentication settings to header and query params.
|
||||||
*
|
*
|
||||||
* @param queryParams List of query parameters
|
* @param queryParams List of query parameters
|
||||||
* @param headerParams Map of header parameters
|
* @param headerParams Map of header parameters
|
||||||
* @param cookieParams Map of cookie parameters
|
* @param cookieParams Map of cookie parameters
|
||||||
*/
|
*/
|
||||||
void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams);
|
void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -17,7 +17,6 @@ import org.openapitools.client.Pair;
|
|||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.Optional;
|
|
||||||
import java.util.function.Supplier;
|
import java.util.function.Supplier;
|
||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
@@ -26,7 +25,7 @@ public class HttpBearerAuth implements Authentication {
|
|||||||
private Supplier<String> tokenSupplier;
|
private Supplier<String> tokenSupplier;
|
||||||
|
|
||||||
public HttpBearerAuth(String scheme) {
|
public HttpBearerAuth(String scheme) {
|
||||||
this.scheme = scheme;
|
this.scheme = upperCaseBearer(scheme);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -58,15 +57,14 @@ public class HttpBearerAuth implements Authentication {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams) {
|
public void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams) {
|
||||||
String bearerToken = Optional.ofNullable(tokenSupplier).map(Supplier::get).orElse(null);
|
String bearerToken = tokenSupplier != null ? tokenSupplier.get() : null;
|
||||||
if (bearerToken == null) {
|
if (bearerToken == null) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
headerParams.put("Authorization", (scheme != null ? scheme + " " : "") + bearerToken);
|
||||||
headerParams.put("Authorization", (scheme != null ? upperCaseBearer(scheme) + " " : "") + bearerToken);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private static String upperCaseBearer(String scheme) {
|
private static String upperCaseBearer(String scheme) {
|
||||||
return ("bearer".equalsIgnoreCase(scheme)) ? "Bearer" : scheme;
|
return "bearer".equalsIgnoreCase(scheme) ? "Bearer" : scheme;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -20,12 +20,12 @@ import java.util.List;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public interface Authentication {
|
public interface Authentication {
|
||||||
/**
|
/**
|
||||||
* Apply authentication settings to header and query params.
|
* Apply authentication settings to header and query params.
|
||||||
*
|
*
|
||||||
* @param queryParams List of query parameters
|
* @param queryParams List of query parameters
|
||||||
* @param headerParams Map of header parameters
|
* @param headerParams Map of header parameters
|
||||||
* @param cookieParams Map of cookie parameters
|
* @param cookieParams Map of cookie parameters
|
||||||
*/
|
*/
|
||||||
void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams);
|
void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -17,7 +17,6 @@ import org.openapitools.client.Pair;
|
|||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.Optional;
|
|
||||||
import java.util.function.Supplier;
|
import java.util.function.Supplier;
|
||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
@@ -26,7 +25,7 @@ public class HttpBearerAuth implements Authentication {
|
|||||||
private Supplier<String> tokenSupplier;
|
private Supplier<String> tokenSupplier;
|
||||||
|
|
||||||
public HttpBearerAuth(String scheme) {
|
public HttpBearerAuth(String scheme) {
|
||||||
this.scheme = scheme;
|
this.scheme = upperCaseBearer(scheme);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -58,15 +57,14 @@ public class HttpBearerAuth implements Authentication {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams) {
|
public void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams) {
|
||||||
String bearerToken = Optional.ofNullable(tokenSupplier).map(Supplier::get).orElse(null);
|
String bearerToken = tokenSupplier != null ? tokenSupplier.get() : null;
|
||||||
if (bearerToken == null) {
|
if (bearerToken == null) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
headerParams.put("Authorization", (scheme != null ? scheme + " " : "") + bearerToken);
|
||||||
headerParams.put("Authorization", (scheme != null ? upperCaseBearer(scheme) + " " : "") + bearerToken);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private static String upperCaseBearer(String scheme) {
|
private static String upperCaseBearer(String scheme) {
|
||||||
return ("bearer".equalsIgnoreCase(scheme)) ? "Bearer" : scheme;
|
return "bearer".equalsIgnoreCase(scheme) ? "Bearer" : scheme;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -20,12 +20,12 @@ import java.util.List;
|
|||||||
|
|
||||||
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public interface Authentication {
|
public interface Authentication {
|
||||||
/**
|
/**
|
||||||
* Apply authentication settings to header and query params.
|
* Apply authentication settings to header and query params.
|
||||||
*
|
*
|
||||||
* @param queryParams List of query parameters
|
* @param queryParams List of query parameters
|
||||||
* @param headerParams Map of header parameters
|
* @param headerParams Map of header parameters
|
||||||
* @param cookieParams Map of cookie parameters
|
* @param cookieParams Map of cookie parameters
|
||||||
*/
|
*/
|
||||||
void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams);
|
void applyToParams(List<Pair> queryParams, Map<String, String> headerParams, Map<String, String> cookieParams);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,43 +22,47 @@ import java.time.format.DateTimeParseException;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class JavaTimeFormatter {
|
public class JavaTimeFormatter {
|
||||||
|
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
||||||
|
|
||||||
private DateTimeFormatter offsetDateTimeFormatter = DateTimeFormatter.ISO_OFFSET_DATE_TIME;
|
/**
|
||||||
|
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
|
*
|
||||||
|
* @return DateTimeFormatter
|
||||||
|
*/
|
||||||
|
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
||||||
|
return offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
||||||
* @return DateTimeFormatter
|
*
|
||||||
*/
|
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
||||||
public DateTimeFormatter getOffsetDateTimeFormatter() {
|
*/
|
||||||
return offsetDateTimeFormatter;
|
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
||||||
}
|
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the date format used to parse/format {@code OffsetDateTime} parameters.
|
* Parse the given string into {@code OffsetDateTime} object.
|
||||||
* @param offsetDateTimeFormatter {@code DateTimeFormatter}
|
*
|
||||||
*/
|
* @param str String
|
||||||
public void setOffsetDateTimeFormatter(DateTimeFormatter offsetDateTimeFormatter) {
|
* @return {@code OffsetDateTime}
|
||||||
this.offsetDateTimeFormatter = offsetDateTimeFormatter;
|
*/
|
||||||
|
public OffsetDateTime parseOffsetDateTime(String str) {
|
||||||
|
try {
|
||||||
|
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
||||||
|
} catch (DateTimeParseException e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the given string into {@code OffsetDateTime} object.
|
* Format the given {@code OffsetDateTime} object into string.
|
||||||
* @param str String
|
*
|
||||||
* @return {@code OffsetDateTime}
|
* @param offsetDateTime {@code OffsetDateTime}
|
||||||
*/
|
* @return {@code OffsetDateTime} in string format
|
||||||
public OffsetDateTime parseOffsetDateTime(String str) {
|
*/
|
||||||
try {
|
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
||||||
return OffsetDateTime.parse(str, offsetDateTimeFormatter);
|
return offsetDateTimeFormatter.format(offsetDateTime);
|
||||||
} catch (DateTimeParseException e) {
|
}
|
||||||
throw new RuntimeException(e);
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Format the given {@code OffsetDateTime} object into string.
|
|
||||||
* @param offsetDateTime {@code OffsetDateTime}
|
|
||||||
* @return {@code OffsetDateTime} in string format
|
|
||||||
*/
|
|
||||||
public String formatOffsetDateTime(OffsetDateTime offsetDateTime) {
|
|
||||||
return offsetDateTimeFormatter.format(offsetDateTime);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -15,43 +15,23 @@ package org.openapitools.client;
|
|||||||
|
|
||||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0-SNAPSHOT")
|
||||||
public class Pair {
|
public class Pair {
|
||||||
private String name = "";
|
private final String name;
|
||||||
private String value = "";
|
private final String value;
|
||||||
|
|
||||||
public Pair (String name, String value) {
|
public Pair(String name, String value) {
|
||||||
setName(name);
|
this.name = isValidString(name) ? name : "";
|
||||||
setValue(value);
|
this.value = isValidString(value) ? value : "";
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setName(String name) {
|
public String getName() {
|
||||||
if (!isValidString(name)) {
|
return this.name;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.name = name;
|
public String getValue() {
|
||||||
}
|
return this.value;
|
||||||
|
}
|
||||||
|
|
||||||
private void setValue(String value) {
|
private static boolean isValidString(String arg) {
|
||||||
if (!isValidString(value)) {
|
return arg != null;
|
||||||
return;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getName() {
|
|
||||||
return this.name;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getValue() {
|
|
||||||
return this.value;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean isValidString(String arg) {
|
|
||||||
if (arg == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user