1 /************************************************************************* 2 * 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * Copyright 2000, 2010 Oracle and/or its affiliates. 6 * 7 * OpenOffice.org - a multi-platform office productivity suite 8 * 9 * This file is part of OpenOffice.org. 10 * 11 * OpenOffice.org is free software: you can redistribute it and/or modify 12 * it under the terms of the GNU Lesser General Public License version 3 13 * only, as published by the Free Software Foundation. 14 * 15 * OpenOffice.org is distributed in the hope that it will be useful, 16 * but WITHOUT ANY WARRANTY; without even the implied warranty of 17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18 * GNU Lesser General Public License version 3 for more details 19 * (a copy is included in the LICENSE file that accompanied this code). 20 * 21 * You should have received a copy of the GNU Lesser General Public License 22 * version 3 along with OpenOffice.org. If not, see 23 * <http://www.openoffice.org/license.html> 24 * for a copy of the LGPLv3 License. 25 * 26 ************************************************************************/ 27 28 package com.sun.star.uno; 29 30 /** 31 * The Enum class is the base class for all classes generated 32 * as java binding for the IDL type enum. 33 * Each java mapped enum class provides static member of this class 34 * which represents the enum values. 35 * You cannot create a object of this class or subclass direct, to 36 * avoid enum values with integer values outside the defined range. 37 * <p> 38 * @version $Revision: 1.5 $ $ $Date: 2008-04-11 11:11:59 $ 39 */ 40 public abstract class Enum { 41 private int m_value; 42 43 /** 44 * Constructs a enum value. 45 * <p> 46 * @param value the integer value of this enum value. 47 */ 48 protected Enum(int value) { 49 m_value = value; 50 } 51 52 /** 53 * Get the integer value of an enum value. 54 * <p> 55 * @return the integer value. 56 */ 57 public final int getValue() { 58 return m_value; 59 } 60 } 61 62