public interface ScreenManager<T extends GameScreen> extends GameResizeListener
GameScreens and Transitions between them| Modifier and Type | Method and Description | 
|---|---|
| void | addGameScreen(T screen)Adds a  GameScreento this manager | 
| void | enterGameScreen(int id,
               Transition transitionOut,
               Transition transitionIn)Begins a transition to a new  GameScreen | 
| T | getGameScreen(int id)Returns the  GameScreenwith the given id | 
| java.util.Iterator<T> | getGameScreens()Returns an  Iteratorover all the game screens | 
| void | interpolate(GameContainer gc,
           float alpha)Interpolate between the previous and current state | 
| boolean | isTransitioning()Returns if the  ScreenManageris moving betweenScreens | 
| void | onPause() | 
| void | onResume() | 
| void | render(GameContainer gc,
      Graphics g)Renders the current  GameScreenand anyTransitionthat
 may be occurring | 
| void | update(GameContainer gc,
      float delta)Updates the current  GameScreenand anyTransitionthat
 may be occurring | 
onResizevoid update(GameContainer gc, float delta)
GameScreen and any Transition that
 may be occurringgc - The GameContainer that is updating this
            ScreenManagerdelta - The time since the last updatevoid interpolate(GameContainer gc, float alpha)
alpha - The interpolation alpha valuevoid render(GameContainer gc, Graphics g)
GameScreen and any Transition that
 may be occurringgc - The GameContainer that is rendering this
            ScreenManagerg - The Graphics context available for renderingvoid onPause()
void onResume()
void enterGameScreen(int id,
                     Transition transitionOut,
                     Transition transitionIn)
GameScreenid - The id of the GameScreen to transition totransitionOut - The outgoing Transition, e.g. fade outtransitionIn - The incoming Transition, e.g. fade invoid addGameScreen(T screen)
GameScreen to this managerscreen - The GameScreen to be addedT getGameScreen(int id)
GameScreen with the given idid - The id to search forGameScreen registered with this
         managerboolean isTransitioning()
ScreenManager is moving between ScreensTransitions activejava.util.Iterator<T> getGameScreens()
Iterator over all the game screens