org.omg.CORBA.portable.ObjectImpl Java Examples

The following examples show how to use org.omg.CORBA.portable.ObjectImpl. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: StubAdapter.java    From openjdk-8-source with GNU General Public License v2.0 6 votes vote down vote up
/** Given any Tie, return the corresponding object refernce, activating
 * the Servant if necessary.
 */
public static org.omg.CORBA.Object activateTie( Tie tie )
{
    /** Any implementation of Tie should be either a Servant or an ObjectImpl,
     * depending on which style of code generation is used.  rmic -iiop by
     * default results in an ObjectImpl-based Tie, while rmic -iiop -poa
     * results in a Servant-based Tie.  Dynamic RMI-IIOP also uses Servant-based
     * Ties (see impl.presentation.rmi.ReflectiveTie).
     */
    if (tie instanceof ObjectImpl) {
        return tie.thisObject() ;
    } else if (tie instanceof Servant) {
        Servant servant = (Servant)tie ;
        return activateServant( servant ) ;
    } else {
        throw wrapper.badActivateTieCall() ;
    }
}
 
Example #2
Source File: StubAdapter.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 6 votes vote down vote up
/** Given any Tie, return the corresponding object refernce, activating
 * the Servant if necessary.
 */
public static org.omg.CORBA.Object activateTie( Tie tie )
{
    /** Any implementation of Tie should be either a Servant or an ObjectImpl,
     * depending on which style of code generation is used.  rmic -iiop by
     * default results in an ObjectImpl-based Tie, while rmic -iiop -poa
     * results in a Servant-based Tie.  Dynamic RMI-IIOP also uses Servant-based
     * Ties (see impl.presentation.rmi.ReflectiveTie).
     */
    if (tie instanceof ObjectImpl) {
        return tie.thisObject() ;
    } else if (tie instanceof Servant) {
        Servant servant = (Servant)tie ;
        return activateServant( servant ) ;
    } else {
        throw wrapper.badActivateTieCall() ;
    }
}
 
Example #3
Source File: StubAdapter.java    From jdk8u60 with GNU General Public License v2.0 6 votes vote down vote up
/** Given any Tie, return the corresponding object refernce, activating
 * the Servant if necessary.
 */
public static org.omg.CORBA.Object activateTie( Tie tie )
{
    /** Any implementation of Tie should be either a Servant or an ObjectImpl,
     * depending on which style of code generation is used.  rmic -iiop by
     * default results in an ObjectImpl-based Tie, while rmic -iiop -poa
     * results in a Servant-based Tie.  Dynamic RMI-IIOP also uses Servant-based
     * Ties (see impl.presentation.rmi.ReflectiveTie).
     */
    if (tie instanceof ObjectImpl) {
        return tie.thisObject() ;
    } else if (tie instanceof Servant) {
        Servant servant = (Servant)tie ;
        return activateServant( servant ) ;
    } else {
        throw wrapper.badActivateTieCall() ;
    }
}
 
Example #4
Source File: StubAdapter.java    From TencentKona-8 with GNU General Public License v2.0 6 votes vote down vote up
/** Given any Tie, return the corresponding object refernce, activating
 * the Servant if necessary.
 */
public static org.omg.CORBA.Object activateTie( Tie tie )
{
    /** Any implementation of Tie should be either a Servant or an ObjectImpl,
     * depending on which style of code generation is used.  rmic -iiop by
     * default results in an ObjectImpl-based Tie, while rmic -iiop -poa
     * results in a Servant-based Tie.  Dynamic RMI-IIOP also uses Servant-based
     * Ties (see impl.presentation.rmi.ReflectiveTie).
     */
    if (tie instanceof ObjectImpl) {
        return tie.thisObject() ;
    } else if (tie instanceof Servant) {
        Servant servant = (Servant)tie ;
        return activateServant( servant ) ;
    } else {
        throw wrapper.badActivateTieCall() ;
    }
}
 
Example #5
Source File: StubAdapter.java    From JDKSourceCode1.8 with MIT License 6 votes vote down vote up
/** Given any Tie, return the corresponding object refernce, activating
 * the Servant if necessary.
 */
public static org.omg.CORBA.Object activateTie( Tie tie )
{
    /** Any implementation of Tie should be either a Servant or an ObjectImpl,
     * depending on which style of code generation is used.  rmic -iiop by
     * default results in an ObjectImpl-based Tie, while rmic -iiop -poa
     * results in a Servant-based Tie.  Dynamic RMI-IIOP also uses Servant-based
     * Ties (see impl.presentation.rmi.ReflectiveTie).
     */
    if (tie instanceof ObjectImpl) {
        return tie.thisObject() ;
    } else if (tie instanceof Servant) {
        Servant servant = (Servant)tie ;
        return activateServant( servant ) ;
    } else {
        throw wrapper.badActivateTieCall() ;
    }
}
 
Example #6
Source File: StubAdapter.java    From openjdk-jdk8u with GNU General Public License v2.0 6 votes vote down vote up
/** Given any Tie, return the corresponding object refernce, activating
 * the Servant if necessary.
 */
public static org.omg.CORBA.Object activateTie( Tie tie )
{
    /** Any implementation of Tie should be either a Servant or an ObjectImpl,
     * depending on which style of code generation is used.  rmic -iiop by
     * default results in an ObjectImpl-based Tie, while rmic -iiop -poa
     * results in a Servant-based Tie.  Dynamic RMI-IIOP also uses Servant-based
     * Ties (see impl.presentation.rmi.ReflectiveTie).
     */
    if (tie instanceof ObjectImpl) {
        return tie.thisObject() ;
    } else if (tie instanceof Servant) {
        Servant servant = (Servant)tie ;
        return activateServant( servant ) ;
    } else {
        throw wrapper.badActivateTieCall() ;
    }
}
 
Example #7
Source File: StubAdapter.java    From jdk1.8-source-analysis with Apache License 2.0 6 votes vote down vote up
/** Given any Tie, return the corresponding object refernce, activating
 * the Servant if necessary.
 */
public static org.omg.CORBA.Object activateTie( Tie tie )
{
    /** Any implementation of Tie should be either a Servant or an ObjectImpl,
     * depending on which style of code generation is used.  rmic -iiop by
     * default results in an ObjectImpl-based Tie, while rmic -iiop -poa
     * results in a Servant-based Tie.  Dynamic RMI-IIOP also uses Servant-based
     * Ties (see impl.presentation.rmi.ReflectiveTie).
     */
    if (tie instanceof ObjectImpl) {
        return tie.thisObject() ;
    } else if (tie instanceof Servant) {
        Servant servant = (Servant)tie ;
        return activateServant( servant ) ;
    } else {
        throw wrapper.badActivateTieCall() ;
    }
}
 
Example #8
Source File: StubAdapter.java    From openjdk-8 with GNU General Public License v2.0 6 votes vote down vote up
/** Given any Tie, return the corresponding object refernce, activating
 * the Servant if necessary.
 */
public static org.omg.CORBA.Object activateTie( Tie tie )
{
    /** Any implementation of Tie should be either a Servant or an ObjectImpl,
     * depending on which style of code generation is used.  rmic -iiop by
     * default results in an ObjectImpl-based Tie, while rmic -iiop -poa
     * results in a Servant-based Tie.  Dynamic RMI-IIOP also uses Servant-based
     * Ties (see impl.presentation.rmi.ReflectiveTie).
     */
    if (tie instanceof ObjectImpl) {
        return tie.thisObject() ;
    } else if (tie instanceof Servant) {
        Servant servant = (Servant)tie ;
        return activateServant( servant ) ;
    } else {
        throw wrapper.badActivateTieCall() ;
    }
}
 
Example #9
Source File: StubAdapter.java    From hottub with GNU General Public License v2.0 5 votes vote down vote up
public static void connect( Object stub,
    ORB orb ) throws java.rmi.RemoteException
{
    if (stub instanceof DynamicStub)
        ((DynamicStub)stub).connect(
            (com.sun.corba.se.spi.orb.ORB)orb ) ;
    else if (stub instanceof javax.rmi.CORBA.Stub)
        ((javax.rmi.CORBA.Stub)stub).connect( orb ) ;
    else if (stub instanceof ObjectImpl)
        orb.connect( (org.omg.CORBA.Object)stub ) ;
    else
        throw wrapper.connectRequiresStub() ;
}
 
Example #10
Source File: StubAdapter.java    From hottub with GNU General Public License v2.0 5 votes vote down vote up
public static String[] getTypeIds( Object stub )
{
    if (stub instanceof DynamicStub)
        return ((DynamicStub)stub).getTypeIds() ;
    else if (stub instanceof ObjectImpl)
        return ((ObjectImpl)stub)._ids() ;
    else
        throw wrapper.getTypeIdsRequiresStub() ;
}
 
Example #11
Source File: StubAdapter.java    From openjdk-8-source with GNU General Public License v2.0 5 votes vote down vote up
/** This also gets the delegate from a Servant by
 * using Servant._this_object()
 */
public static Delegate getDelegate( Object stub )
{
    if (stub instanceof DynamicStub)
        return ((DynamicStub)stub).getDelegate() ;
    else if (stub instanceof ObjectImpl)
        return ((ObjectImpl)stub)._get_delegate() ;
    else if (stub instanceof Tie) {
        Tie tie = (Tie)stub ;
        org.omg.CORBA.Object ref = activateTie( tie ) ;
        return getDelegate( ref ) ;
    } else
        throw wrapper.getDelegateRequiresStub() ;
}
 
Example #12
Source File: StubAdapter.java    From JDKSourceCode1.8 with MIT License 5 votes vote down vote up
public static OutputStream request( Object stub,
    String operation, boolean responseExpected )
{
    if (stub instanceof DynamicStub)
        return ((DynamicStub)stub).request( operation,
            responseExpected ) ;
    else if (stub instanceof ObjectImpl)
        return ((ObjectImpl)stub)._request( operation,
            responseExpected ) ;
    else
        throw wrapper.requestRequiresStub() ;
}
 
Example #13
Source File: StubAdapter.java    From hottub with GNU General Public License v2.0 5 votes vote down vote up
public static void setDelegate( Object stub, Delegate delegate )
{
    if (stub instanceof DynamicStub)
        ((DynamicStub)stub).setDelegate( delegate ) ;
    else if (stub instanceof ObjectImpl)
        ((ObjectImpl)stub)._set_delegate( delegate ) ;
    else
        throw wrapper.setDelegateRequiresStub() ;
}
 
Example #14
Source File: StubAdapter.java    From openjdk-jdk9 with GNU General Public License v2.0 5 votes vote down vote up
public static OutputStream request( Object stub,
    String operation, boolean responseExpected )
{
    if (stub instanceof DynamicStub)
        return ((DynamicStub)stub).request( operation,
            responseExpected ) ;
    else if (stub instanceof ObjectImpl)
        return ((ObjectImpl)stub)._request( operation,
            responseExpected ) ;
    else
        throw wrapper.requestRequiresStub() ;
}
 
Example #15
Source File: StubAdapter.java    From openjdk-jdk9 with GNU General Public License v2.0 5 votes vote down vote up
public static boolean isLocal( Object stub )
{
    if (stub instanceof DynamicStub)
        return ((DynamicStub)stub).isLocal() ;
    else if (stub instanceof ObjectImpl)
        return ((ObjectImpl)stub)._is_local() ;
    else
        throw wrapper.isLocalRequiresStub() ;
}
 
Example #16
Source File: StubAdapter.java    From hottub with GNU General Public License v2.0 5 votes vote down vote up
/** This also gets the delegate from a Servant by
 * using Servant._this_object()
 */
public static Delegate getDelegate( Object stub )
{
    if (stub instanceof DynamicStub)
        return ((DynamicStub)stub).getDelegate() ;
    else if (stub instanceof ObjectImpl)
        return ((ObjectImpl)stub)._get_delegate() ;
    else if (stub instanceof Tie) {
        Tie tie = (Tie)stub ;
        org.omg.CORBA.Object ref = activateTie( tie ) ;
        return getDelegate( ref ) ;
    } else
        throw wrapper.getDelegateRequiresStub() ;
}
 
Example #17
Source File: StubAdapter.java    From openjdk-8 with GNU General Public License v2.0 5 votes vote down vote up
public static void connect( Object stub,
    ORB orb ) throws java.rmi.RemoteException
{
    if (stub instanceof DynamicStub)
        ((DynamicStub)stub).connect(
            (com.sun.corba.se.spi.orb.ORB)orb ) ;
    else if (stub instanceof javax.rmi.CORBA.Stub)
        ((javax.rmi.CORBA.Stub)stub).connect( orb ) ;
    else if (stub instanceof ObjectImpl)
        orb.connect( (org.omg.CORBA.Object)stub ) ;
    else
        throw wrapper.connectRequiresStub() ;
}
 
Example #18
Source File: StubAdapter.java    From openjdk-jdk9 with GNU General Public License v2.0 5 votes vote down vote up
public static void connect( Object stub,
    ORB orb ) throws java.rmi.RemoteException
{
    if (stub instanceof DynamicStub)
        ((DynamicStub)stub).connect(
            (com.sun.corba.se.spi.orb.ORB)orb ) ;
    else if (stub instanceof javax.rmi.CORBA.Stub)
        ((javax.rmi.CORBA.Stub)stub).connect( orb ) ;
    else if (stub instanceof ObjectImpl)
        orb.connect( (org.omg.CORBA.Object)stub ) ;
    else
        throw wrapper.connectRequiresStub() ;
}
 
Example #19
Source File: StubAdapter.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 5 votes vote down vote up
public static ORB getORB( Object stub )
{
    if (stub instanceof DynamicStub)
        return ((DynamicStub)stub).getORB() ;
    else if (stub instanceof ObjectImpl)
        return (ORB)((ObjectImpl)stub)._orb() ;
    else
        throw wrapper.getOrbRequiresStub() ;
}
 
Example #20
Source File: StubAdapter.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 5 votes vote down vote up
/** This also gets the delegate from a Servant by
 * using Servant._this_object()
 */
public static Delegate getDelegate( Object stub )
{
    if (stub instanceof DynamicStub)
        return ((DynamicStub)stub).getDelegate() ;
    else if (stub instanceof ObjectImpl)
        return ((ObjectImpl)stub)._get_delegate() ;
    else if (stub instanceof Tie) {
        Tie tie = (Tie)stub ;
        org.omg.CORBA.Object ref = activateTie( tie ) ;
        return getDelegate( ref ) ;
    } else
        throw wrapper.getDelegateRequiresStub() ;
}
 
Example #21
Source File: StubAdapter.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 5 votes vote down vote up
public static void setDelegate( Object stub, Delegate delegate )
{
    if (stub instanceof DynamicStub)
        ((DynamicStub)stub).setDelegate( delegate ) ;
    else if (stub instanceof ObjectImpl)
        ((ObjectImpl)stub)._set_delegate( delegate ) ;
    else
        throw wrapper.setDelegateRequiresStub() ;
}
 
Example #22
Source File: StubAdapter.java    From openjdk-8 with GNU General Public License v2.0 5 votes vote down vote up
public static ORB getORB( Object stub )
{
    if (stub instanceof DynamicStub)
        return ((DynamicStub)stub).getORB() ;
    else if (stub instanceof ObjectImpl)
        return (ORB)((ObjectImpl)stub)._orb() ;
    else
        throw wrapper.getOrbRequiresStub() ;
}
 
Example #23
Source File: StubAdapter.java    From openjdk-jdk8u with GNU General Public License v2.0 5 votes vote down vote up
public static OutputStream request( Object stub,
    String operation, boolean responseExpected )
{
    if (stub instanceof DynamicStub)
        return ((DynamicStub)stub).request( operation,
            responseExpected ) ;
    else if (stub instanceof ObjectImpl)
        return ((ObjectImpl)stub)._request( operation,
            responseExpected ) ;
    else
        throw wrapper.requestRequiresStub() ;
}
 
Example #24
Source File: StubAdapter.java    From openjdk-jdk8u with GNU General Public License v2.0 5 votes vote down vote up
public static boolean isLocal( Object stub )
{
    if (stub instanceof DynamicStub)
        return ((DynamicStub)stub).isLocal() ;
    else if (stub instanceof ObjectImpl)
        return ((ObjectImpl)stub)._is_local() ;
    else
        throw wrapper.isLocalRequiresStub() ;
}
 
Example #25
Source File: StubAdapter.java    From openjdk-jdk8u with GNU General Public License v2.0 5 votes vote down vote up
public static void connect( Object stub,
    ORB orb ) throws java.rmi.RemoteException
{
    if (stub instanceof DynamicStub)
        ((DynamicStub)stub).connect(
            (com.sun.corba.se.spi.orb.ORB)orb ) ;
    else if (stub instanceof javax.rmi.CORBA.Stub)
        ((javax.rmi.CORBA.Stub)stub).connect( orb ) ;
    else if (stub instanceof ObjectImpl)
        orb.connect( (org.omg.CORBA.Object)stub ) ;
    else
        throw wrapper.connectRequiresStub() ;
}
 
Example #26
Source File: StubAdapter.java    From openjdk-jdk8u with GNU General Public License v2.0 5 votes vote down vote up
public static String[] getTypeIds( Object stub )
{
    if (stub instanceof DynamicStub)
        return ((DynamicStub)stub).getTypeIds() ;
    else if (stub instanceof ObjectImpl)
        return ((ObjectImpl)stub)._ids() ;
    else
        throw wrapper.getTypeIdsRequiresStub() ;
}
 
Example #27
Source File: StubAdapter.java    From openjdk-jdk8u with GNU General Public License v2.0 5 votes vote down vote up
public static ORB getORB( Object stub )
{
    if (stub instanceof DynamicStub)
        return ((DynamicStub)stub).getORB() ;
    else if (stub instanceof ObjectImpl)
        return (ORB)((ObjectImpl)stub)._orb() ;
    else
        throw wrapper.getOrbRequiresStub() ;
}
 
Example #28
Source File: StubAdapter.java    From openjdk-jdk8u with GNU General Public License v2.0 5 votes vote down vote up
/** This also gets the delegate from a Servant by
 * using Servant._this_object()
 */
public static Delegate getDelegate( Object stub )
{
    if (stub instanceof DynamicStub)
        return ((DynamicStub)stub).getDelegate() ;
    else if (stub instanceof ObjectImpl)
        return ((ObjectImpl)stub)._get_delegate() ;
    else if (stub instanceof Tie) {
        Tie tie = (Tie)stub ;
        org.omg.CORBA.Object ref = activateTie( tie ) ;
        return getDelegate( ref ) ;
    } else
        throw wrapper.getDelegateRequiresStub() ;
}
 
Example #29
Source File: StubAdapter.java    From openjdk-jdk8u with GNU General Public License v2.0 5 votes vote down vote up
public static void setDelegate( Object stub, Delegate delegate )
{
    if (stub instanceof DynamicStub)
        ((DynamicStub)stub).setDelegate( delegate ) ;
    else if (stub instanceof ObjectImpl)
        ((ObjectImpl)stub)._set_delegate( delegate ) ;
    else
        throw wrapper.setDelegateRequiresStub() ;
}
 
Example #30
Source File: StubAdapter.java    From openjdk-8 with GNU General Public License v2.0 5 votes vote down vote up
public static void setDelegate( Object stub, Delegate delegate )
{
    if (stub instanceof DynamicStub)
        ((DynamicStub)stub).setDelegate( delegate ) ;
    else if (stub instanceof ObjectImpl)
        ((ObjectImpl)stub)._set_delegate( delegate ) ;
    else
        throw wrapper.setDelegateRequiresStub() ;
}