jp.co.freee.accounting.models.ApprovalRequestResponseApprovalRequestRequestItems Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of freee-accounting-sdk Show documentation
Show all versions of freee-accounting-sdk Show documentation
freee accounting client SDK for Java
/*
* freee API
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: v1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
package jp.co.freee.accounting.models;
import java.util.Objects;
import java.util.Arrays;
import com.google.gson.TypeAdapter;
import com.google.gson.annotations.JsonAdapter;
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.io.IOException;
/**
* ApprovalRequestResponseApprovalRequestRequestItems
*/
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class ApprovalRequestResponseApprovalRequestRequestItems {
public static final String SERIALIZED_NAME_ID = "id";
@SerializedName(SERIALIZED_NAME_ID)
private Integer id;
/**
* 項目タイプ(title: 申請タイトル, single_line: 自由記述形式 1行, multi_line: 自由記述形式 複数行, select: プルダウン, date: 日付, amount: 金額, receipt: 添付ファイル, section: 部門ID, partner: 取引先ID, ninja_sign_document: 契約書(freeeサイン連携))
*/
@JsonAdapter(TypeEnum.Adapter.class)
public enum TypeEnum {
TITLE("title"),
SINGLE_LINE("single_line"),
MULTI_LINE("multi_line"),
SELECT("select"),
DATE("date"),
AMOUNT("amount"),
RECEIPT("receipt"),
SECTION("section"),
PARTNER("partner"),
NINJA_SIGN_DOCUMENT("ninja_sign_document");
private String value;
TypeEnum(String value) {
this.value = value;
}
public String getValue() {
return value;
}
@Override
public String toString() {
return String.valueOf(value);
}
public static TypeEnum fromValue(String value) {
for (TypeEnum b : TypeEnum.values()) {
if (b.value.equals(value)) {
return b;
}
}
throw new IllegalArgumentException("Unexpected value '" + value + "'");
}
public static class Adapter extends TypeAdapter {
@Override
public void write(final JsonWriter jsonWriter, final TypeEnum enumeration) throws IOException {
jsonWriter.value(enumeration.getValue());
}
@Override
public TypeEnum read(final JsonReader jsonReader) throws IOException {
String value = jsonReader.nextString();
return TypeEnum.fromValue(value);
}
}
}
public static final String SERIALIZED_NAME_TYPE = "type";
@SerializedName(SERIALIZED_NAME_TYPE)
private TypeEnum type;
public static final String SERIALIZED_NAME_VALUE = "value";
@SerializedName(SERIALIZED_NAME_VALUE)
private String value;
public ApprovalRequestResponseApprovalRequestRequestItems() {
}
public ApprovalRequestResponseApprovalRequestRequestItems id(Integer id) {
this.id = id;
return this;
}
/**
* 項目ID
* minimum: 1
* maximum: 2147483647
* @return id
**/
@javax.annotation.Nonnull
@ApiModelProperty(example = "1", required = true, value = "項目ID")
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
public ApprovalRequestResponseApprovalRequestRequestItems type(TypeEnum type) {
this.type = type;
return this;
}
/**
* 項目タイプ(title: 申請タイトル, single_line: 自由記述形式 1行, multi_line: 自由記述形式 複数行, select: プルダウン, date: 日付, amount: 金額, receipt: 添付ファイル, section: 部門ID, partner: 取引先ID, ninja_sign_document: 契約書(freeeサイン連携))
* @return type
**/
@javax.annotation.Nonnull
@ApiModelProperty(example = "single_line", required = true, value = "項目タイプ(title: 申請タイトル, single_line: 自由記述形式 1行, multi_line: 自由記述形式 複数行, select: プルダウン, date: 日付, amount: 金額, receipt: 添付ファイル, section: 部門ID, partner: 取引先ID, ninja_sign_document: 契約書(freeeサイン連携))")
public TypeEnum getType() {
return type;
}
public void setType(TypeEnum type) {
this.type = type;
}
public ApprovalRequestResponseApprovalRequestRequestItems value(String value) {
this.value = value;
return this;
}
/**
* 項目の値
* @return value
**/
@javax.annotation.Nonnull
@ApiModelProperty(example = "取引先への営業のため", required = true, value = "項目の値")
public String getValue() {
return value;
}
public void setValue(String value) {
this.value = value;
}
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
ApprovalRequestResponseApprovalRequestRequestItems approvalRequestResponseApprovalRequestRequestItems = (ApprovalRequestResponseApprovalRequestRequestItems) o;
return Objects.equals(this.id, approvalRequestResponseApprovalRequestRequestItems.id) &&
Objects.equals(this.type, approvalRequestResponseApprovalRequestRequestItems.type) &&
Objects.equals(this.value, approvalRequestResponseApprovalRequestRequestItems.value);
}
@Override
public int hashCode() {
return Objects.hash(id, type, value);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class ApprovalRequestResponseApprovalRequestRequestItems {\n");
sb.append(" id: ").append(toIndentedString(id)).append("\n");
sb.append(" type: ").append(toIndentedString(type)).append("\n");
sb.append(" value: ").append(toIndentedString(value)).append("\n");
sb.append("}");
return sb.toString();
}
/**
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
}
}