1package com.coremedia.iso.boxes.apple;
2
3import java.util.HashMap;
4import java.util.Map;
5
6/**
7 * itunes MetaData comment box.
8 */
9public class AppleMediaTypeBox extends AbstractAppleMetaDataBox {
10    private static Map<String, String> mediaTypes = new HashMap<String, String>();
11
12    static {
13        mediaTypes.put("0", "Movie (is now 9)");
14        mediaTypes.put("1", "Normal (Music)");
15        mediaTypes.put("2", "Audiobook");
16        mediaTypes.put("6", "Music Video");
17        mediaTypes.put("9", "Movie");
18        mediaTypes.put("10", "TV Show");
19        mediaTypes.put("11", "Booklet");
20        mediaTypes.put("14", "Ringtone");
21    }
22
23    public static final String TYPE = "stik";
24
25
26    public AppleMediaTypeBox() {
27        super(TYPE);
28        appleDataBox = AppleDataBox.getUint8AppleDataBox();
29    }
30
31    public String getReadableValue() {
32        if (mediaTypes.containsKey(getValue())) {
33            return mediaTypes.get(getValue());
34        } else {
35            return "unknown media type " + getValue();
36        }
37
38    }
39}