Class CompoundType.Method

java.lang.Object
org.glassfish.rmic.iiop.CompoundType.Method
All Implemented Interfaces:
Cloneable, ContextElement
Enclosing class:
CompoundType

public class CompoundType.Method extends Object implements ContextElement, Cloneable
A CompoundType.Method object encapsulates IIOP-specific information about a particular method in the interface represented by the outer instance.
  • Constructor Details

  • Method Details

    • isInherited

      public boolean isInherited()
      Is this method inherited?
    • isAttribute

      public boolean isAttribute()
      Is this method an attribute? Return true if getAttributeKind != ATTRIBUTE_NONE.
    • isReadWriteAttribute

      public boolean isReadWriteAttribute()
      Is this method a read-write attribute?
    • getAttributeKind

      public int getAttributeKind()
      Return the attribute kind.
    • getAttributeName

      public String getAttributeName()
      Return the attribute name. Will be null if attribute kind == ATTRIBUTE_NONE.
    • getAttributePairIndex

      public int getAttributePairIndex()
      For kinds ATTRIBUTE_GET_RW or ATTRIBUTE_IS_RW, return the index of the matching ATTRIBUTE_SET method, and vice-versa. For all other cases, return -1.
    • getElementName

      public String getElementName()
      Return context element name.
      Specified by:
      getElementName in interface ContextElement
    • equals

      public boolean equals(Object obj)
      Equality check based on method signature.
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • mergeWith

      public CompoundType.Method mergeWith(CompoundType.Method other)
      Return a new Method object that is a legal combination of this method object and another one. This requires determining the exceptions declared by the combined method, which must be only those exceptions that may thrown by both of the old methods.
    • getEnclosing

      public CompoundType getEnclosing()
      Return the compound type which contains this method.
    • getDeclaredBy

      public Identifier getDeclaredBy()
      Return the identifier for the class or interface which declares this method.
    • getVisibility

      public String getVisibility()
      Return the visibility (e.g. "public final") of this member.
    • isPublic

      public boolean isPublic()
      Methods to check various attributes.
    • isProtected

      public boolean isProtected()
    • isPrivate

      public boolean isPrivate()
    • isStatic

      public boolean isStatic()
    • getName

      public String getName()
      Return the name of this method.
    • getIDLName

      public String getIDLName()
      IDL_Naming Return the IDL name of this method.
    • getType

      public Type getType()
      Return the type of this method.
    • isConstructor

      public boolean isConstructor()
      Return true if this is a constructor.
    • isNormalMethod

      public boolean isNormalMethod()
      Return true if this is NOT a constructor && is not an attribute.
    • getReturnType

      public Type getReturnType()
      Get the return type of this method. May be null.
    • getArguments

      public Type[] getArguments()
      Return the argument types of this method.
    • getArgumentNames

      public String[] getArgumentNames()
      Return the names of the argument types of this method.
    • getMemberDefinition

      public MemberDefinition getMemberDefinition()
      Return the MemberDefinition from which this method was created.
    • getExceptions

      public ValueType[] getExceptions()
      Return an array of the exception classes declared to be thrown by this remote method. For methods with the same name and type signature inherited from multiple remote interfaces, the array will contain the set of exceptions declared in all of the interfaces' methods that can be legally thrown in each of them.
    • getImplExceptions

      public ValueType[] getImplExceptions()
      Same as getExceptions(), except when method is in an ImplementationType and the exceptions list is narrower.
    • getUniqueCatchList

      public ValueType[] getUniqueCatchList(ValueType[] list)
      Return an array containing only those exceptions which need to be caught. Removes java.rmi.RemoteException, java.lang.RuntimeException, java.lang.Error, and their subclasses, then removes any exceptions which are more derived than another in the list. Returns null if no exceptions need to be caught.
    • getFilteredStubExceptions

      public ValueType[] getFilteredStubExceptions(ValueType[] list)
      Return an array containing only those exceptions which need to be handled explicitly by the stub. Removes java.lang.RuntimeException, java.lang.Error, and their subclasses, since these are all passed back as CORBA system exceptions. Also removes subclasses of java.rmi.RemoteException but not java.rmi.RemoteException itself, since this may need to be thrown by the stub.
    • toString

      public String toString()
      Return the string representation of this method.
      Overrides:
      toString in class Object
    • setAttributeKind

      public void setAttributeKind(int kind)
      Set attribute kind. May only be called during initialization.
    • setAttributePairIndex

      public void setAttributePairIndex(int index)
      Set pair index. May only be called during initialization.
    • setAttributeName

      public void setAttributeName(String name)
      Set attribute name. May only be called during initialization.
    • setIDLName

      public void setIDLName(String idlName)
      Set the idl name. May only be called during initialization.
    • setImplExceptions

      public void setImplExceptions(ValueType[] exceptions)
      Set the implExceptions array. May only be called during initialization.
    • setDeclaredBy

      public void setDeclaredBy(Identifier by)
      Set the declaredBy Identifier. May only be called during initialization.
    • swapInvalidTypes

      protected void swapInvalidTypes()
      Convert all invalid types to valid ones.
    • destroy

      public void destroy()
      Release all resources.
    • clone

      protected Object clone()
      Cloning is supported by returning a shallow copy of this object.
      Overrides:
      clone in class Object