0N/A/*
157N/A * Copyright (c) 1997, 2001, 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
157N/A * published by the Free Software Foundation. Oracle designates this
0N/A * particular file as subject to the "Classpath" exception as provided
157N/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 *
157N/A * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
157N/A * or visit www.oracle.com if you need additional information or have any
157N/A * questions.
0N/A */
0N/A
0N/A/*
0N/A * File: ./org/omg/CORBA/DefinitionKind.java
0N/A * From: ./ir.idl
0N/A * Date: Fri Aug 28 16:03:31 1998
0N/A * By: idltojava Java IDL 1.2 Aug 11 1998 02:00:18
0N/A */
0N/A
0N/Apackage org.omg.CORBA;
0N/A
0N/A/**
0N/A* The class that provides the constants used to identify the type of an
0N/A* Interface Repository object. This class contains two kinds of constants,
0N/A* those that are an <code>int</code> and those that are an instance of the class
0N/A* <code>DefinitionKind</code>. This class provides the method
0N/A* <code>from_int</code>, which given one
0N/A* of the <code>int</code> constants, creates the corresponding
0N/A* <code>DefinitionKind</code> instance. It also provides the method
0N/A* <code>value</code>, which returns the <code>int</code> constant that
0N/A* is the value for a <code>DefinitionKind</code> instance.
0N/A*
0N/A* @see IRObject
0N/A*/
0N/A
0N/Apublic class DefinitionKind implements org.omg.CORBA.portable.IDLEntity {
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object
0N/A * does not have a definition kind.
0N/A */
0N/A public static final int _dk_none = 0,
0N/A
0N/A/**
0N/A * The constant that indicates that the type of an Interface Repository object
0N/A * may be any type.
0N/A */
0N/A _dk_all = 1,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is an
0N/A * attribute.
0N/A */
0N/A _dk_Attribute = 2,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is a
0N/A * constant.
0N/A */
0N/A _dk_Constant = 3,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is an
0N/A * exception.
0N/A */
0N/A
0N/A _dk_Exception = 4,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is an
0N/A * interface.
0N/A */
0N/A
0N/A _dk_Interface = 5,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is a
0N/A * module.
0N/A */
0N/A
0N/A _dk_Module = 6,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is an
0N/A * operation.
0N/A */
0N/A
0N/A _dk_Operation = 7,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is a
0N/A * Typedef.
0N/A */
0N/A
0N/A _dk_Typedef = 8,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is an
0N/A * Alias.
0N/A */
0N/A
0N/A _dk_Alias = 9,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is a
0N/A * Struct.
0N/A */
0N/A
0N/A _dk_Struct = 10,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is a
0N/A * Union.
0N/A */
0N/A
0N/A _dk_Union = 11,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is an
0N/A * Enum.
0N/A */
0N/A
0N/A _dk_Enum = 12,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is a
0N/A * Primitive.
0N/A */
0N/A
0N/A _dk_Primitive = 13,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is a
0N/A * String.
0N/A */
0N/A
0N/A _dk_String = 14,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is a
0N/A * Sequence.
0N/A */
0N/A
0N/A _dk_Sequence = 15,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is an
0N/A * Array.
0N/A */
0N/A
0N/A _dk_Array = 16,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is a
0N/A * Repository.
0N/A */
0N/A
0N/A _dk_Repository = 17,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is a
0N/A * Wstring.
0N/A */
0N/A
0N/A _dk_Wstring = 18,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is of type
0N/A * Fixed.
0N/A */
0N/A
0N/A _dk_Fixed = 19,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is a
0N/A * Value.
0N/A */
0N/A
0N/A _dk_Value = 20,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is a
0N/A * ValueBox.
0N/A */
0N/A
0N/A _dk_ValueBox = 21,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is a
0N/A * ValueMember.
0N/A */
0N/A
0N/A _dk_ValueMember = 22,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object is of type
0N/A * Native.
0N/A */
0N/A
0N/A _dk_Native = 23,
0N/A
0N/A/**
0N/A * The constant that indicates that an Interface Repository object
0N/A * is representing an abstract interface.
0N/A */
0N/A _dk_AbstractInterface = 24;
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object has no definition kind.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_none = new DefinitionKind(_dk_none);
0N/A
0N/A /**
0N/A * The wildcard <code>DefinitionKind</code> constant, useful
0N/A * in all occasions where any
0N/A * <code>DefinitionKind</code> is appropriate. The Container's
0N/A * <code>contents</code> method
0N/A * makes use of this constant to return all contained definitions of any kind.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_all = new DefinitionKind(_dk_all);
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is an Attribute.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_Attribute = new DefinitionKind(_dk_Attribute);
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is a constant.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_Constant = new DefinitionKind(_dk_Constant);
0N/A
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is an Exception.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_Exception = new DefinitionKind(_dk_Exception);
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is an Interface.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_Interface = new DefinitionKind(_dk_Interface);
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is a Module.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_Module = new DefinitionKind(_dk_Module);
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is an Operation.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_Operation = new DefinitionKind(_dk_Operation);
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is a Typedef.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_Typedef = new DefinitionKind(_dk_Typedef);
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is an Alias.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_Alias = new DefinitionKind(_dk_Alias);
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is a Struct.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_Struct = new DefinitionKind(_dk_Struct);
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is a Union.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_Union = new DefinitionKind(_dk_Union);
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is an Enum.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_Enum = new DefinitionKind(_dk_Enum);
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is a Primitive.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_Primitive = new DefinitionKind(_dk_Primitive);
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is a String.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_String = new DefinitionKind(_dk_String);
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is a Sequence.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_Sequence = new DefinitionKind(_dk_Sequence);
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is an Array.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_Array = new DefinitionKind(_dk_Array);
0N/A
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is a Repository.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_Repository = new DefinitionKind(_dk_Repository);
0N/A
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is a Wstring.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_Wstring = new DefinitionKind(_dk_Wstring);
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is a Fixed value.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_Fixed = new DefinitionKind(_dk_Fixed);
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is a Value.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_Value = new DefinitionKind(_dk_Value);
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is a ValueBox.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_ValueBox = new DefinitionKind(_dk_ValueBox);
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is a ValueMember.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_ValueMember = new DefinitionKind(_dk_ValueMember);
0N/A
0N/A
0N/A/**
0N/A * The static instance of <code>DefinitionKind</code> indicating that an
0N/A * Interface Repository object is a Native value.
0N/A */
0N/A
0N/A public static final DefinitionKind dk_Native = new DefinitionKind(_dk_Native);
0N/A
0N/A
0N/A/**
0N/A* The static instance of <code>DefinitionKind</code> indicating that an
0N/A* Interface Repository object represents an abstract interface.
0N/A*/
0N/A public static final DefinitionKind dk_AbstractInterface = new DefinitionKind(_dk_AbstractInterface);
0N/A
0N/A
0N/A /**
0N/A * Returns the <code>int</code> constant identifying the type of an IR object.
0N/A * @return the <code>int</code> constant from the class
0N/A * <code>DefinitionKind</code> that is the value of this
0N/A * <code>DefinitionKind</code> instance
0N/A */
0N/A
0N/A public int value() {
0N/A return _value;
0N/A }
0N/A
0N/A
0N/A /**
0N/A * Creates a <code>DefinitionKind</code> instance corresponding to the given code
0N/A.
0N/A * @param i one of the <code>int</code> constants from the class
0N/A * <code>DefinitionKind</code>
0N/A * @return the <code>DefinitionKind</code> instance corresponding
0N/A * to the given code
0N/A * @throws org.omg.CORBA.BAD_PARAM if the given parameter is not
0N/A one
0N/A * of the <code>int</code> constants from the class
0N/A * <code>DefinitionKind</code>
0N/A */
0N/A
0N/A public static DefinitionKind from_int(int i) {
0N/A switch (i) {
0N/A case _dk_none:
0N/A return dk_none;
0N/A case _dk_all:
0N/A return dk_all;
0N/A case _dk_Attribute:
0N/A return dk_Attribute;
0N/A case _dk_Constant:
0N/A return dk_Constant;
0N/A case _dk_Exception:
0N/A return dk_Exception;
0N/A case _dk_Interface:
0N/A return dk_Interface;
0N/A case _dk_Module:
0N/A return dk_Module;
0N/A case _dk_Operation:
0N/A return dk_Operation;
0N/A case _dk_Typedef:
0N/A return dk_Typedef;
0N/A case _dk_Alias:
0N/A return dk_Alias;
0N/A case _dk_Struct:
0N/A return dk_Struct;
0N/A case _dk_Union:
0N/A return dk_Union;
0N/A case _dk_Enum:
0N/A return dk_Enum;
0N/A case _dk_Primitive:
0N/A return dk_Primitive;
0N/A case _dk_String:
0N/A return dk_String;
0N/A case _dk_Sequence:
0N/A return dk_Sequence;
0N/A case _dk_Array:
0N/A return dk_Array;
0N/A case _dk_Repository:
0N/A return dk_Repository;
0N/A case _dk_Wstring:
0N/A return dk_Wstring;
0N/A case _dk_Fixed:
0N/A return dk_Fixed;
0N/A case _dk_Value:
0N/A return dk_Value;
0N/A case _dk_ValueBox:
0N/A return dk_ValueBox;
0N/A case _dk_ValueMember:
0N/A return dk_ValueMember;
0N/A case _dk_Native:
0N/A return dk_Native;
0N/A default:
0N/A throw new org.omg.CORBA.BAD_PARAM();
0N/A }
0N/A }
0N/A
0N/A /**
0N/A * Constructs a <code>DefinitionKind</code> object with its <code>_value</code>
0N/A * field initialized with the given value.
0N/A * @param _value one of the <code>int</code> constants defined in the
0N/A * class <code>DefinitionKind</code>
0N/A */
0N/A
0N/A protected DefinitionKind(int _value){
0N/A this._value = _value;
0N/A }
0N/A
0N/A /**
0N/A * The field that holds a value for a <code>DefinitionKind</code> object.
0N/A * @serial
0N/A */
0N/A
0N/A private int _value;
0N/A}