#include <Iguana/Framework/interface/IgCollection.h>
Public Member Functions | |
template<class T> | |
T & | current (void) |
int | currentColumn () |
int | currentRow () |
template<class T> | |
T & | get (IgProperty &property) |
template<class T> | |
T & | get (const char *label) |
IgCollectionItem (IgCollection *collection, int position) | |
IgCollectionItem & | moveToColumn (const IgColumnHandle &handle) |
IgCollectionItem & | nextColumn (void) |
IgCollectionItem & | operator * (void) |
operator IgRef () const | |
template<class T, class A, template< typename, typename > class C> | |
IgCollectionItem & | operator, (C< T, A > container) |
IgCollectionItem & | operator, (const std::string &value) |
IgCollectionItem & | operator, (const char *value) |
template<class T> | |
IgCollectionItem & | operator, (T value) |
template<class T, class A, template< typename, typename > class C> | |
IgCollectionItem & | operator= (C< T, A > container) |
IgCollectionItem & | operator= (const char *value) |
IgCollectionItem & | operator= (const std::string &value) |
template<class T> | |
IgCollectionItem & | operator= (T value) |
IgCollectionItem & | operator[] (const char *label) |
IgCollectionItem & | operator[] (IgProperty &property) |
template<class T> | |
void | set (const char *label, T value) |
template<class T> | |
void | set (IgProperty &property, T value) |
void | stream (std::ostream &stream) |
Private Member Functions | |
IgColumnHandle & | currentHandle () |
Private Attributes | |
IgCollection * | m_collection |
unsigned int | m_position |
unsigned int | m_propertyPosition |
Classes | |
struct | ContainerTraits |
Definition at line 739 of file IgCollection.h.
IgCollectionItem::IgCollectionItem | ( | IgCollection * | collection, | |
int | position | |||
) | [inline] |
Definition at line 742 of file IgCollection.h.
00743 :m_collection(collection), m_position(position), m_propertyPosition(0) 00744 { 00745 }
T& IgCollectionItem::current | ( | void | ) | [inline] |
Definition at line 781 of file IgCollection.h.
References currentHandle(), IgColumnHandle::get(), and m_position.
00782 { 00783 return currentHandle().get<T>(m_position); 00784 }
int IgCollectionItem::currentColumn | ( | ) | [inline] |
Definition at line 747 of file IgCollection.h.
References m_propertyPosition.
00748 { 00749 return m_propertyPosition; 00750 }
IgColumnHandle& IgCollectionItem::currentHandle | ( | ) | [inline, private] |
Definition at line 921 of file IgCollection.h.
References IgCollection::getHandleByPosition(), m_collection, and m_propertyPosition.
Referenced by current(), operator,(), and operator=().
00922 { 00923 return m_collection->getHandleByPosition(m_propertyPosition); 00924 }
int IgCollectionItem::currentRow | ( | ) | [inline] |
Definition at line 752 of file IgCollection.h.
References m_position.
00753 { 00754 return m_position; 00755 }
T& IgCollectionItem::get | ( | IgProperty & | property | ) | [inline] |
Definition at line 866 of file IgCollection.h.
References m_position.
00867 { 00868 return property.handle().get<T>(m_position); 00869 }
T& IgCollectionItem::get | ( | const char * | label | ) | [inline] |
Definition at line 860 of file IgCollection.h.
References IgColumnHandle::get(), IgCollection::getHandleByLabel(), label, m_collection, and m_position.
00861 { 00862 return m_collection->getHandleByLabel(label).get<T>(m_position); 00863 }
IgCollectionItem& IgCollectionItem::moveToColumn | ( | const IgColumnHandle & | handle | ) | [inline] |
Definition at line 763 of file IgCollection.h.
References IgColumnHandle::data(), data, i, j, m_collection, m_propertyPosition, and IgCollection::properties().
Referenced by operator[]().
00764 { 00765 void *data = handle.data(); 00766 int j = 0; 00767 for (IgCollection::Properties::iterator i = m_collection->properties().begin(); 00768 (i != m_collection->properties().end()) && (i->handle().data() != data); 00769 i++) 00770 { j++; } 00771 m_propertyPosition = j; 00772 return *this; 00773 }
IgCollectionItem& IgCollectionItem::nextColumn | ( | void | ) | [inline] |
Definition at line 757 of file IgCollection.h.
References m_propertyPosition.
00758 { 00759 m_propertyPosition++; 00760 return *this; 00761 }
IgCollectionItem& IgCollectionItem::operator * | ( | void | ) | [inline] |
IgCollectionItem::operator IgRef | ( | ) | const [inline] |
Definition at line 898 of file IgCollection.h.
References IgCollection::id(), m_collection, and m_position.
00899 { return IgRef(m_collection->id(), m_position); }
IgCollectionItem& IgCollectionItem::operator, | ( | C< T, A > | container | ) | [inline] |
Definition at line 850 of file IgCollection.h.
References m_collection, m_position, m_propertyPosition, and MixingModule::put().
00851 { 00852 m_propertyPosition=ContainerTraits<C,T,A>::put(m_collection, 00853 m_propertyPosition, 00854 m_position, 00855 container); 00856 return *this; 00857 }
IgCollectionItem& IgCollectionItem::operator, | ( | const std::string & | value | ) | [inline] |
Definition at line 841 of file IgCollection.h.
References currentHandle(), IgColumnHandle::get(), m_position, and m_propertyPosition.
00842 { 00843 m_propertyPosition++; 00844 currentHandle().get<std::string>(m_position) = value; 00845 return *this; 00846 }
IgCollectionItem& IgCollectionItem::operator, | ( | const char * | value | ) | [inline] |
Definition at line 834 of file IgCollection.h.
References currentHandle(), IgColumnHandle::get(), m_position, and m_propertyPosition.
00835 { 00836 m_propertyPosition++; 00837 currentHandle().get<std::string>(m_position) = value; 00838 return *this; 00839 }
IgCollectionItem& IgCollectionItem::operator, | ( | T | value | ) | [inline] |
Definition at line 827 of file IgCollection.h.
References currentHandle(), IgColumnHandle::get(), m_position, and m_propertyPosition.
00828 { 00829 m_propertyPosition++; 00830 currentHandle().get<T>(m_position) = value; 00831 return *this; 00832 }
IgCollectionItem& IgCollectionItem::operator= | ( | C< T, A > | container | ) | [inline] |
Definition at line 817 of file IgCollection.h.
References m_collection, m_position, m_propertyPosition, and MixingModule::put().
00818 { 00819 ContainerTraits<C,T,A>::put(m_collection, 00820 m_propertyPosition, 00821 m_position, 00822 container); 00823 return *this; 00824 }
IgCollectionItem& IgCollectionItem::operator= | ( | const char * | value | ) | [inline] |
Definition at line 810 of file IgCollection.h.
References currentHandle(), IgColumnHandle::get(), and m_position.
00811 { 00812 currentHandle().get<std::string>(m_position) = value; 00813 return *this; 00814 }
IgCollectionItem& IgCollectionItem::operator= | ( | const std::string & | value | ) | [inline] |
Definition at line 804 of file IgCollection.h.
References currentHandle(), IgColumnHandle::get(), and m_position.
00805 { 00806 currentHandle().get<std::string>(m_position) = value; 00807 return *this; 00808 }
IgCollectionItem& IgCollectionItem::operator= | ( | T | value | ) | [inline] |
Definition at line 798 of file IgCollection.h.
References currentHandle(), IgColumnHandle::get(), and m_position.
00799 { 00800 currentHandle().get<typename IgStorageGetterTrait<T>::storage_type>(m_position) = value; 00801 return *this; 00802 }
IgCollectionItem& IgCollectionItem::operator[] | ( | const char * | label | ) | [inline] |
Definition at line 791 of file IgCollection.h.
References IgCollection::getHandleByLabel(), m_collection, and moveToColumn().
00792 { 00793 assert(m_collection && "Collection ptr is 0"); 00794 return this->moveToColumn(m_collection->getHandleByLabel(label)); 00795 }
IgCollectionItem& IgCollectionItem::operator[] | ( | IgProperty & | property | ) | [inline] |
Definition at line 786 of file IgCollection.h.
References IgProperty::handle(), and moveToColumn().
00787 { 00788 return this->moveToColumn(property.handle()); 00789 }
void IgCollectionItem::set | ( | const char * | label, | |
T | value | |||
) | [inline] |
void IgCollectionItem::set | ( | IgProperty & | property, | |
T | value | |||
) | [inline] |
Definition at line 872 of file IgCollection.h.
References m_position, and value.
00873 { 00874 property.handle().get<T>(m_position) = value; 00875 }
void IgCollectionItem::stream | ( | std::ostream & | stream | ) | [inline] |
Definition at line 883 of file IgCollection.h.
References i, m_collection, m_position, IgCollection::properties(), and IgColumnHandle::stream().
00884 { 00885 for (IgCollection::Properties::iterator i = m_collection->properties().begin(); 00886 i != m_collection->properties().end(); 00887 i++) 00888 { 00889 IgColumnHandle &handle = i->handle(); 00890 handle.stream(stream, m_position); 00891 if (i+1 != m_collection->properties().end()) 00892 { 00893 stream << ", "; 00894 } 00895 } 00896 }
IgCollection* IgCollectionItem::m_collection [private] |
Definition at line 926 of file IgCollection.h.
Referenced by currentHandle(), get(), moveToColumn(), operator IgRef(), operator,(), operator=(), operator[](), and stream().
unsigned int IgCollectionItem::m_position [private] |
Definition at line 927 of file IgCollection.h.
Referenced by current(), currentRow(), get(), operator IgRef(), operator,(), operator=(), set(), and stream().
unsigned int IgCollectionItem::m_propertyPosition [private] |
Definition at line 928 of file IgCollection.h.
Referenced by currentColumn(), currentHandle(), moveToColumn(), nextColumn(), operator,(), and operator=().