1 7 8 package javax.print.attribute.standard; 9 10 import javax.print.attribute.Attribute ; 11 import javax.print.attribute.EnumSyntax ; 12 import javax.print.attribute.PrintJobAttribute ; 13 14 31 32 public class JobState extends EnumSyntax implements PrintJobAttribute { 33 34 private static final long serialVersionUID = 400465010094018920L; 35 36 39 public static final JobState UNKNOWN = new JobState (0); 40 41 44 public static final JobState PENDING = new JobState (3); 45 46 52 public static final JobState PENDING_HELD = new JobState (4); 53 54 86 public static final JobState PROCESSING = new JobState (5); 87 88 104 public static final JobState PROCESSING_STOPPED = new JobState (6); 105 106 117 public static final JobState CANCELED = new JobState (7); 118 119 130 public static final JobState ABORTED = new JobState (8); 131 132 141 public static final JobState COMPLETED = new JobState (9); 142 143 145 150 protected JobState(int value) { 151 super (value); 152 } 153 154 private static final String [] myStringTable = 155 {"unknown", 156 null, 157 null, 158 "pending", 159 "pending-held", 160 "processing", 161 "processing-stopped", 162 "canceled", 163 "aborted", 164 "completed"}; 165 166 private static final JobState [] myEnumValueTable = 167 {UNKNOWN, 168 null, 169 null, 170 PENDING, 171 PENDING_HELD, 172 PROCESSING, 173 PROCESSING_STOPPED, 174 CANCELED, 175 ABORTED, 176 COMPLETED}; 177 178 181 protected String [] getStringTable() { 182 return myStringTable; 183 } 184 185 188 protected EnumSyntax [] getEnumValueTable() { 189 return myEnumValueTable; 190 } 191 192 202 public final Class <? extends Attribute > getCategory() { 203 return JobState .class; 204 } 205 206 215 public final String getName() { 216 return "job-state"; 217 } 218 219 } 220 | Popular Tags |