Code example for Vector

Methods: size, toArray

0
	/** 
	 * Get the packets contained in this bundle. 
	 * @return an array of packets 
	 */ 
	public OSCPacket[] getPackets() { 
		OSCPacket[] packetArray = new OSCPacket[packets.size()];
		packets.toArray(packetArray);
		return packetArray;
	} 
 
	/** 
	 * Convert the timetag (a Java Date) into the OSC byte stream. Used Internally. 
	 */ 
	protected void computeTimeTagByteArray(OSCJavaToByteArrayConverter stream) {
		if ((null == timestamp) || (timestamp == TIMESTAMP_IMMEDIATE)) {
			stream.write((int) 0);
			stream.write((int) 1);
			return; 
		} 
		 
		long millisecs = timestamp.getTime();