public T simonTypeImg ( SimonType simonType , String rootPath ) throws IOException { String image = null ; switch ( simonType ) { case COUNTER : image = "TypeCounter.png" ; break ; case STOPWATCH : image = "TypeStopwatch.png" ; break ; case UNKNOWN : image = "TypeUnknown.png" ; break ; } String label = simonType . name ( ) . toLowerCase ( ) ; doBegin ( "img" , null , label + " icon" ) ; attr ( "src" , rootPath + "resource/images/" + image ) ; attr ( "alt" , label ) ; writer . write ( " />" ) ; return ( T ) this ; }
Icon image representing Simon Type .