CMS 3D CMS Logo

Public Member Functions | Private Attributes

ora::Query< Tp > Class Template Reference

#include <QueryableVector.h>

List of all members.

Public Member Functions

template<typename Prim >
void addSelection (const std::string &dataMemberName, SelectionItemType stype, Prim selectionData)
size_t count ()
Range< Tp > execute ()
Queryoperator= (const Query< Tp > &rhs)
 Query (const Query< Tp > &rhs)
 Query (boost::shared_ptr< IVectorLoader > &loader)
virtual ~Query ()

Private Attributes

boost::shared_ptr< IVectorLoaderm_loader
Selection m_selection

Detailed Description

template<typename Tp>
class ora::Query< Tp >

Definition at line 142 of file QueryableVector.h.


Constructor & Destructor Documentation

template<typename Tp>
ora::Query< Tp >::Query ( boost::shared_ptr< IVectorLoader > &  loader) [explicit]
template<class Tp >
ora::Query< Tp >::Query ( const Query< Tp > &  rhs)

Definition at line 163 of file QueryableVectorImpl.h.

                                       :
  m_selection( rhs.m_selection),
  m_loader( rhs.m_loader ){
}
template<typename Tp>
virtual ora::Query< Tp >::~Query ( ) [inline, virtual]

Definition at line 150 of file QueryableVector.h.


Member Function Documentation

template<class Tp >
template<typename Prim >
void ora::Query< Tp >::addSelection ( const std::string &  dataMemberName,
ora::SelectionItemType  stype,
Prim  selectionData 
)

Definition at line 176 of file QueryableVectorImpl.h.

                                                                                                                                       {
  m_selection.addDataItem(dataMemberName, stype, selectionData);
}
template<class Tp >
size_t ora::Query< Tp >::count ( void  )

Definition at line 180 of file QueryableVectorImpl.h.

                                              {
  return m_loader->getSelectionCount( m_selection );
}
template<class Tp >
ora::Range< Tp > ora::Query< Tp >::execute ( )

Definition at line 184 of file QueryableVectorImpl.h.

                                                      {
  typedef typename Range<Tp>::store_base_type range_store_base_type;
  boost::shared_ptr<range_store_base_type> newData ( new range_store_base_type );
  m_loader->loadSelection( m_selection, newData.get());
  return Range<Tp>( newData );
}
template<class Tp >
ora::Query< Tp > & ora::Query< Tp >::operator= ( const Query< Tp > &  rhs)

Definition at line 169 of file QueryableVectorImpl.h.

References ora::Query< Tp >::m_loader, and ora::Query< Tp >::m_selection.

                                                            {
  m_selection = rhs.m_selection;
  m_loader = rhs.m_loader;
  return *this;
}

Member Data Documentation

template<typename Tp>
boost::shared_ptr<IVectorLoader> ora::Query< Tp >::m_loader [private]

Definition at line 161 of file QueryableVector.h.

Referenced by ora::Query< Tp >::operator=().

template<typename Tp>
Selection ora::Query< Tp >::m_selection [private]

Definition at line 160 of file QueryableVector.h.

Referenced by ora::Query< Tp >::operator=().