Initial import.
[clinton/mirror/jspi/.git] / jspi / src / main / java / de / lohndirekt / print / attribute / IppValueTag.java
1 /**
2 * Copyright (C) 2003 <a href="http://www.lohndirekt.de/">lohndirekt.de</a>
3 *
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
8 *
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
13 *
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 *
18 */
19 package de.lohndirekt.print.attribute;
20
21 /**
22 *Bezeichnungen übernommen aus <link>www.ietf.org/rfc/rfc2910.txt</link>
23 *Tags ohne Bezeichnung sind dort nicht aufgeführt, werden aber in der Cups-API verwendet
24 */
25 public class IppValueTag {
26
27 private String description;
28 private int value = 0;
29
30 public static final IppValueTag UNSUPPORTED_VALUE = new IppValueTag(0x10, "unsupported");
31 public static final IppValueTag DEFAULT = new IppValueTag(0x11, "'default' ");
32 public static final IppValueTag UNKNOWN = new IppValueTag(0x12, "unknown");
33 public static final IppValueTag NOVALUE = new IppValueTag(0x13, "no-value");
34 public static final IppValueTag NOTSETTABLE = new IppValueTag(0x15, "");
35 public static final IppValueTag DELETEATTR = new IppValueTag(0x16, "");
36 public static final IppValueTag ADMINDEFINE = new IppValueTag(0x17, "");
37 public static final IppValueTag INTEGER = new IppValueTag(0x21, "integer");
38 public static final IppValueTag BOOLEAN = new IppValueTag(0x22, "boolean");
39 public static final IppValueTag ENUM = new IppValueTag(0x23, "enum");
40 public static final IppValueTag STRING = new IppValueTag(0x30, "octetString");
41 public static final IppValueTag DATE = new IppValueTag(0x31, "dateTime");
42 public static final IppValueTag RESOLUTION = new IppValueTag(0x32, "resolution");
43 public static final IppValueTag RANGE = new IppValueTag(0x33, "rangeOfInteger");
44 public static final IppValueTag BEGIN_COLLECTION = new IppValueTag(0x34, "");
45 public static final IppValueTag TEXTLANG = new IppValueTag(0x35, "resolution");
46 public static final IppValueTag NAMELANG = new IppValueTag(0x36, "nameWithLanguage");
47 public static final IppValueTag END_COLLECTION = new IppValueTag(0x37, "");
48 public static final IppValueTag TEXT = new IppValueTag(0x41, "textWithoutLanguage");
49 public static final IppValueTag NAME = new IppValueTag(0x42, "nameWithoutLanguage");
50 public static final IppValueTag KEYWORD = new IppValueTag(0x44, "keyword");
51 public static final IppValueTag URI = new IppValueTag(0x45, "uri");
52 public static final IppValueTag URISCHEME = new IppValueTag(0x46, "uriScheme");
53 public static final IppValueTag CHARSET = new IppValueTag(0x47, "charset");
54 public static final IppValueTag LANGUAGE = new IppValueTag(0x48, "naturalLanguage");
55 public static final IppValueTag MIMETYPE = new IppValueTag(0x49, "mimeMediaType");
56 public static final IppValueTag MEMBERNAME = new IppValueTag(0x4A, "");
57 public static final IppValueTag MASK = new IppValueTag(0x7FFFFFFF, "");
58 public static final IppValueTag COPY = new IppValueTag(0x80000001, "");
59
60 private IppValueTag(int value, String description) {
61 this.value = value;
62 this.description = description;
63 }
64
65 public int getValue() {
66 return this.value;
67 }
68
69
70 public String toString() {
71 return this.description;
72 }
73
74 }