Package com.ribs.datasource
Class RMDataSource
- java.lang.Object
- 
- com.ribs.datasource.RMDataSource
 
- 
- Direct Known Subclasses:
- DataSetDataSource,- RMDataSourceGoogle,- RMDataSourceJDBC,- RMDataSourceXML
 
 public class RMDataSource extends java.lang.ObjectThis class is used as a proxy for objects passed to document's generateReport() method. It provides schema information of the object graph (in the form of RMEntity and RMProperty objects) and it provides sample data (probably in the form of Java Collections and core types: List, Map, String, Number, Date).
- 
- 
Constructor SummaryConstructors Constructor Description RMDataSource()Creates a plain datasource.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.ObjectfromXML(RXArchiver anArchiver, RXElement anElement)XML unarchival.java.util.MapgetDataset()Returns a sample dataset of objects associated with the datasource.RMEntitygetEntity(java.lang.String aKeyPath)Returns the entity at the given key path.java.lang.StringgetError()Returns the last error encountered when loading a datasource.java.lang.StringgetName()Returns the name for the datasource.RMPropertygetRelation(java.lang.String aKeyPath)Returns the relation at the given key path.RMSchemagetSchema()Returns the schema of represented datasource as a heirarchy of RMEntity and RMProperty objects.voidsetName(java.lang.String aName)Sets the name for the datasource.java.lang.StringtoString()Returns a string representation of the datasource (just its name).RXElementtoXML(RXArchiver anArchiver)XML archival.
 
- 
- 
- 
Method Detail- 
getNamepublic java.lang.String getName() Returns the name for the datasource.
 - 
setNamepublic void setName(java.lang.String aName) Sets the name for the datasource.
 - 
getSchemapublic RMSchema getSchema() Returns the schema of represented datasource as a heirarchy of RMEntity and RMProperty objects.
 - 
getDatasetpublic java.util.Map getDataset() Returns a sample dataset of objects associated with the datasource.
 - 
getErrorpublic java.lang.String getError() Returns the last error encountered when loading a datasource.
 - 
getEntitypublic RMEntity getEntity(java.lang.String aKeyPath) Returns the entity at the given key path.
 - 
getRelationpublic RMProperty getRelation(java.lang.String aKeyPath) Returns the relation at the given key path.
 - 
toStringpublic java.lang.String toString() Returns a string representation of the datasource (just its name).- Overrides:
- toStringin class- java.lang.Object
 
 - 
toXMLpublic RXElement toXML(RXArchiver anArchiver) XML archival.
 - 
fromXMLpublic java.lang.Object fromXML(RXArchiver anArchiver, RXElement anElement) XML unarchival.
 
- 
 
-