jp.co.freee.accounting.models.QuotationIndexResponseQuotationContents 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;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.List;
import org.openapitools.jackson.nullable.JsonNullable;
/**
* QuotationIndexResponseQuotationContents
*/
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class QuotationIndexResponseQuotationContents {
public static final String SERIALIZED_NAME_ACCOUNT_ITEM_ID = "account_item_id";
@SerializedName(SERIALIZED_NAME_ACCOUNT_ITEM_ID)
private Integer accountItemId;
public static final String SERIALIZED_NAME_ACCOUNT_ITEM_NAME = "account_item_name";
@SerializedName(SERIALIZED_NAME_ACCOUNT_ITEM_NAME)
private String accountItemName;
public static final String SERIALIZED_NAME_AMOUNT = "amount";
@SerializedName(SERIALIZED_NAME_AMOUNT)
private Integer amount;
public static final String SERIALIZED_NAME_DESCRIPTION = "description";
@SerializedName(SERIALIZED_NAME_DESCRIPTION)
private String description;
public static final String SERIALIZED_NAME_ID = "id";
@SerializedName(SERIALIZED_NAME_ID)
private Integer id;
public static final String SERIALIZED_NAME_ITEM_ID = "item_id";
@SerializedName(SERIALIZED_NAME_ITEM_ID)
private Integer itemId;
public static final String SERIALIZED_NAME_ITEM_NAME = "item_name";
@SerializedName(SERIALIZED_NAME_ITEM_NAME)
private String itemName;
public static final String SERIALIZED_NAME_ORDER = "order";
@SerializedName(SERIALIZED_NAME_ORDER)
private Integer order;
public static final String SERIALIZED_NAME_QTY = "qty";
@SerializedName(SERIALIZED_NAME_QTY)
private BigDecimal qty;
public static final String SERIALIZED_NAME_REDUCED_VAT = "reduced_vat";
@SerializedName(SERIALIZED_NAME_REDUCED_VAT)
private Boolean reducedVat;
public static final String SERIALIZED_NAME_SECTION_ID = "section_id";
@SerializedName(SERIALIZED_NAME_SECTION_ID)
private Integer sectionId;
public static final String SERIALIZED_NAME_SECTION_NAME = "section_name";
@SerializedName(SERIALIZED_NAME_SECTION_NAME)
private String sectionName;
public static final String SERIALIZED_NAME_SEGMENT1_TAG_ID = "segment_1_tag_id";
@SerializedName(SERIALIZED_NAME_SEGMENT1_TAG_ID)
private Long segment1TagId;
public static final String SERIALIZED_NAME_SEGMENT1_TAG_NAME = "segment_1_tag_name";
@SerializedName(SERIALIZED_NAME_SEGMENT1_TAG_NAME)
private String segment1TagName;
public static final String SERIALIZED_NAME_SEGMENT2_TAG_ID = "segment_2_tag_id";
@SerializedName(SERIALIZED_NAME_SEGMENT2_TAG_ID)
private Long segment2TagId;
public static final String SERIALIZED_NAME_SEGMENT2_TAG_NAME = "segment_2_tag_name";
@SerializedName(SERIALIZED_NAME_SEGMENT2_TAG_NAME)
private String segment2TagName;
public static final String SERIALIZED_NAME_SEGMENT3_TAG_ID = "segment_3_tag_id";
@SerializedName(SERIALIZED_NAME_SEGMENT3_TAG_ID)
private Long segment3TagId;
public static final String SERIALIZED_NAME_SEGMENT3_TAG_NAME = "segment_3_tag_name";
@SerializedName(SERIALIZED_NAME_SEGMENT3_TAG_NAME)
private String segment3TagName;
public static final String SERIALIZED_NAME_TAG_IDS = "tag_ids";
@SerializedName(SERIALIZED_NAME_TAG_IDS)
private List tagIds = new ArrayList<>();
public static final String SERIALIZED_NAME_TAG_NAMES = "tag_names";
@SerializedName(SERIALIZED_NAME_TAG_NAMES)
private List tagNames = new ArrayList<>();
public static final String SERIALIZED_NAME_TAX_CODE = "tax_code";
@SerializedName(SERIALIZED_NAME_TAX_CODE)
private Integer taxCode;
/**
* 行の種類
*/
@JsonAdapter(TypeEnum.Adapter.class)
public enum TypeEnum {
NORMAL("normal"),
DISCOUNT("discount"),
TEXT("text");
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_UNIT = "unit";
@SerializedName(SERIALIZED_NAME_UNIT)
private String unit;
public static final String SERIALIZED_NAME_UNIT_PRICE = "unit_price";
@SerializedName(SERIALIZED_NAME_UNIT_PRICE)
private BigDecimal unitPrice;
public static final String SERIALIZED_NAME_VAT = "vat";
@SerializedName(SERIALIZED_NAME_VAT)
private Integer vat;
public QuotationIndexResponseQuotationContents() {
}
public QuotationIndexResponseQuotationContents accountItemId(Integer accountItemId) {
this.accountItemId = accountItemId;
return this;
}
/**
* 勘定科目ID
* @return accountItemId
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "1", required = true, value = "勘定科目ID")
public Integer getAccountItemId() {
return accountItemId;
}
public void setAccountItemId(Integer accountItemId) {
this.accountItemId = accountItemId;
}
public QuotationIndexResponseQuotationContents accountItemName(String accountItemName) {
this.accountItemName = accountItemName;
return this;
}
/**
* 勘定科目名
* @return accountItemName
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "売上", required = true, value = "勘定科目名")
public String getAccountItemName() {
return accountItemName;
}
public void setAccountItemName(String accountItemName) {
this.accountItemName = accountItemName;
}
public QuotationIndexResponseQuotationContents amount(Integer amount) {
this.amount = amount;
return this;
}
/**
* 内税/外税の判別とamountの税込み、税抜きについて <ul> <li>tax_entry_methodがexclusive (外税)の場合</li> <ul> <li>amount: 消費税抜きの金額</li> <li>vat: 消費税の金額</li> </ul> <li>tax_entry_methodがinclusive (内税)の場合</li> <ul> <li>amount: 消費税込みの金額</li> <li>vat: 消費税の金額</li> </ul> </ul>
* @return amount
**/
@javax.annotation.Nonnull
@ApiModelProperty(example = "108000", required = true, value = "内税/外税の判別とamountの税込み、税抜きについて - tax_entry_methodがexclusive (外税)の場合
- amount: 消費税抜きの金額
- vat: 消費税の金額
- tax_entry_methodがinclusive (内税)の場合
- amount: 消費税込みの金額
- vat: 消費税の金額
")
public Integer getAmount() {
return amount;
}
public void setAmount(Integer amount) {
this.amount = amount;
}
public QuotationIndexResponseQuotationContents description(String description) {
this.description = description;
return this;
}
/**
* 備考
* @return description
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "備考", required = true, value = "備考")
public String getDescription() {
return description;
}
public void setDescription(String description) {
this.description = description;
}
public QuotationIndexResponseQuotationContents id(Integer id) {
this.id = id;
return this;
}
/**
* 見積内容ID
* @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 QuotationIndexResponseQuotationContents itemId(Integer itemId) {
this.itemId = itemId;
return this;
}
/**
* 品目ID
* @return itemId
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "1", required = true, value = "品目ID")
public Integer getItemId() {
return itemId;
}
public void setItemId(Integer itemId) {
this.itemId = itemId;
}
public QuotationIndexResponseQuotationContents itemName(String itemName) {
this.itemName = itemName;
return this;
}
/**
* 品目
* @return itemName
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "freee会計", required = true, value = "品目")
public String getItemName() {
return itemName;
}
public void setItemName(String itemName) {
this.itemName = itemName;
}
public QuotationIndexResponseQuotationContents order(Integer order) {
this.order = order;
return this;
}
/**
* 順序
* @return order
**/
@javax.annotation.Nonnull
@ApiModelProperty(example = "1", required = true, value = "順序")
public Integer getOrder() {
return order;
}
public void setOrder(Integer order) {
this.order = order;
}
public QuotationIndexResponseQuotationContents qty(BigDecimal qty) {
this.qty = qty;
return this;
}
/**
* 数量
* @return qty
**/
@javax.annotation.Nonnull
@ApiModelProperty(example = "1", required = true, value = "数量")
public BigDecimal getQty() {
return qty;
}
public void setQty(BigDecimal qty) {
this.qty = qty;
}
public QuotationIndexResponseQuotationContents reducedVat(Boolean reducedVat) {
this.reducedVat = reducedVat;
return this;
}
/**
* 軽減税率税区分(true: 対象、false: 対象外)
* @return reducedVat
**/
@javax.annotation.Nonnull
@ApiModelProperty(example = "true", required = true, value = "軽減税率税区分(true: 対象、false: 対象外)")
public Boolean getReducedVat() {
return reducedVat;
}
public void setReducedVat(Boolean reducedVat) {
this.reducedVat = reducedVat;
}
public QuotationIndexResponseQuotationContents sectionId(Integer sectionId) {
this.sectionId = sectionId;
return this;
}
/**
* 部門ID
* @return sectionId
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "1", required = true, value = "部門ID")
public Integer getSectionId() {
return sectionId;
}
public void setSectionId(Integer sectionId) {
this.sectionId = sectionId;
}
public QuotationIndexResponseQuotationContents sectionName(String sectionName) {
this.sectionName = sectionName;
return this;
}
/**
* 部門
* @return sectionName
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "開発部", required = true, value = "部門")
public String getSectionName() {
return sectionName;
}
public void setSectionName(String sectionName) {
this.sectionName = sectionName;
}
public QuotationIndexResponseQuotationContents segment1TagId(Long segment1TagId) {
this.segment1TagId = segment1TagId;
return this;
}
/**
* セグメント1ID
* @return segment1TagId
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "1", value = "セグメント1ID")
public Long getSegment1TagId() {
return segment1TagId;
}
public void setSegment1TagId(Long segment1TagId) {
this.segment1TagId = segment1TagId;
}
public QuotationIndexResponseQuotationContents segment1TagName(String segment1TagName) {
this.segment1TagName = segment1TagName;
return this;
}
/**
* セグメント1ID
* @return segment1TagName
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "セグメント1", value = "セグメント1ID")
public String getSegment1TagName() {
return segment1TagName;
}
public void setSegment1TagName(String segment1TagName) {
this.segment1TagName = segment1TagName;
}
public QuotationIndexResponseQuotationContents segment2TagId(Long segment2TagId) {
this.segment2TagId = segment2TagId;
return this;
}
/**
* セグメント2ID
* @return segment2TagId
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "1", value = "セグメント2ID")
public Long getSegment2TagId() {
return segment2TagId;
}
public void setSegment2TagId(Long segment2TagId) {
this.segment2TagId = segment2TagId;
}
public QuotationIndexResponseQuotationContents segment2TagName(String segment2TagName) {
this.segment2TagName = segment2TagName;
return this;
}
/**
* セグメント2
* @return segment2TagName
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "セグメント2", value = "セグメント2")
public String getSegment2TagName() {
return segment2TagName;
}
public void setSegment2TagName(String segment2TagName) {
this.segment2TagName = segment2TagName;
}
public QuotationIndexResponseQuotationContents segment3TagId(Long segment3TagId) {
this.segment3TagId = segment3TagId;
return this;
}
/**
* セグメント3ID
* @return segment3TagId
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "1", value = "セグメント3ID")
public Long getSegment3TagId() {
return segment3TagId;
}
public void setSegment3TagId(Long segment3TagId) {
this.segment3TagId = segment3TagId;
}
public QuotationIndexResponseQuotationContents segment3TagName(String segment3TagName) {
this.segment3TagName = segment3TagName;
return this;
}
/**
* セグメント3
* @return segment3TagName
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "セグメント3", value = "セグメント3")
public String getSegment3TagName() {
return segment3TagName;
}
public void setSegment3TagName(String segment3TagName) {
this.segment3TagName = segment3TagName;
}
public QuotationIndexResponseQuotationContents tagIds(List tagIds) {
this.tagIds = tagIds;
return this;
}
public QuotationIndexResponseQuotationContents addTagIdsItem(Integer tagIdsItem) {
this.tagIds.add(tagIdsItem);
return this;
}
/**
* Get tagIds
* @return tagIds
**/
@javax.annotation.Nonnull
@ApiModelProperty(required = true, value = "")
public List getTagIds() {
return tagIds;
}
public void setTagIds(List tagIds) {
this.tagIds = tagIds;
}
public QuotationIndexResponseQuotationContents tagNames(List tagNames) {
this.tagNames = tagNames;
return this;
}
public QuotationIndexResponseQuotationContents addTagNamesItem(String tagNamesItem) {
this.tagNames.add(tagNamesItem);
return this;
}
/**
* Get tagNames
* @return tagNames
**/
@javax.annotation.Nonnull
@ApiModelProperty(required = true, value = "")
public List getTagNames() {
return tagNames;
}
public void setTagNames(List tagNames) {
this.tagNames = tagNames;
}
public QuotationIndexResponseQuotationContents taxCode(Integer taxCode) {
this.taxCode = taxCode;
return this;
}
/**
* 税区分コード
* @return taxCode
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "1", required = true, value = "税区分コード")
public Integer getTaxCode() {
return taxCode;
}
public void setTaxCode(Integer taxCode) {
this.taxCode = taxCode;
}
public QuotationIndexResponseQuotationContents type(TypeEnum type) {
this.type = type;
return this;
}
/**
* 行の種類
* @return type
**/
@javax.annotation.Nonnull
@ApiModelProperty(example = "normal", required = true, value = "行の種類")
public TypeEnum getType() {
return type;
}
public void setType(TypeEnum type) {
this.type = type;
}
public QuotationIndexResponseQuotationContents unit(String unit) {
this.unit = unit;
return this;
}
/**
* 単位
* @return unit
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "個", required = true, value = "単位")
public String getUnit() {
return unit;
}
public void setUnit(String unit) {
this.unit = unit;
}
public QuotationIndexResponseQuotationContents unitPrice(BigDecimal unitPrice) {
this.unitPrice = unitPrice;
return this;
}
/**
* 単価
* @return unitPrice
**/
@javax.annotation.Nonnull
@ApiModelProperty(example = "1", required = true, value = "単価")
public BigDecimal getUnitPrice() {
return unitPrice;
}
public void setUnitPrice(BigDecimal unitPrice) {
this.unitPrice = unitPrice;
}
public QuotationIndexResponseQuotationContents vat(Integer vat) {
this.vat = vat;
return this;
}
/**
* 消費税額
* @return vat
**/
@javax.annotation.Nonnull
@ApiModelProperty(example = "8000", required = true, value = "消費税額")
public Integer getVat() {
return vat;
}
public void setVat(Integer vat) {
this.vat = vat;
}
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
QuotationIndexResponseQuotationContents quotationIndexResponseQuotationContents = (QuotationIndexResponseQuotationContents) o;
return Objects.equals(this.accountItemId, quotationIndexResponseQuotationContents.accountItemId) &&
Objects.equals(this.accountItemName, quotationIndexResponseQuotationContents.accountItemName) &&
Objects.equals(this.amount, quotationIndexResponseQuotationContents.amount) &&
Objects.equals(this.description, quotationIndexResponseQuotationContents.description) &&
Objects.equals(this.id, quotationIndexResponseQuotationContents.id) &&
Objects.equals(this.itemId, quotationIndexResponseQuotationContents.itemId) &&
Objects.equals(this.itemName, quotationIndexResponseQuotationContents.itemName) &&
Objects.equals(this.order, quotationIndexResponseQuotationContents.order) &&
Objects.equals(this.qty, quotationIndexResponseQuotationContents.qty) &&
Objects.equals(this.reducedVat, quotationIndexResponseQuotationContents.reducedVat) &&
Objects.equals(this.sectionId, quotationIndexResponseQuotationContents.sectionId) &&
Objects.equals(this.sectionName, quotationIndexResponseQuotationContents.sectionName) &&
Objects.equals(this.segment1TagId, quotationIndexResponseQuotationContents.segment1TagId) &&
Objects.equals(this.segment1TagName, quotationIndexResponseQuotationContents.segment1TagName) &&
Objects.equals(this.segment2TagId, quotationIndexResponseQuotationContents.segment2TagId) &&
Objects.equals(this.segment2TagName, quotationIndexResponseQuotationContents.segment2TagName) &&
Objects.equals(this.segment3TagId, quotationIndexResponseQuotationContents.segment3TagId) &&
Objects.equals(this.segment3TagName, quotationIndexResponseQuotationContents.segment3TagName) &&
Objects.equals(this.tagIds, quotationIndexResponseQuotationContents.tagIds) &&
Objects.equals(this.tagNames, quotationIndexResponseQuotationContents.tagNames) &&
Objects.equals(this.taxCode, quotationIndexResponseQuotationContents.taxCode) &&
Objects.equals(this.type, quotationIndexResponseQuotationContents.type) &&
Objects.equals(this.unit, quotationIndexResponseQuotationContents.unit) &&
Objects.equals(this.unitPrice, quotationIndexResponseQuotationContents.unitPrice) &&
Objects.equals(this.vat, quotationIndexResponseQuotationContents.vat);
}
private static boolean equalsNullable(JsonNullable a, JsonNullable b) {
return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get()));
}
@Override
public int hashCode() {
return Objects.hash(accountItemId, accountItemName, amount, description, id, itemId, itemName, order, qty, reducedVat, sectionId, sectionName, segment1TagId, segment1TagName, segment2TagId, segment2TagName, segment3TagId, segment3TagName, tagIds, tagNames, taxCode, type, unit, unitPrice, vat);
}
private static int hashCodeNullable(JsonNullable a) {
if (a == null) {
return 1;
}
return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31;
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class QuotationIndexResponseQuotationContents {\n");
sb.append(" accountItemId: ").append(toIndentedString(accountItemId)).append("\n");
sb.append(" accountItemName: ").append(toIndentedString(accountItemName)).append("\n");
sb.append(" amount: ").append(toIndentedString(amount)).append("\n");
sb.append(" description: ").append(toIndentedString(description)).append("\n");
sb.append(" id: ").append(toIndentedString(id)).append("\n");
sb.append(" itemId: ").append(toIndentedString(itemId)).append("\n");
sb.append(" itemName: ").append(toIndentedString(itemName)).append("\n");
sb.append(" order: ").append(toIndentedString(order)).append("\n");
sb.append(" qty: ").append(toIndentedString(qty)).append("\n");
sb.append(" reducedVat: ").append(toIndentedString(reducedVat)).append("\n");
sb.append(" sectionId: ").append(toIndentedString(sectionId)).append("\n");
sb.append(" sectionName: ").append(toIndentedString(sectionName)).append("\n");
sb.append(" segment1TagId: ").append(toIndentedString(segment1TagId)).append("\n");
sb.append(" segment1TagName: ").append(toIndentedString(segment1TagName)).append("\n");
sb.append(" segment2TagId: ").append(toIndentedString(segment2TagId)).append("\n");
sb.append(" segment2TagName: ").append(toIndentedString(segment2TagName)).append("\n");
sb.append(" segment3TagId: ").append(toIndentedString(segment3TagId)).append("\n");
sb.append(" segment3TagName: ").append(toIndentedString(segment3TagName)).append("\n");
sb.append(" tagIds: ").append(toIndentedString(tagIds)).append("\n");
sb.append(" tagNames: ").append(toIndentedString(tagNames)).append("\n");
sb.append(" taxCode: ").append(toIndentedString(taxCode)).append("\n");
sb.append(" type: ").append(toIndentedString(type)).append("\n");
sb.append(" unit: ").append(toIndentedString(unit)).append("\n");
sb.append(" unitPrice: ").append(toIndentedString(unitPrice)).append("\n");
sb.append(" vat: ").append(toIndentedString(vat)).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 ");
}
}