[Buix-commits] r224 - in trunk/jaxx/src/main/java/jaxx: . util
Author: tchemit Date: 2008-02-24 18:51:57 +0000 (Sun, 24 Feb 2008) New Revision: 224 Added: trunk/jaxx/src/main/java/jaxx/util/ trunk/jaxx/src/main/java/jaxx/util/SimplePaginationEnum.java Log: ajout d'une enum pour definir une suite d'entiers (utilise sur un composant Paginationpar exemple) Added: trunk/jaxx/src/main/java/jaxx/util/SimplePaginationEnum.java =================================================================== --- trunk/jaxx/src/main/java/jaxx/util/SimplePaginationEnum.java (rev 0) +++ trunk/jaxx/src/main/java/jaxx/util/SimplePaginationEnum.java 2008-02-24 18:51:57 UTC (rev 224) @@ -0,0 +1,47 @@ +/* +* ##% Copyright (C) 2007, 2008 Code Lutin, Tony Chemit +* +* This program is free software; you can redistribute it and/or +* modify it under the terms of the GNU General Public License +* as published by the Free Software Foundation; either version 2 +* of the License, or (at your option) any later version. +* +* This program is distributed in the hope that it will be useful, +* but WITHOUT ANY WARRANTY; without even the implied warranty of +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +* GNU General Public License for more details. +* +* You should have received a copy of the GNU General Public License +* along with this program; if not, write to the Free Software +* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +* ##% */ +package jaxx.util; + +/** + * Une enumration pour definir les tailles de liste + * + * @author chemit + */ +public enum SimplePaginationEnum { + _5, + _10, + _20, + _50, + _100; + + int intValue; + + SimplePaginationEnum() { + intValue = Integer.valueOf(toString()); + } + + @Override + public String toString() { + return super.toString().substring(1); + } + + public int intValue() { + return intValue; + } + +}
participants (1)
-
tchemit@users.labs.libre-entreprise.org