001/* 002 * Copyright (C) 2014 konik.io 003 * 004 * This file is part of Konik library. 005 * 006 * Konik library is free software: you can redistribute it and/or modify 007 * it under the terms of the GNU Affero General Public License as published by 008 * the Free Software Foundation, either version 3 of the License, or 009 * (at your option) any later version. 010 * 011 * Konik library is distributed in the hope that it will be useful, 012 * but WITHOUT ANY WARRANTY; without even the implied warranty of 013 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 014 * GNU Affero General Public License for more details. 015 * 016 * You should have received a copy of the GNU Affero General Public License 017 * along with Konik library. If not, see <http://www.gnu.org/licenses/>. 018 */ 019package io.konik.zugferd.entity; 020 021import javax.validation.Valid; 022import javax.xml.bind.annotation.XmlAccessType; 023import javax.xml.bind.annotation.XmlAccessorType; 024import javax.xml.bind.annotation.XmlElement; 025import javax.xml.bind.annotation.XmlType; 026 027/** 028 * = The Trade Item. 029 * 030 */ 031@XmlAccessorType(XmlAccessType.FIELD) 032@XmlType(name = "SupplyChainTradeLineItemType", propOrder = { "position", "agreement", "delivery","settlement", "product" }) 033public class Item { 034 035 @Valid 036 @XmlElement(name = "AssociatedDocumentLineDocument") 037 private DocumentLine position; 038 039 @Valid 040 @XmlElement(name = "SpecifiedSupplyChainTradeAgreement") 041 private Agreement agreement; 042 043 @Valid 044 @XmlElement(name = "SpecifiedSupplyChainTradeDelivery") 045 private Delivery delivery; 046 047 @Valid 048 @XmlElement(name = "SpecifiedSupplyChainTradeSettlement") 049 private Settlement settlement; 050 051 @Valid 052 @XmlElement(name = "SpecifiedTradeProduct") 053 private Product product; 054 055 /** 056 * Gets the item position document. 057 * 058 * @return the position 059 */ 060 public DocumentLine getPosition() { 061 return position; 062 } 063 064 /** 065 * Sets the item position document. 066 * 067 * @param position the new position 068 * @return the item 069 */ 070 public Item setPosition(DocumentLine position) { 071 this.position = position; 072 return this; 073 } 074 075 /** 076 * Gets the specified supply chain trade agreement. 077 * 078 * @return the specified supply chain trade agreement 079 */ 080 public Agreement getAgreement() { 081 return agreement; 082 } 083 084 /** 085 * Sets the specified supply chain trade agreement. 086 * 087 * @param agreement the new specified supply chain trade agreement 088 * @return the item 089 */ 090 public Item setAgreement(Agreement agreement) { 091 this.agreement = agreement; 092 return this; 093 } 094 095 /** 096 * Gets the specified supply chain trade delivery. 097 * 098 * @return the specified supply chain trade delivery 099 */ 100 public Delivery getDelivery() { 101 return delivery; 102 } 103 104 /** 105 * Sets the specified supply chain trade delivery. 106 * 107 * @param delivery the new specified supply chain trade delivery 108 * @return the item 109 */ 110 public Item setDelivery(Delivery delivery) { 111 this.delivery = delivery; 112 return this; 113 } 114 115 /** 116 * Gets the specified supply chain trade settlement. 117 * 118 * @return the specified supply chain trade settlement 119 */ 120 public Settlement getSettlement() { 121 return settlement; 122 } 123 124 /** 125 * Sets the specified supply chain trade settlement. 126 * 127 * @param settlement the new specified supply chain trade settlement 128 * @return the item 129 */ 130 public Item setSettlement(Settlement settlement) { 131 this.settlement = settlement; 132 return this; 133 } 134 135 /** 136 * Gets the specified trade product. 137 * 138 * @return the specified trade product 139 */ 140 public Product getProduct() { 141 return product; 142 } 143 144 /** 145 * Sets the specified trade product. 146 * 147 * @param product the product 148 * @return the item 149 */ 150 public Item setProduct(Product product) { 151 this.product = product; 152 return this; 153 } 154}