Beispiel #1
0
 /**
  * @param offset
  * @param length
  * @return
  * @throws NSErrorException
  */
 public byte[] getBytes(int offset, int length) throws NSErrorException {
   byte[] bytes = new byte[length];
   NSError.NSErrorPtr err = new NSError.NSErrorPtr();
   getBytes(VM.getArrayValuesAddress(bytes), offset, length, err);
   if (err.get() != null) {
     throw new NSErrorException(err.get());
   }
   return bytes;
 }
Beispiel #2
0
 public MIDIRawData setData(byte[] data) {
   setData0(VM.getArrayValuesAddress(data));
   setLength0(data.length);
   return this;
 }