Class ria.template.DefaultTemplate


Extends ria.template.Template.
A DefaultTemplate formats an arbitrary object into an HTML table with one row for each property of the object. The first column of each row contains the property name and the second column contains the property value. String, number, or boolean data types are rendered as the appropriate string value, whilst any other data types, as well as undefined or null values, are rendered as an empty string. To support CSS styling, elements are equipped with certain CSS classes. The table element has the class defaultTemplate, every <td> element containing a property name has the class name and every <td> element containing a property value has the class value.

Method Summary
Method Attributes Method Name and Description
format(obj)
Formats the given object into an HTML table.
Method Detail
{String} format(obj)
Formats the given object into an HTML table.
Parameters:
{Object} obj
Object to format
Returns:
{String} HTML string generated from the given object