1 /* 2 * Copyright 2008 CoreMedia AG, Hamburg 3 * 4 * Licensed under the Apache License, Version 2.0 (the License); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an AS IS BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17 package com.coremedia.iso.boxes; 18 19 import com.googlecode.mp4parser.AbstractContainerBox; 20 21 /** 22 * This box contains all the objects that declare characteristic information of the media in the track. 23 */ 24 public class MediaInformationBox extends AbstractContainerBox { 25 public static final String TYPE = "minf"; 26 MediaInformationBox()27 public MediaInformationBox() { 28 super(TYPE); 29 } 30 getSampleTableBox()31 public SampleTableBox getSampleTableBox() { 32 for (Box box : boxes) { 33 if (box instanceof SampleTableBox) { 34 return (SampleTableBox) box; 35 } 36 } 37 return null; 38 } 39 getMediaHeaderBox()40 public AbstractMediaHeaderBox getMediaHeaderBox() { 41 for (Box box : boxes) { 42 if (box instanceof AbstractMediaHeaderBox) { 43 return (AbstractMediaHeaderBox) box; 44 } 45 } 46 return null; 47 } 48 49 } 50