14 #include "msdevstudio/MSconfig.h"
50 using namespace hippodraw;
53 :
BaseXML (
"DataRep", controller ),
54 m_contours (
"contours" )
77 const void * addr = reinterpret_cast <
const void * > ( &
rep );
151 if ( binProjector != 0 )
158 if ( functionProjector != 0 )
166 if ( mapMatrixProjector != 0 ) {
178 const void * addr = reinterpret_cast <
const void * > ( target );
194 bool ok = element -> attribute (
m_type, type );
197 if ( type ==
"Z Plot" ) {
222 assert ( ntuple != 0 );
224 vector < string > bindings;
252 if ( element != 0 ) {
259 if ( element != 0 ) {
265 if ( element != 0 ) {
267 assert ( targetelement );
268 int id = targetelement->
getID ();
274 if ( element == 0 ) {
277 if ( element == 0 ) {
291 if ( type ==
"TextDataRep" ) {
295 if ( rep == 0 )
return 0;
298 assert ( pr_element );
XmlElement * createElement()
Creates a new element node.
The BinningProjector is an abstract class provides most of the functionality for a projector that doe...
virtual XmlElement * createElement(const std::string &tagName)=0
Creates a new DOM element wrapper object and returns a pointer to it.
NTupleProjectorXML * m_nTupleProjector
The NTupleProjectorXML instance used by this class.
virtual bool attribute(const std::string &name, bool &value) const =0
Sets value to the attribute name's value.
FunctionProjectorXML class interface.
hippodraw::DataRepXML class interface
const std::string & name() const
Returns the name of the display.
BinningProjectorXML * m_binningProjectorXML
the BinningProjectorXML instance used by this class.
PointRepXML class interface.
virtual void setPointRep(RepBase *pointrep)
Sets the representation of the data points.
XmlDocument class interface.
hippodraw::DataRep * createDataRep(const XmlElement *element)
Creates and returns a DataRep object that does not have NTuple bindings.
XmlController class interface.
FunctionProjectorXML * m_functionProjector
The FunctionProjectorXML instance used by this class.
hippodraw::FunctionController class interface
hippodraw::TextDataRep class interface
hippodraw::BinningProjector class interface
XmlElement * createElement(const RepBase &rep)
Returns a newly created XML element for the RepBase object.
MapMatrixProjectorXML * m_mapMatrixProjectorXML
The MapMatrixProjectorXML instance used by this class.
const XmlElement * getNode(const XmlElement *element) const
Returns the single child node of element of the type that can be handled by this object.
An NTupleProjector is a projector that projects data from an DataSource object.
A pure virtual base class of XML element wrapper.
PointRepXML * m_pointrep
The PointRepXML instance used by this class.
A derived class of DataRep which is a base class for displaying a function.
An class XML doing serialization and deserialization of derived classes of BinningProjector.
An class XML doing serialization and de-serialization of derived classes of MapMatrixProjector.
RepBase * createObject(const XmlElement *element)
Creates an object derived from RepBase from information in the XmlElement.
virtual XmlElement * getNode(const std::string &tagName) const =0
Returns the single direct child element node with name tagName.
hippodraw::DataRep * getTextRepObject(const XmlElement *)
Creates and returns a DataRep object that is a TextDataRep.
virtual int getID() const =0
Returns the ID of the element, if it has one.
hippodraw::MapMatrixProjector class interface
DataRep * createDataRep(const std::string &name)
Creates a new DataRep object of class name.
A singleton class that is does XML serialization and de-serialization of derived classes of RepBase...
DataRep * getTarget() const
Returns the DataRep object upon which the function is applied.
void setId(XmlElement &tag, int id)
Sets the unique identification of the object.
hippodraw::FunctionRep class interface
hippodraw::DataSource class interface.
hippodraw::DataRep * createObject(const XmlElement *element)
Returns a newly created object based on the XmlElement.
PyArray_TYPES type(numeric::array arr)
The base class for data representations.
virtual void appendChild(const XmlNode &child)=0
Appends a child element to the element.
DataRepController class interface.
XmlElement * createElement(const FunctionProjector &projector)
Returns a newly created XmlElement with its attributes set for projector.
DataRepXML(XmlController *)
A constructor taking an XML Controller as argument.
const DataSource * getDataSource(int ref_id)
Returns pointer to data source from the xml reference ID.
A derived class of NTupleProjector that maps 1 DataSource column to a Y axis of two dimensional proje...
A singleton class that is the interface between GUI and the DataRep.
An class XML doing serialization and deserialization of derived classes of NTupleProjector.
virtual bool hasNTupleBindings() const
Returns true if the DataRep's projector can bind to DataSource.
hippodraw::RepBase class interface
XmlController * m_controller
The singleton XML controller object.
XmlElement class interface.
void getObject(const XmlElement *parent, ProjectorBase *projector)
Sets the binning attributes of the projector from child nodes of the parent XML element.
The base class for the Projector hierarchy.
static DataRepController * instance()
Returns the pointer to the singleton instance.
BinningProjectorXML class interface.
static XmlDocument * m_xml_doc
The current document being generated or read.
const std::string m_type
The attribute name for the type of object.
hippodraw::FunctionProjector class interface
An class XML doing serialization and deserialization of derived classes of FunctionProjector.
An xception class that is thrown when attempting to bind a DataRep to a NTuple with a column name tha...
void createFunctionTargetChild(XmlElement &tag, const hippodraw::DataRep &rep)
Creates the child element for the function target.
A base class of XML element controllers.
XmlElement * createElement(const NTupleProjector &projector)
Returns a newly created XML element with its attributes set.
DataRep * getDataRep(int ref)
Returns a pointer to the DataRep from the xml reference Id.
MapMatrixProjectorXML class interface.
void getBindings(const XmlElement *element, std::vector< std::string > &bindings) const
Retreives the bindings to the HiNTuple from the element's data by clearing the list then filling it...
A base class that is the interface between GUI and the XML serialization and deserialization.
~DataRepXML()
The destructor.
hippodraw::NTupleProjectorXML class interface
virtual ProjectorBase * getProjector() const
Returns the Projector object controlling the data.
Displays data in textual representation.
int getNTupleReference(const XmlElement *element) const
Retrieves the reference to the DataSource from the XML elements's data.
void createChildren(XmlElement &tag, const hippodraw::DataRep &rep)
Creates the children elements of this element.
The base class for the point representation hierarchy.
RepBase * getRepresentation() const
Returns the representation used to draw the data points.
hippodraw::PlotterBase class interface.
virtual void setAttribute(const std::string &name, bool value)=0
Sets attribute named name to the int value value.
A projector that plots one function.
Base class for DataSource.