This documentation differs from the official API. Jadeite adds extra features to the API including: variable font sizes, constructions examples, placeholders for classes and methods, and auto-generated “See Also” links. Additionally it is missing some items found in standard Javadoc documentation, including: generics type information, “Deprecated” tags and comments, “See Also” links, along with other minor differences. Please send any questions or feedback to bam@cs.cmu.edu.


com.sun.mail.iap
class ByteArray

com.sun.mail.iap.ByteArray

public class ByteArray
extends Object

A simple wrapper around a byte array, with a start position and count of bytes.


Constructor Summary
ByteArray(byte[] b, int start, int count)

          Constructor
ByteArray(int size)

          Constructor that creates a byte array of the specified size.
 
Method Summary
 byte[]

          Returns the internal byte array.
 int

          Returns the count of bytes
 byte[]

          Returns a new byte array that is a copy of the data.
 int

          Returns the start position
 void
grow(int incr)

          Grow the byte array by incr bytes.
 void
setCount(int count)

          Set the count of bytes.
 ByteArrayInputStream

          Returns a ByteArrayInputStream.
 

Constructor Detail

ByteArray

public ByteArray(byte[] b,
                 int start,
                 int count)
Constructor

Parameters:
b
start
count

ByteArray

public ByteArray(int size)
Constructor that creates a byte array of the specified size.

Parameters:
size
Method Detail

getBytes

public byte[] getBytes()
Returns the internal byte array. Note that this is a live reference to the actual data, not a copy.


getCount

public int getCount()
Returns the count of bytes


getNewBytes

public byte[] getNewBytes()
Returns a new byte array that is a copy of the data.


getStart

public int getStart()
Returns the start position


grow

public void grow(int incr)
Grow the byte array by incr bytes.

Parameters:
incr

setCount

public void setCount(int count)
Set the count of bytes.

Parameters:
count

toByteArrayInputStream

public ByteArrayInputStream toByteArrayInputStream()
Returns a ByteArrayInputStream.



This documentation differs from the official API. Jadeite adds extra features to the API including: variable font sizes, constructions examples, placeholders for classes and methods, and auto-generated “See Also” links. Additionally it is missing some items found in standard Javadoc documentation, including: generics type information, “Deprecated” tags and comments, “See Also” links, along with other minor differences. Please send any questions or feedback to bam@cs.cmu.edu.
This page displays the Jadeite version of the documention. The official Sun™ documentation can be found here at http://java.sun.com/products/javamail/javadocs/index.html.