ch.elca.el4j.services.monitoring.jmx.display
Class HtmlDisplayManager

java.lang.Object
  extended by ch.elca.el4j.services.monitoring.jmx.display.HtmlDisplayManager
All Implemented Interfaces:
DisplayManager

public class HtmlDisplayManager
extends Object
implements DisplayManager

Utility for displaying HTML information and creating strings out of it.

Author:
David Bernhard (DBD)
File-location:
HtmlDisplayManager
Last check-in date:
2009-08-04 14:35:53 +0200 (Di, 04. Aug 2009) by swismer for revision 3875

Constructor Summary
HtmlDisplayManager()
          Default constructor.
 
Method Summary
 void addSection(Section section)
          Adds a section.
 String getPage()
          
 void setTitle(String title)
          Sets the tile of the page to display.
static String tag(String tag, String value)
          Wrap some text in a tag.
static String tagRecursive(String value, String... tags)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HtmlDisplayManager

public HtmlDisplayManager()
Default constructor.

Method Detail

setTitle

public void setTitle(String title)
Sets the tile of the page to display.

Specified by:
setTitle in interface DisplayManager
Parameters:
title - The title.

addSection

public void addSection(Section section)
Adds a section.

Specified by:
addSection in interface DisplayManager
Parameters:
section - The section to add.

getPage

public String getPage()

Specified by:
getPage in interface DisplayManager
Returns:
The page generated from the added content.

tag

public static String tag(String tag,
                         String value)
Wrap some text in a tag.

Parameters:
tag - The tag to wrap in.
value - The text.
Returns:
<tag>text</tag>

tagRecursive

public static String tagRecursive(String value,
                                  String... tags)
Parameters:
value - The text.
tags - A list of tags.
Returns:
the text wrapped recursively in the tags.


Copyright © 2005-2011 ELCA. All Rights Reserved.