Examples of XRequestCallback


Examples of com.sun.star.awt.XRequestCallback

                    // the main thread should be accessed asynchronously
                    XMultiComponentFactory xFactory = xContext.getServiceManager();
                    if ( xFactory == null )
                        throw new com.sun.star.uno.RuntimeException();
                   
                    XRequestCallback xRequest = (XRequestCallback)UnoRuntime.queryInterface(
                        XRequestCallback.class,
                        xFactory.createInstanceWithContext( "com.sun.star.awt.AsyncCallback", xContext ) );
                    if ( xRequest != null )
                    {
                        xRequest.addCallback( aExecutor, Any.VOID );
                        do
                        {
                            Thread.yield();
                        }
                        while( !aExecutor.m_bCalled );
View Full Code Here

Examples of com.sun.star.awt.XRequestCallback

    public void getTestObject() {
        try {
            xMSF = (XMultiServiceFactory)param.getMSF();
            SOfficeFactory xSOF = SOfficeFactory.getFactory(xMSF);
           
            XRequestCallback xAsyncCallback = null;
       
            XInterface xIfc = (XInterface)xMSF.createInstance(
                                "com.sun.star.awt.AsyncCallback" );
            xAsyncCallback = (XRequestCallback)
                UnoRuntime.queryInterface(XRequestCallback.class,xIfc);
View Full Code Here

Examples of com.sun.star.awt.XRequestCallback

    }
   
    public void checkCallback() {
        getTestObject();
        log.println("*** Now testing asynchronous callback service ***");
        XRequestCallback xAsyncCallback = null;
        xAsyncCallback = (XRequestCallback)
            UnoRuntime.queryInterface( XRequestCallback.class, testObject );
        CallbackClass aCallbackClass = new CallbackClass( log, xMSF );
        xAsyncCallback.addCallback( aCallbackClass, null );
    }
View Full Code Here

Examples of com.sun.star.awt.XRequestCallback

    public void getTestObject() {
        try {
            xMSF = (XMultiServiceFactory)param.getMSF();
            SOfficeFactory xSOF = SOfficeFactory.getFactory(xMSF);
           
            XRequestCallback xAsyncCallback = null;
       
            XInterface xIfc = (XInterface)xMSF.createInstance(
                                "com.sun.star.awt.AsyncCallback" );
            xAsyncCallback = (XRequestCallback)
                UnoRuntime.queryInterface(XRequestCallback.class,xIfc);
View Full Code Here

Examples of com.sun.star.awt.XRequestCallback

    }
   
    public void checkCallback() {
        getTestObject();
        log.println("*** Now testing asynchronous callback service ***");
        XRequestCallback xAsyncCallback = null;
        xAsyncCallback = (XRequestCallback)
            UnoRuntime.queryInterface( XRequestCallback.class, testObject );
        CallbackClass aCallbackClass = new CallbackClass( log, xMSF );
        xAsyncCallback.addCallback( aCallbackClass, null );
    }
View Full Code Here

Examples of com.sun.star.awt.XRequestCallback

    public void getTestObject() {
        try {
            xMSF = (XMultiServiceFactory)param.getMSF();
            SOfficeFactory xSOF = SOfficeFactory.getFactory(xMSF);
           
            XRequestCallback xAsyncCallback = null;
       
            XInterface xIfc = (XInterface)xMSF.createInstance(
                                "com.sun.star.awt.AsyncCallback" );
            xAsyncCallback = (XRequestCallback)
                UnoRuntime.queryInterface(XRequestCallback.class,xIfc);
View Full Code Here

Examples of com.sun.star.awt.XRequestCallback

                    // the main thread should be accessed asynchronously
                    XMultiComponentFactory xFactory = xContext.getServiceManager();
                    if ( xFactory == null )
                        throw new com.sun.star.uno.RuntimeException();
                   
                    XRequestCallback xRequest = (XRequestCallback)UnoRuntime.queryInterface(
                        XRequestCallback.class,
                        xFactory.createInstanceWithContext( "com.sun.star.awt.AsyncCallback", xContext ) );
                    if ( xRequest != null )
                    {
                        xRequest.addCallback( aExecutor, Any.VOID );
                        do
                        {
                            Thread.yield();
                        }
                        while( !aExecutor.m_bCalled );
View Full Code Here

Examples of com.sun.star.awt.XRequestCallback

        final UITools tools = new UITools(
            (XMultiServiceFactory) tParam.getMSF(),
            UnoRuntime.queryInterface(XWindow.class, mb));
        final boolean[] done = new boolean[] { false };
        final boolean[] good = new boolean[] { false };
        XRequestCallback async = AsyncCallback.create(
            tParam.getComponentContext());
        async.addCallback(
            new XCallback() {
                public void notify(Object aData) {
                    mb.execute();
                    synchronized (done) {
                        done[0] = true;
                        done.notifyAll();
                    }
                }
            },
            Any.VOID);
        async.addCallback(
            new XCallback() {
                public void notify(Object aData) {
                    try {
                        tools.clickButton("OK");
                    } catch (RuntimeException e) {
View Full Code Here

Examples of com.sun.star.awt.XRequestCallback

                    // the main thread should be accessed asynchronously
                    XMultiComponentFactory xFactory = xContext.getServiceManager();
                    if ( xFactory == null )
                        throw new com.sun.star.uno.RuntimeException();
                   
                    XRequestCallback xRequest = (XRequestCallback)UnoRuntime.queryInterface(
                        XRequestCallback.class,
                        xFactory.createInstanceWithContext( "com.sun.star.awt.AsyncCallback", xContext ) );
                    if ( xRequest != null )
                    {
                        xRequest.addCallback( aExecutor, Any.VOID );
                        do
                        {
                            Thread.yield();
                        }
                        while( !aExecutor.m_bCalled );
View Full Code Here

Examples of com.sun.star.awt.XRequestCallback

    public void getTestObject() {
        try {
            xMSF = (XMultiServiceFactory)param.getMSF();
            SOfficeFactory xSOF = SOfficeFactory.getFactory(xMSF);
           
            XRequestCallback xAsyncCallback = null;
       
            XInterface xIfc = (XInterface)xMSF.createInstance(
                                "com.sun.star.awt.AsyncCallback" );
            xAsyncCallback = (XRequestCallback)
                UnoRuntime.queryInterface(XRequestCallback.class,xIfc);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.