Reranker Framework (ReFr)
Reranking framework for structure prediction and discriminative language modeling
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Types | Public Member Functions | List of all members
reranker::Initializers Class Reference

A container for all the member initializers for a particular Factory-constructible instance. More...

#include <factory.H>

Public Types

typedef unordered_map< string,
MemberInitializer * >
::const_iterator 
const_iterator
 Forward the const_iterator typedef of the internal data structure, to make code compact and readable. More...
 
typedef unordered_map< string,
MemberInitializer * >
::iterator 
iterator
 Forward the iterator typedef of the internal data structure, to make code compact and readable. More...
 

Public Member Functions

 Initializers ()
 Constructs a new instance. More...
 
virtual ~Initializers ()
 Destroys this instance. More...
 
template<typename T >
void Add (const string &name, T *member, bool required=false)
 
const_iterator begin () const
 Returns a const iterator pointing to the beginning of the map from member names to pointers to TypedMemberInitializer instances. More...
 
const_iterator end () const
 Returns a const iterator pointing to the end of the map from member names to pointers to TypedMemberInitializer instances. More...
 
iterator begin ()
 Returns an iterator pointing to the beginning of the map from member names to pointers to TypedMemberInitializer instances. More...
 
iterator end ()
 Returns an iterator pointing to the end of the map from member names to pointers to TypedMemberInitializer instances. More...
 
const_iterator find (const string &name) const
 Returns a const_iterator pointing to the MemberInitializer associated with the specified name, or else end if no such TypedMemberInitializer exists. More...
 
iterator find (const string &name)
 Returns an iterator pointing to the MemberInitializer associated with the specified name, or else end if no such TypedMemberInitializer exists. More...
 

Detailed Description

A container for all the member initializers for a particular Factory-constructible instance.

This class provides an easy, consistent syntax for Factory-constructible classes to specify which members they want/need initialized by the Factory based on the specification string.

Definition at line 203 of file factory.H.

Member Typedef Documentation

Forward the const_iterator typedef of the internal data structure, to make code compact and readable.

Definition at line 208 of file factory.H.

typedef unordered_map<string, MemberInitializer *>::iterator reranker::Initializers::iterator

Forward the iterator typedef of the internal data structure, to make code compact and readable.

Definition at line 211 of file factory.H.

Constructor & Destructor Documentation

reranker::Initializers::Initializers ( )
inline

Constructs a new instance.

Definition at line 214 of file factory.H.

virtual reranker::Initializers::~Initializers ( )
inlinevirtual

Destroys this instance.

Definition at line 216 of file factory.H.

Member Function Documentation

template<typename T >
void reranker::Initializers::Add ( const string &  name,
T *  member,
bool  required = false 
)
inline

Definition at line 225 of file factory.H.

const_iterator reranker::Initializers::begin ( ) const
inline

Returns a const iterator pointing to the beginning of the map from member names to pointers to TypedMemberInitializer instances.

Definition at line 232 of file factory.H.

iterator reranker::Initializers::begin ( )
inline

Returns an iterator pointing to the beginning of the map from member names to pointers to TypedMemberInitializer instances.

Definition at line 243 of file factory.H.

const_iterator reranker::Initializers::end ( ) const
inline

Returns a const iterator pointing to the end of the map from member names to pointers to TypedMemberInitializer instances.

Definition at line 237 of file factory.H.

iterator reranker::Initializers::end ( )
inline

Returns an iterator pointing to the end of the map from member names to pointers to TypedMemberInitializer instances.

Definition at line 247 of file factory.H.

const_iterator reranker::Initializers::find ( const string &  name) const
inline

Returns a const_iterator pointing to the MemberInitializer associated with the specified name, or else end if no such TypedMemberInitializer exists.

Definition at line 254 of file factory.H.

iterator reranker::Initializers::find ( const string &  name)
inline

Returns an iterator pointing to the MemberInitializer associated with the specified name, or else end if no such TypedMemberInitializer exists.

Definition at line 262 of file factory.H.


The documentation for this class was generated from the following file: