Examples of available()


Examples of java.util.zip.ZipInputStream.available()

    if (debug)
      System.out.println("RAConfig.extractFromJAR(" + fileName +  "," + reader + ")");

    ZipInputStream stream = new ZipInputStream(reader);
    ZipEntry currEntry = stream.getNextEntry();
    while (stream.available() > 0) {
      if (currEntry == null) break;
      if (currEntry.getName().equalsIgnoreCase(fileName)) {
        // the fileName is found, return the InputStream.
        if (debug)
          System.out.println("RAConfig.extractFromJAR : currEntry = " + currEntry);
View Full Code Here

Examples of javax.mail.util.SharedFileInputStream.available()

            out.flush();
            out.close();
           
            tmpMsgIn = new SharedFileInputStream(file);
          
            final int size = tmpMsgIn.available();
            final int bodyStartOctet = bodyStartOctet(tmpMsgIn);

            // Disable line length... This should be handled by the smtp server component and not the parser itself
            // https://issues.apache.org/jira/browse/IMAP-122
            MimeEntityConfig config = new MimeEntityConfig();
View Full Code Here

Examples of javax.servlet.ServletInputStream.available()

                                HttpMessage msg = exchange.getIn(HttpMessage.class);

                                ServletInputStream sis = HttpConverter.toServletInputStream(msg);
                                assertNotNull(sis);
                                // The ServletInputStream should be cached and you can't read message here
                                assertTrue(sis.available() == 0);                               
                                String s = msg.getBody(String.class);

                                assertEquals("Hello World", s);
                            }
                        }).transform(constant("Bye World"));
View Full Code Here

Examples of javax.sound.sampled.AudioInputStream.available()

    {
      InputStream fin = new BufferedInputStream(new FileInputStream(filename));
      AudioInputStream in= AudioSystem.getAudioInputStream(fin);   
      dumpAudioInputStream(in,out,fin.toString());
      assertEquals("FrameLength",-1,in.getFrameLength());     
      assertEquals("Available",Integer.parseInt((String)props.getProperty("Available")),in.available());     
      fin.close();
      in.close();
    }
    catch (UnsupportedAudioFileException e)
    {
View Full Code Here

Examples of javax.tools.diagnostics.vm.spi.delegates.HProfMBeanDumpDelegate.available()

    }

    // Sun Hotspot HProf MBean
    DumpInitiatorDelegate mbeanDump = new HProfMBeanDumpDelegate();
   
    if (mbeanDump.available()) {
      addInitiator(mbeanDump);
    }
   
       
    addInitiator(new JavaDumpDelegate());
View Full Code Here

Examples of lev.LInChannel.available()

                }
                LInChannel input = new LInChannel(ini);

                String line = "";
                // First line
                while (input.available() > 0 && !line.toUpperCase().contains("SRESOURCEARCHIVELIST")) {
                    line = input.extractLine();
                }
                if (line.toUpperCase().contains("SRESOURCEARCHIVELIST2")) {
                    line2 = true;
                    resources.addAll(processINIline(line));
View Full Code Here

Examples of net.bnubot.core.BNetInputStream.available()

          String ValueStr = is.readNTString();
         
          recieveInfo("MPQ: " + MPQFileName);
       
          byte extraData[] = null;
          if(is.available() == 0x80) {
            extraData = new byte[0x80];
            is.read(extraData, 0, 0x80);
          }
          assert(is.available() == 0);
         
View Full Code Here

Examples of net.bnubot.util.BNetInputStream.available()

        byte[] valueStr = is.readNTBytes();

        Out.debug(getClass(), "MPQ: " + mpqFileName);

        byte extraData[] = null;
        if (is.available() == 0x80) {
          extraData = new byte[0x80];
          is.read(extraData, 0, 0x80);
        }
        assert (is.available() == 0);
View Full Code Here

Examples of net.sourceforge.chaperon.process.extended.CharBuffer.available()

  public void testCharBuffer()
  {
    CharBuffer buffer = new CharBuffer();

    assertTrue("Test if read is not possible", !buffer.available());

    char[] chars1 = "abcde".toCharArray();
    buffer.push(chars1, 1, 3)// "bcd"

    assertTrue("Test if read is possible", buffer.available());
View Full Code Here

Examples of net.yura.lobby.util.ByteBufferInputStream.available()

//                byte[] bytes = new byte[ buf.remaining() ];
//                buf.get(bytes);
//                data.addBytes(bytes);
                ByteBufferInputStream data = new ByteBufferInputStream(buf);
                while (true) {
                    if (size==-1 && data.available() >= 4) {
                        size = data.readInt();
                    }
                    else if (size>=0 && data.available() >= size) {
                        Message message = (Message)access.load(data, size);
                        size = -1;
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.