1 11 package org.eclipse.update.core.model; 12 13 14 30 public abstract class ContentEntryModel extends ModelObject { 31 32 37 public static final long UNKNOWN_SIZE = -1; 38 39 private long downloadSize = UNKNOWN_SIZE; 40 private long installSize = UNKNOWN_SIZE; 41 private String os; 42 private String ws; 43 private String nl; 44 private String arch; 45 46 51 protected ContentEntryModel() { 52 super(); 53 } 54 55 62 63 public long getDownloadSize() { 64 return downloadSize; 65 } 66 67 74 public long getInstallSize() { 75 return installSize; 76 } 77 78 84 public String getOS() { 85 return os; 86 } 87 88 94 95 public String getWS() { 96 return ws; 97 } 98 99 105 public String getOSArch() { 106 return arch; 107 } 108 109 115 public String getNL() { 116 return nl; 117 } 118 119 126 public void setDownloadSize(long downloadSize) { 127 assertIsWriteable(); 128 if (downloadSize < 0) 129 this.downloadSize = UNKNOWN_SIZE; 130 else 131 this.downloadSize = downloadSize; 132 } 133 134 141 public void setInstallSize(long installSize) { 142 assertIsWriteable(); 143 if (installSize < 0) 144 this.installSize = UNKNOWN_SIZE; 145 else 146 this.installSize = installSize; 147 } 148 149 156 public void setOS(String os) { 157 assertIsWriteable(); 158 this.os = os; 159 } 160 161 168 public void setWS(String ws) { 169 assertIsWriteable(); 170 this.ws = ws; 171 } 172 173 180 public void setArch(String arch) { 181 assertIsWriteable(); 182 this.arch = arch; 183 } 184 185 192 public void setNL(String nl) { 193 assertIsWriteable(); 194 this.nl = nl; 195 } 196 } 197 | Popular Tags |