1. package org.omg.PortableServer;
  2. /**
  3. * org/omg/PortableServer/IdAssignmentPolicyValue.java .
  4. * Generated by the IDL-to-Java compiler (portable), version "3.1"
  5. * from ../../../../src/share/classes/org/omg/PortableServer/poa.idl
  6. * Monday, February 23, 2004 7:03:01 AM GMT
  7. */
  8. /**
  9. * The IdAssignmentPolicyValue can have the following
  10. * values. USER_ID - Objects created with that POA are
  11. * assigned Object Ids only by the application.
  12. * SYSTEM_ID - Objects created with that POA are
  13. * assigned Object Ids only by the POA. If the POA also
  14. * has the PERSISTENT policy, assigned Object Ids must
  15. * be unique across all instantiations of the same POA.
  16. */
  17. public class IdAssignmentPolicyValue implements org.omg.CORBA.portable.IDLEntity
  18. {
  19. private int __value;
  20. private static int __size = 2;
  21. private static org.omg.PortableServer.IdAssignmentPolicyValue[] __array = new org.omg.PortableServer.IdAssignmentPolicyValue [__size];
  22. public static final int _USER_ID = 0;
  23. public static final org.omg.PortableServer.IdAssignmentPolicyValue USER_ID = new org.omg.PortableServer.IdAssignmentPolicyValue(_USER_ID);
  24. public static final int _SYSTEM_ID = 1;
  25. public static final org.omg.PortableServer.IdAssignmentPolicyValue SYSTEM_ID = new org.omg.PortableServer.IdAssignmentPolicyValue(_SYSTEM_ID);
  26. public int value ()
  27. {
  28. return __value;
  29. }
  30. public static org.omg.PortableServer.IdAssignmentPolicyValue from_int (int value)
  31. {
  32. if (value >= 0 && value < __size)
  33. return __array[value];
  34. else
  35. throw new org.omg.CORBA.BAD_PARAM ();
  36. }
  37. protected IdAssignmentPolicyValue (int value)
  38. {
  39. __value = value;
  40. __array[__value] = this;
  41. }
  42. } // class IdAssignmentPolicyValue