1 27 28 package olstore.form; 29 30 31 import java.util.Vector; 32 33 import olstore.dto.PictureValue; 34 import olstore.dto.PropertyValue; 35 36 37 public class CreateItemForm extends DemoBaseForm { 38 39 40 private String ItemId = null; 41 private String Name = null; 42 private String Price = null; 43 private String ShortDesc = null; 44 private String LongDesc = null; 45 private String TypeId = null; 46 private Boolean MainPage = new Boolean ( false ); 47 private Boolean SpecialOffer= new Boolean ( false ); 48 49 private String NumPics = null; 50 private String NumProps = null; 51 private String Submit = null; 52 53 private Vector Properties = new Vector() ; 54 private Vector Pictures = new Vector(); 55 56 57 public String getItemId () { 58 return this.ItemId; 59 } 60 public void setItemId ( String itemId ) { 61 this.ItemId = itemId; 62 } 63 64 public String getName () { 65 return this.Name; 66 } 67 public void setName ( String name ) { 68 this.Name = name; 69 } 70 71 public String getPrice () { 72 return this.Price; 73 } 74 public void setPrice ( String price ) { 75 this.Price= price; 76 } 77 78 public String getShortDesc () { 79 return this.ShortDesc; 80 } 81 public void setShortDesc ( String shortDesc ) { 82 this.ShortDesc= shortDesc; 83 } 84 85 public String getLongDesc () { 86 return this.LongDesc; 87 } 88 public void setLongDesc ( String longDesc) { 89 this.LongDesc = longDesc; 90 } 91 92 public String getTypeId () { 93 return this.TypeId ; 94 } 95 public void setTypeId ( String typeId ) { 96 this.TypeId = typeId ; 97 } 98 99 public Boolean getMainPage() { 100 return this.MainPage; 101 } 102 public void setMainPage ( Boolean mainPage) { 103 this.MainPage= mainPage; 104 } 105 106 public Boolean getSpecialOffer () { 107 return this.SpecialOffer; 108 } 109 public void setSpecialOffer ( Boolean specialOffer ) { 110 this.SpecialOffer = specialOffer ; 111 } 112 113 114 122 public PropertyValue getProp (int index) { 123 if ( index >= Properties.size() ) { 124 int size = Properties.size(); 125 for ( int i =0; i < (index-size) + 1 ; i++ ) { 126 Properties.add ( new PropertyValue() ); 127 } 128 } 129 return (PropertyValue) Properties.get ( index ); 130 } 131 132 public void setProp ( int index, PropertyValue property ) { 133 Properties.set ( index, property ); 134 } 135 136 139 public Vector getProperties( ) { 140 return Properties; 141 } 142 143 public void setProperties ( Vector props ) { 144 Properties = props; 145 } 146 147 155 public PictureValue getPic (int index) { 156 if ( index >= Pictures.size() ) { 157 int size = Pictures.size(); 158 for ( int i =0; i < (index-size) + 1 ; i++ ) { 159 Pictures.add ( new PictureValue() ); 160 } 161 } 162 return (PictureValue) Pictures.get ( index ); 163 } 164 165 public void setPic ( int index, PictureValue picture ) { 166 Pictures.set ( index, picture ); 167 } 168 169 172 public Vector getPictures( ) { 173 return Pictures; 174 } 175 176 public void setPictures ( Vector pics ) { 177 Pictures = pics ; 178 } 179 180 public String getNumPics () { 182 return this.NumPics; 183 } 184 public void setNumPics ( String numPics ) { 185 this.NumPics = numPics ; 186 } 187 188 public String getNumProps () { 189 return this.NumProps; 190 } 191 public void setNumProps ( String numProps) { 192 this.NumProps = numProps; 193 } 194 195 public String getSubmitType () { 196 return this.Submit; 197 } 198 public void setSubmitType ( String submit ) { 199 this.Submit = submit; 200 } 201 202 } 203 | Popular Tags |