0N/A/*
2362N/A * Copyright (c) 2000, 2003, Oracle and/or its affiliates. All rights reserved.
0N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
0N/A *
0N/A * This code is free software; you can redistribute it and/or modify it
0N/A * under the terms of the GNU General Public License version 2 only, as
2362N/A * published by the Free Software Foundation. Oracle designates this
0N/A * particular file as subject to the "Classpath" exception as provided
2362N/A * by Oracle in the LICENSE file that accompanied this code.
0N/A *
0N/A * This code is distributed in the hope that it will be useful, but WITHOUT
0N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
0N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
0N/A * version 2 for more details (a copy is included in the LICENSE file that
0N/A * accompanied this code).
0N/A *
0N/A * You should have received a copy of the GNU General Public License version
0N/A * 2 along with this work; if not, write to the Free Software Foundation,
0N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
0N/A *
2362N/A * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
2362N/A * or visit www.oracle.com if you need additional information or have any
2362N/A * questions.
0N/A */
0N/Apackage javax.print.attribute.standard;
0N/A
0N/Aimport java.util.Locale;
0N/Aimport javax.print.attribute.Attribute;
0N/Aimport javax.print.attribute.EnumSyntax;
0N/A
0N/A/**
0N/A * Class MediaName is a subclass of Media, a printing attribute class (an
0N/A * enumeration) that specifies the media for a print job as a name.
0N/A * <P>
0N/A * This attribute can be used instead of specifying MediaSize or MediaTray.
0N/A * <p>
0N/A * Class MediaName currently declares a few standard media names.
0N/A * Implementation- or site-defined names for a media name attribute may also
0N/A * be created by defining a subclass of class MediaName.
0N/A * <P>
0N/A * <B>IPP Compatibility:</B> MediaName is a representation class for
0N/A * values of the IPP "media" attribute which names media.
0N/A * <P>
0N/A *
0N/A */
0N/Apublic class MediaName extends Media implements Attribute {
0N/A
0N/A private static final long serialVersionUID = 4653117714524155448L;
0N/A
0N/A /**
0N/A * white letter paper.
0N/A */
0N/A public static final MediaName NA_LETTER_WHITE = new MediaName(0);
0N/A
0N/A /**
0N/A * letter transparency.
0N/A */
0N/A public static final MediaName NA_LETTER_TRANSPARENT = new MediaName(1);
0N/A
0N/A /**
0N/A * white A4 paper.
0N/A */
0N/A public static final MediaName ISO_A4_WHITE = new MediaName(2);
0N/A
0N/A
0N/A /**
0N/A * A4 transparency.
0N/A */
0N/A public static final MediaName ISO_A4_TRANSPARENT= new MediaName(3);
0N/A
0N/A
0N/A /**
0N/A * Constructs a new media name enumeration value with the given integer
0N/A * value.
0N/A *
0N/A * @param value Integer value.
0N/A */
0N/A protected MediaName(int value) {
0N/A super (value);
0N/A }
0N/A
0N/A private static final String[] myStringTable = {
0N/A "na-letter-white",
0N/A "na-letter-transparent",
0N/A "iso-a4-white",
0N/A "iso-a4-transparent"
0N/A };
0N/A
0N/A private static final MediaName[] myEnumValueTable = {
0N/A NA_LETTER_WHITE,
0N/A NA_LETTER_TRANSPARENT,
0N/A ISO_A4_WHITE,
0N/A ISO_A4_TRANSPARENT
0N/A };
0N/A
0N/A /**
0N/A * Returns the string table for class MediaTray.
0N/A * @return the String table.
0N/A */
0N/A protected String[] getStringTable()
0N/A {
0N/A return (String[])myStringTable.clone();
0N/A }
0N/A
0N/A /**
0N/A * Returns the enumeration value table for class MediaTray.
0N/A * @return the enumeration value table.
0N/A */
0N/A protected EnumSyntax[] getEnumValueTable() {
0N/A return (EnumSyntax[])myEnumValueTable.clone();
0N/A }
0N/A
0N/A}