-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathID3v24Frame.java
More file actions
28 lines (22 loc) · 767 Bytes
/
Copy pathID3v24Frame.java
File metadata and controls
28 lines (22 loc) · 767 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
package Mp3File;
public class ID3v24Frame extends ID3v2Frame {
public ID3v24Frame(byte[] buffer, int offset) throws InvalidDataException {
super(buffer, offset);
}
public ID3v24Frame(String id, byte[] data) {
super(id, data);
}
@Override
protected void unpackDataLength(byte[] buffer, int offset) {
dataLength = BufferTools.unpackSynchsafeInteger(buffer[offset + DATA_LENGTH_OFFSET], buffer[offset + DATA_LENGTH_OFFSET + 1], buffer[offset + DATA_LENGTH_OFFSET + 2], buffer[offset + DATA_LENGTH_OFFSET + 3]);
}
@Override
protected byte[] packDataLength() {
return BufferTools.packSynchsafeInteger(dataLength);
}
@Override
public boolean equals(Object obj) {
if (!(obj instanceof ID3v24Frame)) return false;
return super.equals(obj);
}
}