Examples of Wait()


Examples of java.awt.Button.wait()

                public void run() {
                    event.dispatch();
                }
            }.start();
            try {
                button.wait(1000);
            } catch (InterruptedException e) {
                e.printStackTrace();
            }
        }
        assertTrue(runnableCalled);

Examples of java.awt.Frame.wait()

                        }
                    }
                });
                synchronized (f) {
                    try {
                        f.wait();
                    } catch (InterruptedException e1) {
                    }
                }
            }
            System.exit(1);

Examples of java.awt.event.ComponentListener.wait()

        listener.reset();
        ComponentListener compListener = addComponentListener(component);
        ancestor.add(component);
        waitForIdle();
        synchronized (compListener) {
            compListener.wait(1000);
        }
        assertTrue(listener.getNumEvents() >= 1);
        performChecksInQueue(component, ancestor, AncestorEvent.ANCESTOR_ADDED);
    }

Examples of java.awt.event.FocusListener.wait()

        SwingUtilities.invokeAndWait(thread);
        if (!thread.result) {
            return false;
        }
        synchronized (listener) {
            listener.wait(maxWaitTime);
        }
        waitForIdle();
        if (!c.isFocusOwner()) {
            fail();
        }

Examples of java.io.ByteArrayOutputStream.wait()

                                    {
                                        out.notify();
                                    }
                                    synchronized (out)
                                    {
                                        out.wait();
                                        out.reset();
                                    }
                                }
                            }
                        }

Examples of java.io.File.wait()

    }
    // Make sure that the dd2spring generated file exists
    File generatedFile = new File(contextFiles[0]);
    while (!generatedFile.exists()) {
      synchronized (generatedFile) {
        generatedFile.wait(500);
      }
    }
    System.out
        .println("ManagedUimaService initialized - ready to process. Agent State Update endpoint:"
            + agentStateUpdateEndpoint);

Examples of java.io.PrintStream.wait()

                {
                    synchronized ( projectStream )
                    {
                        try
                        {
                            projectStream.wait( 100 );
                        }
                        catch ( InterruptedException e )
                        {
                            throw new RuntimeException( e );
                        }

Examples of java.net.ServerSocket.wait()

    config.portString = "65431";
    fetcher.init();
   
    synchronized (server) {
      server.start();
      server.wait();
    }
    NumericRangeList value = (NumericRangeList) fetcher.scan(new ScanningSubject(InetAddress.getLocalHost()));
    assertEquals(config.portString, value.toString());
   
    fetcher.cleanup();

Examples of java.net.Socket.wait()

                    }
                };
                t.setDaemon(true);
                t.start();
                synchronized (sock) {
                    sock.wait(timeout * 1000);
                    sock.close();
                }
            }
            System.out.println("...done. Exiting.");
        } catch (Exception e) {

Examples of java.nio.channels.FileChannel.wait()

                while (fileLength != l) {
                    fileLength += fc.transferTo(fileLength, l, target);
                    if (fileLength != l) {
                        logger.info("Waiting for writing...");
                        try {
                            fc.wait(1000);
                        } catch (InterruptedException e) {
                            logger.trace(e.getMessage(), e);
                        }
                    }
                }
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.