| Home >> All >> javax >> ide >> menu >> [ spi Javadoc ] |
Source code: javax/ide/menu/spi/SectionContainer.java
1 package javax.ide.menu.spi; 2 3 import java.util.List; 4 5 /** 6 * Section Container is a container of sections. This corresponds to the 7 * sectionContainerType schema type. 8 */ 9 public class SectionContainer extends Positionable 10 { 11 private final PositionMap _sections = new PositionMap(); 12 13 public SectionContainer( String id ) 14 { 15 super( id ); 16 } 17 18 void addSection( Section section ) 19 { 20 _sections.add( section ); 21 } 22 23 /** 24 * Get the sections in this container. 25 * 26 * @return a Collection of Section instances. 27 */ 28 public List getSections() 29 { 30 return _sections.getSortedItems(); 31 } 32 33 public Section getSection(String id) 34 { 35 return (Section)_sections.get(id); 36 } 37 }