P2PWNC
Class B64Data

java.lang.Object
  extended byP2PWNC.B64Data

public class B64Data
extends java.lang.Object

This class represents a byte array together with its length. It is being used internally in Base-64 operations, mainly as a return value.

Version:
0.0.1
Author:
Pantelis Frangoudis, Elias Efstathiou

Field Summary
protected  byte[] data
          The byte array holding the actual data.
protected  int datalen
          Length of the data byte array.
 
Constructor Summary
B64Data(byte[] data, int datalen)
          Constructs a new B64Data object.
 
Method Summary
 byte[] getData()
          Returns the "data" field.
 int getDatalen()
          Returns the "datalen" field.
 void setData(byte[] data)
          Sets the object's "data" field to "data"
 void setDatalen(int datalen)
          Sets the object's "datalen" field to "datalen"
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

data

protected byte[] data
The byte array holding the actual data.


datalen

protected int datalen
Length of the data byte array.

Constructor Detail

B64Data

public B64Data(byte[] data,
               int datalen)
Constructs a new B64Data object.

Parameters:
data - byte[] The "data" contents.
datalen - int The lenght of the data.
Method Detail

getData

public byte[] getData()
Returns the "data" field.

Returns:
byte[]

getDatalen

public int getDatalen()
Returns the "datalen" field.

Returns:
int

setData

public void setData(byte[] data)
Sets the object's "data" field to "data"

Parameters:
data - byte[]

setDatalen

public void setDatalen(int datalen)
Sets the object's "datalen" field to "datalen"

Parameters:
datalen - int