I am pretty new to JSF and I am trying to make a datatable which will show some properties (first column will contain the names of the properties and the second column their values). Property types may vary (String, Long, URI,Calendar etc.).
What I want to do is, if the property type is eg. String, long, boolean, etc to output property's value as plain text (using outputText) but if it is URI or Reference(this is a custom type) to view it as a link.
This is my current JSF page (shows everything as plain text):
<p:dataTable var="property"
value="#{myBean.properties()}" >
<p:column headerText="Property" >
#{property}
</p:column>
<p:column headerText="Value">
<h:outputText value="#{myBean.property(property)}"/>
</p:column>
</p:dataTable>
Thank you!