stream

1.Stream写byte
            String text = "To be or not to be";        // Define a string
            byte[] textArray = text.getBytes();
            for(byte b: textArray)
            {
              System.out.write(b);
            }

 

2.String => byte
String text = "To be or not to be";        // Define a string
byte[] textArray = text.getBytes();

posted @ 2009-12-22 00:08  Fan Zhang  阅读(203)  评论(0)    收藏  举报