ch.uzh.ifi.attempto.preditor.example
Class ExampleMenuCreator

java.lang.Object
  extended by ch.uzh.ifi.attempto.preditor.MenuCreator
      extended by ch.uzh.ifi.attempto.preditor.example.ExampleMenuCreator

public class ExampleMenuCreator
extends MenuCreator

This class is an examplary implementation of a menu creator. See the source code.

Author:
Tobias Kuhn

Constructor Summary
ExampleMenuCreator()
          Creates a new menu creator instance.
 
Method Summary
 void addMenuItems(Restriction restriction)
          An implementation of this abstract method should add menu items that comply with the given restriction.
 void initMenuCreation()
          This abstract method is called when the predictive editor is refreshed (before the first call of addMenuItems).
 
Methods inherited from class ch.uzh.ifi.attempto.preditor.MenuCreator
addMenuEntry, addMenuItem, addVariableEntries, prepareMenuBlock, prepareMenuBlock
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ExampleMenuCreator

public ExampleMenuCreator()
Creates a new menu creator instance.

Method Detail

initMenuCreation

public void initMenuCreation()
Description copied from class: MenuCreator
This abstract method is called when the predictive editor is refreshed (before the first call of addMenuItems). This is a good place for calling prepareMenuBlock.

Specified by:
initMenuCreation in class MenuCreator

addMenuItems

public void addMenuItems(Restriction restriction)
Description copied from class: MenuCreator
An implementation of this abstract method should add menu items that comply with the given restriction. This should be done by calling addMenuItem and/or addMenuEntry.

Specified by:
addMenuItems in class MenuCreator
Parameters:
restriction - The restriction for the menu items.


Copyright 2008-2009, Attempto Group, University of Zurich (see http://attempto.ifi.uzh.ch)