tests/libjava-mauve/src/gnu/testlet/javax/print/attribute/EnumSyntax/CorrectEnumSyntax.java
branchjk_new_structure
changeset 1541 75c2e24dea9a
parent 1540 92ac284961c1
child 1542 be11db817bcf
equal deleted inserted replaced
1540:92ac284961c1 1541:75c2e24dea9a
     1 //Tags: not-a-test
       
     2 
       
     3 //Copyright (C) 2005 Free Software Foundation, Inc.
       
     4 //Written by Wolfgang Baer (WBaer@gmx.de)
       
     5 
       
     6 //This file is part of Mauve.
       
     7 
       
     8 //Mauve is free software; you can redistribute it and/or modify
       
     9 //it under the terms of the GNU General Public License as published by
       
    10 //the Free Software Foundation; either version 2, or (at your option)
       
    11 //any later version.
       
    12 
       
    13 //Mauve is distributed in the hope that it will be useful,
       
    14 //but WITHOUT ANY WARRANTY; without even the implied warranty of
       
    15 //MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
       
    16 //GNU General Public License for more details.
       
    17 
       
    18 //You should have received a copy of the GNU General Public License
       
    19 //along with Mauve; see the file COPYING.  If not, write to
       
    20 //the Free Software Foundation, 59 Temple Place - Suite 330,
       
    21 //Boston, MA 02111-1307, USA.  */
       
    22 
       
    23 
       
    24 package gnu.testlet.javax.print.attribute.EnumSyntax;
       
    25 
       
    26 import javax.print.attribute.EnumSyntax;
       
    27 
       
    28 /**
       
    29  * Helper class testing EnumSyntax implementation which
       
    30  * is correctly subclassed according to specification.
       
    31  */
       
    32 public class CorrectEnumSyntax extends EnumSyntax
       
    33 {
       
    34   public static final CorrectEnumSyntax TEST1 = new CorrectEnumSyntax(3);
       
    35   public static final CorrectEnumSyntax TEST2 = new CorrectEnumSyntax(4);
       
    36   public static final CorrectEnumSyntax TEST3 = new CorrectEnumSyntax(5);
       
    37 
       
    38   protected CorrectEnumSyntax(int value)
       
    39   {
       
    40     super(value);
       
    41   }
       
    42 
       
    43   protected int getOffset()
       
    44   {
       
    45     return 3;
       
    46   }
       
    47 
       
    48   private static final String[] stringTable = { "test1", "test2", "test3"};
       
    49 
       
    50   protected String[] getStringTable()
       
    51   {
       
    52     return stringTable;
       
    53   }
       
    54 
       
    55   private static final CorrectEnumSyntax[] enumValueTable = 
       
    56                                         { TEST1, TEST2, TEST3};
       
    57 
       
    58   protected EnumSyntax[] getEnumValueTable()
       
    59   {
       
    60     return enumValueTable;
       
    61   }
       
    62 }