<h:dataTable value="#{metobservCharacterizationMassspectrum.spectralPoints.points}" var="specpoint">
<h:column>
<f:facet name="header"><h:outputText value="m/z's"/></f:facet>
<h:outputText value="#{specpoint.mz}"/>
</h:column>
<h:column>
<f:facet name="header"><h:outputText value="Intensities"/></f:facet>
<h:outputText value="#{specpoint.intensity}"/>
</h:column>
</h:dataTable>
The <dataTable> @value point (via the faces-config.xml) to the MetobservCharacterizationMassspectrumBean, which has a getSpectralPoints() method (autocreated from the <skos:Concept> SpectralPoints, which has a convenience method List<SpectralPoint> getPoints().SpectralPoint in turn has the methods getIntensity() and getMz() also used in the above JSF snippet. For convenience, SpectralPointArray also has two other methods: double[] getIntensities() and double[] getMzs() (which I'll have to rename to reuse the code for NMR support :).So, here's the outcome:
Final note, given the dataType, the MetWare bean also has the logic to convert the data back and forth into a SQL serialization, which may eventually use base64 encoding, but currently looks like 61.0,100.0;62.0,1.1, as defined by the regular expression of the XSD dataType for spectralPointArray.
No comments:
Post a Comment