Package com.nomagic.uml2.ext.jmi.reflect
Class AbstractRefPackage
java.lang.Object
com.nomagic.uml2.ext.jmi.reflect.AbstractRefBaseObjectImpl
com.nomagic.uml2.ext.jmi.reflect.AbstractRefPackage
- All Implemented Interfaces:
com.nomagic.uml2.ext.jmi.MapOwner
,AbstractRefBaseObject
,com.nomagic.uml2.ext.jmi.reflect.RepositoryProvider
,javax.jmi.reflect.RefBaseObject
,javax.jmi.reflect.RefPackage
- Direct Known Subclasses:
AbstractRepository
,EcoreRefPackage
public abstract class AbstractRefPackage
extends com.nomagic.uml2.ext.jmi.reflect.AbstractRefBaseObjectImpl
implements javax.jmi.reflect.RefPackage
The RefPackage interface is an abstraction for accessing a collection of
objects and their associations. The interface provides an operation to access
the meta object description for the package, and operations to access the
package instance's class proxy objects and its association objects
-
Field Summary
Fields inherited from class com.nomagic.uml2.ext.jmi.reflect.AbstractRefBaseObjectImpl
mMetaObject, repository
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addAssociation
(String name, javax.jmi.reflect.RefAssociation assoc) void
void
addPackage
(String name, javax.jmi.reflect.RefBaseObject pack) void
internalError
(String string, javax.jmi.reflect.InvalidCallException ex) The refAllAssociation operation returns all associations directly contained by this package.The refAllClasses operation returns all class proxies directly contained by this package.Returns a (possible empty) collection of RefPackages directly contained by this package.javax.jmi.reflect.RefAssociation
refAssociation
(String associationName) The association (or associationName ) parameter should designate the (M2) association whose association object is to be returned.javax.jmi.reflect.RefAssociation
refAssociation
(javax.jmi.reflect.RefObject association) javax.jmi.reflect.RefClass
The type (or className ) parameter should designate the class whose class proxy object is to be returned.javax.jmi.reflect.RefClass
refClass
(javax.jmi.reflect.RefObject type) javax.jmi.reflect.RefStruct
refCreateStruct
(String structName, List args) The refCreateStruct operation creates an instance of a struct data type defined by the metaobject structType (or structName ) whose attribute values are specified by the ordered collection args .javax.jmi.reflect.RefStruct
refCreateStruct
(javax.jmi.reflect.RefObject structType, List name) void
The "refDelete" operation destroys this package, including the objects it contains directly or transitively.javax.jmi.reflect.RefEnum
refGetEnum
(String enumName, String args) The refGetEnum operation returns the instance of an enumeration (i.e., an enumeration literal) whose value is described by the value of literalName .javax.jmi.reflect.RefEnum
refGetEnum
(javax.jmi.reflect.RefObject enumType, String args) javax.jmi.reflect.RefPackage
refPackage
(String nestedPackageName) The "nestedPackage" (or nestedPackageName ) parameter should designate the package whose package object is to be returned.javax.jmi.reflect.RefPackage
refPackage
(javax.jmi.reflect.RefObject nestedPackage) void
removeClass
(com.nomagic.uml2.ext.jmi.reflect.AbstractRefClass clazz) void
removePackage
(javax.jmi.reflect.RefBaseObject pack) Methods inherited from class com.nomagic.uml2.ext.jmi.reflect.AbstractRefBaseObjectImpl
getRepository, mapClear, mapPut, mapPutAll, mapRemove, mof_getRepository, refImmediatePackage, refMetaObject, refMofId, refOutermostPackage, refVerifyConstraints, setMofID, setOwner, setRefMetaObject, setRepository
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface javax.jmi.reflect.RefBaseObject
equals, hashCode, refImmediatePackage, refMetaObject, refMofId, refOutermostPackage, refVerifyConstraints
-
Constructor Details
-
AbstractRefPackage
- Parameters:
repository
-
-
-
Method Details
-
addAssociation
- Parameters:
name
-assoc
-
-
refAllAssociations
The refAllAssociation operation returns all associations directly contained by this package. Returns a (possible empty) collection of RefAssociations directly contained by this package.- Specified by:
refAllAssociations
in interfacejavax.jmi.reflect.RefPackage
-
refAllClasses
The refAllClasses operation returns all class proxies directly contained by this package. Returns a (possible empty) collection of RefClasses directly contained by this package.- Specified by:
refAllClasses
in interfacejavax.jmi.reflect.RefPackage
-
refAssociation
public javax.jmi.reflect.RefAssociation refAssociation(javax.jmi.reflect.RefObject association) - Specified by:
refAssociation
in interfacejavax.jmi.reflect.RefPackage
-
refAssociation
The association (or associationName ) parameter should designate the (M2) association whose association object is to be returned. The refAssociation operations return an association object for a given association. specific analog: get() return type: RefAssociation isQuery: yes parameters: RefObject association (or String associationName) exceptions: JmiException (InvalidCallException, InvalidNameException) - Specified by:
refAssociation
in interfacejavax.jmi.reflect.RefPackage
-
refClass
public javax.jmi.reflect.RefClass refClass(javax.jmi.reflect.RefObject type) - Specified by:
refClass
in interfacejavax.jmi.reflect.RefPackage
-
refClass
The type (or className ) parameter should designate the class whose class proxy object is to be returned. InvalidCallException is raised if the type parameter does not designate a valid class. InvalidNameException is raised when the className does not denote a valid class name. The refClass operations return the class proxy object for a given class. specific analog: get() return type: RefClass isQuery: yes parameters: RefObject type (or String className) exceptions: JmiException (InvalidCallException, InvalidNameException) - Specified by:
refClass
in interfacejavax.jmi.reflect.RefPackage
-
refCreateStruct
public javax.jmi.reflect.RefStruct refCreateStruct(javax.jmi.reflect.RefObject structType, List name) - Specified by:
refCreateStruct
in interfacejavax.jmi.reflect.RefPackage
-
refCreateStruct
The refCreateStruct operation creates an instance of a struct data type defined by the metaobject structType (or structName ) whose attribute values are specified by the ordered collection args . The members of the args list correspond 1-to-1 to the parameters for the specific create operation. They must be encoded as per Generation Rules for Parameters on page 56. InvalidCallException is raised if the structType parameter does not designate a struct type. InvalidNameException is raised when the structName does not denote a valid struct name. This refCreateStruct operations create a new instance of a struct data type. specific analog: create(...); return type: RefStruct parameters: RefObject structType (or String structName), List args exceptions: JmiException (WrongSizeException, TypeMismatchException, InvalidObjectException, InvalidCallException, InvalidNameException, java.lang.NullPointerException) - Specified by:
refCreateStruct
in interfacejavax.jmi.reflect.RefPackage
-
refDelete
public void refDelete()The "refDelete" operation destroys this package, including the objects it contains directly or transitively. Deletion of an outermost package causes all objects within its extent to be deleted.- Specified by:
refDelete
in interfacejavax.jmi.reflect.RefPackage
-
refGetEnum
- Specified by:
refGetEnum
in interfacejavax.jmi.reflect.RefPackage
-
refGetEnum
The refGetEnum operation returns the instance of an enumeration (i.e., an enumeration literal) whose value is described by the value of literalName . Note that the type of enumeration is defined by the meta object that owns the metaLiteral object. InvalidCallException is raised if the enumType parameter does not designate a valid enumeration. InvalidNameException is raised when the enumName does not denote a valid enum name. This refGetEnum returns the enumeration object representing the enumeration literal. specific analog: none. return type: RefEnum parameters: RefObject enumType (or String enumName ) String literalName exceptions: JmiException (TypeMismatchException, InvalidCallException, InvalidNameException, java.lang.NullPointerException)- Specified by:
refGetEnum
in interfacejavax.jmi.reflect.RefPackage
-
refPackage
public javax.jmi.reflect.RefPackage refPackage(javax.jmi.reflect.RefObject nestedPackage) - Specified by:
refPackage
in interfacejavax.jmi.reflect.RefPackage
-
refPackage
The "nestedPackage" (or nestedPackageName ) parameter should designate the package whose package object is to be returned. It must either be nested within the package for this package object, or imported with isCluster set to true. InvalidCallException is raised if the nestedPackage parameter does not designate a valid package. InvalidNameException is raised when the nestedPackageName does not denote a valid nested package name. The refPackage operations return a package object for a nested or clustered package. specific analog: get() return type: RefPackage isQuery: yes parameters: RefObject nestedPackage (or String nestedPackageName) exceptions: JmiException (InvalidCallException, InvalidNameException) - Specified by:
refPackage
in interfacejavax.jmi.reflect.RefPackage
-
internalError
- Parameters:
string
-ex
-
-
getMetaObjects
- Returns:
-
addClass
- Parameters:
name
-clazz
-
-
removeClass
public void removeClass(com.nomagic.uml2.ext.jmi.reflect.AbstractRefClass clazz) -
addPackage
- Parameters:
string
-basicBehaviorsPackage2
-
-
removePackage
public void removePackage(javax.jmi.reflect.RefBaseObject pack) -
refAllPackages
Returns a (possible empty) collection of RefPackages directly contained by this package. The Collection returned from this operation is an immutable collection. The refAllPackages operation returns all packages directly contained or clustered by this package. specific analog: None return type: Collection of RefPackages isQuery: yes parameters: None exceptions: JmiException- Specified by:
refAllPackages
in interfacejavax.jmi.reflect.RefPackage
-