| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
|
| 20 |
|
| 21 |
package com.drew.metadata.mp3; |
| 22 |
|
| 23 |
import com.drew.lang.annotations.NotNull; |
| 24 |
import com.drew.metadata.Directory; |
| 25 |
|
| 26 |
import java.util.HashMap; |
| 27 |
|
| 28 |
|
| 29 |
|
| 30 |
|
| 31 |
public class Mp3Directory extends Directory |
| 32 |
{ |
| 33 |
public static final int TAG_ID = 1; |
| 34 |
public static final int TAG_LAYER = 2; |
| 35 |
public static final int TAG_BITRATE = 3; |
| 36 |
public static final int TAG_FREQUENCY = 4; |
| 37 |
public static final int TAG_MODE = 5; |
| 38 |
public static final int TAG_EMPHASIS = 6; |
| 39 |
public static final int TAG_COPYRIGHT = 7; |
| 40 |
public static final int TAG_FRAME_SIZE = 8; |
| 41 |
|
| 42 |
@NotNull |
| 43 |
private static final HashMap<Integer, String> _tagNameMap = new HashMap<Integer, String>(); |
| 44 |
|
| 45 |
static |
| 46 |
{ |
| 47 |
_tagNameMap.put(TAG_ID, "ID"); |
| 48 |
_tagNameMap.put(TAG_LAYER, "Layer"); |
| 49 |
_tagNameMap.put(TAG_BITRATE, "Bitrate"); |
| 50 |
_tagNameMap.put(TAG_FREQUENCY, "Frequency"); |
| 51 |
_tagNameMap.put(TAG_MODE, "Mode"); |
| 52 |
_tagNameMap.put(TAG_EMPHASIS, "Emphasis Method"); |
| 53 |
_tagNameMap.put(TAG_COPYRIGHT, "Copyright"); |
| 54 |
_tagNameMap.put(TAG_FRAME_SIZE, "Frame Size"); |
| 55 |
} |
| 56 |
|
| 57 |
public Mp3Directory() |
| 58 |
{ |
| 59 |
this.setDescriptor(new Mp3Descriptor(this)); |
| 60 |
} |
| 61 |
|
| 62 |
@NotNull |
| 63 |
@Override |
| 64 |
public String getName() |
| 65 |
{ |
| 66 |
return "MP3"; |
| 67 |
} |
| 68 |
|
| 69 |
@NotNull |
| 70 |
@Override |
| 71 |
protected HashMap<Integer, String> getTagNameMap() |
| 72 |
{ |
| 73 |
return _tagNameMap; |
| 74 |
} |
| 75 |
} |