com.hdcookbook.grin.io.builders
Class MenuAssemblyHelper

java.lang.Object
  extended by com.hdcookbook.grin.io.builders.MenuAssemblyHelper

public class MenuAssemblyHelper
extends java.lang.Object

This class builds the menu_assembly feature. A menu_assembly is turned into a normal Assembly, with a bunch of anonymous groups. Please refer to the BNF in the main GRIN documentation to see a syntax for this.

Here's how it works: A menu_assembly specifies a set of "default" features. Then, it specifies the "parts" of the assembly. Each part specifies the part name, and specifies which features of the default set are to be swapped out for that part, and what they're to be replaced with.


Nested Class Summary
static class MenuAssemblyHelper.Features
          This data holder class specifies a set of features within a MenuAssembly
 
Field Summary
 SEAssembly assembly
           
 int lineNumber
           
 java.util.List<java.lang.String> partNames
           
 java.util.List<java.util.List<MenuAssemblyHelper.Features>> parts
           
 SEShow show
           
 java.util.List<MenuAssemblyHelper.Features> template
           
 
Constructor Summary
MenuAssemblyHelper()
           
 
Method Summary
 java.lang.Iterable<Feature> setupAssembly()
          Setup the assembly.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

show

public SEShow show

template

public java.util.List<MenuAssemblyHelper.Features> template

partNames

public java.util.List<java.lang.String> partNames

parts

public java.util.List<java.util.List<MenuAssemblyHelper.Features>> parts

assembly

public SEAssembly assembly

lineNumber

public int lineNumber
Constructor Detail

MenuAssemblyHelper

public MenuAssemblyHelper()
Method Detail

setupAssembly

public java.lang.Iterable<Feature> setupAssembly()
                                          throws java.io.IOException
Setup the assembly.

Returns:
the synthetic features that were created. These need to be added to the show by the caller.
Throws:
java.io.IOException