Package limelight.io

Examples of limelight.io.StreamReader


    checkSettingImageDataWith("star.wbm");
  }

  private void checkSettingImageDataWith(String imageFile) throws Exception
  {
    StreamReader reader = new StreamReader(TestUtil.fs.inputStream(TestUtil.dataDirPath(imageFile)));
    byte[] bytes = reader.readBytes(100000);

    panel.setData(bytes);

    assertEquals(200, panel.getImage().getHeight(null));
    assertEquals(200, panel.getImage().getWidth(null));
View Full Code Here


  }

  public static void writeSamplePlayerTo(OutputStream outputStream) throws IOException
  {
    final String playerClassFile = TestUtil.dataDirPath("SamplePlayer.class");
    StreamReader reader = new StreamReader(TestUtil.fs.inputStream(playerClassFile));
    final byte[] classBytes = reader.readAllBytes();
    reader.close();
    outputStream.write(classBytes);
    outputStream.close();
  }
View Full Code Here

  protected Class<?> findClass(String name) throws ClassNotFoundException
  {
    String path = classpath + "/" + name.replace('.', '/') + ".class";
    if(Context.fs().exists(path))
    {
      StreamReader reader = new StreamReader(Context.fs().inputStream(path));
      byte[] classBytes = reader.readAllBytes();
      reader.close();
      return defineClass(name, classBytes, 0, classBytes.length);
    }
    else
      throw new ClassNotFoundException(name);
  }
View Full Code Here

TOP

Related Classes of limelight.io.StreamReader

Copyright © 2018 www.massapicom. 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.