Lines Matching defs:data

33  * should be stored in the data array of a <code>SysexMessage</code> as
35 * message data bytes, and finally the end-of-exclusive flag (0xF7).
37 * the length of the system exclusive data plus two: one byte for the status
47 * When Java Sound is used to handle system exclusive data that is being received
48 * using MIDI wire protocol, it should place the data in one or more
49 * <code>SysexMessages</code>. In this case, the length of the system exclusive data
50 * is not known in advance; the end of the system exclusive data is marked by an
56 * The first <code>SysexMessage</code> object containing data for a particular system
58 * the system exclusive data
60 * Otherwise, additional system exclusive data should be sent in one or more
62 * containing the last of the data for the system exclusive message should end with the
65 * If system exclusive data from <code>SysexMessages</code> objects is being transmitted
67 * data itself, and the final 0xF7 (EOX) byte should be propagated; any 0xF7 status
69 * exclusive data should not be propagated via MIDI wire protocol.
101 * The data bytes for this system exclusive message. These are
105 //protected byte[] data = null;
118 // Default sysex message data: SOX followed by EOX
119 data[0] = (byte) (SYSTEM_EXCLUSIVE & 0xFF);
120 data[1] = (byte) (ShortMessage.END_OF_EXCLUSIVE & 0xFF);
124 * Constructs a new {@code SysexMessage} and sets the data for
125 * the message. The first byte of the data array must be a valid system
130 * @param data the system exclusive message data including the status byte
131 * @param length the length of the valid message data in the array,
133 * or equal to {@code data.length}
141 public SysexMessage(byte[] data, int length)
144 setMessage(data, length);
148 * Constructs a new {@code SysexMessage} and sets the data for the message.
154 * @param data the system exclusive message data (without the status byte)
155 * @param length the length of the valid message data in the array;
157 * {@code data.length}
165 public SysexMessage(int status, byte[] data, int length)
168 setMessage(status, data, length);
174 * @param data an array of bytes containing the complete message.
175 * The message data may be changed using the <code>setMessage</code>
179 protected SysexMessage(byte[] data) {
180 super(data);
185 * Sets the data for the system exclusive message. The
186 * first byte of the data array must be a valid system
188 * @param data the system exclusive message data
189 * @param length the length of the valid message data in
192 public void setMessage(byte[] data, int length) throws InvalidMidiDataException {
193 int status = (data[0] & 0xFF);
197 super.setMessage(data, length);
202 * Sets the data for the system exclusive message.
204 * @param data the system exclusive message data
205 * @param length the length of the valid message data in
208 public void setMessage(int status, byte[] data, int length) throws InvalidMidiDataException {
212 if (length < 0 || length > data.length) {
217 if (this.data==null || this.data.length < this.length) {
218 this.data = new byte[this.length];
221 this.data[0] = (byte) (status & 0xFF);
223 System.arraycopy(data, 0, this.data, 1, length);
229 * Obtains a copy of the data for the system exclusive message.
231 * @return array containing the system exclusive message data.
235 System.arraycopy(data, 1, returnedArray, 0, (length - 1));
247 System.arraycopy(data, 0, newData, 0, newData.length);