001    package org.jgnuplot;
002    
003    /**
004     * This class models all possibe values for axes used by the plot command.
005     * 
006     * @author Pander
007     */
008    public final class Axes {
009       private Axes() {
010       }
011    
012       public static final int NOT_SPECIFIED = -2;
013    
014       public static final int X1Y1 = 1;
015    
016       public static final int X1Y2 = 2;
017    
018       public static final int X2Y1 = 3;
019    
020       public static final int X2Y2 = 4;
021    
022       public static String toString(int theAxes) {
023          switch (theAxes) {
024          case NOT_SPECIFIED:
025             return null;
026          case X1Y1:
027             return "x1y1";
028          case X1Y2:
029             return "x1y2";
030          case X2Y1:
031             return "x2y1";
032          case X2Y2:
033             return "x2y2";
034          default:
035             throw new IllegalArgumentException("Unknown Axes");
036          }
037       }
038    }