ardour
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Protected Attributes | Static Protected Attributes | Private Attributes | List of all members
ARDOUR::ElementImportHandler Class Referenceabstract

Virtual interface class for element import handlers. More...

#include <element_import_handler.h>

Inheritance diagram for ARDOUR::ElementImportHandler:
ARDOUR::AudioPlaylistImportHandler ARDOUR::AudioRegionImportHandler ARDOUR::AudioTrackImportHandler ARDOUR::LocationImportHandler ARDOUR::TempoMapImportHandler ARDOUR::UnusedAudioPlaylistImportHandler

Public Types

typedef boost::shared_ptr
< ElementImporter
ElementPtr
 
typedef std::list< ElementPtrElementList
 

Public Member Functions

 ElementImportHandler (XMLTree const &source, ARDOUR::Session &session)
 
virtual ~ElementImportHandler ()
 
virtual std::string get_info () const =0
 
bool check_name (const std::string &name) const
 
void add_name (std::string name)
 Adds name to the list of used names. More...
 
void remove_name (const std::string &name)
 Removes name from the list of used names. More...
 

Static Public Member Functions

static bool dirty ()
 Checks wheter or not all elements can be imported cleanly. More...
 
static void set_dirty ()
 Sets handler dirty. More...
 
static bool errors ()
 Checks wheter or not all elements were imported cleanly. More...
 
static void set_errors ()
 Sets handler dirty. More...
 

Public Attributes

ElementList elements
 Elements this handler handles. More...
 

Protected Attributes

XMLTree const & source
 Source session XML tree. More...
 
ARDOUR::Sessionsession
 Destination session. More...
 

Static Protected Attributes

static bool _dirty = false
 Session XML readability. More...
 
static bool _errors = false
 Errors post initialization. More...
 

Private Attributes

std::set< std::string > names
 Set of names for duplicate checking. More...
 

Detailed Description

Virtual interface class for element import handlers.

Definition at line 41 of file element_import_handler.h.

Member Typedef Documentation

Definition at line 45 of file element_import_handler.h.

Definition at line 44 of file element_import_handler.h.

Constructor & Destructor Documentation

ARDOUR::ElementImportHandler::ElementImportHandler ( XMLTree const &  source,
ARDOUR::Session session 
)
inline

ElementImportHandler constructor The constructor should find everything from the XML Tree it can handle and create respective Elements stored in elements.

Parameters
sourceXML tree to be parsed
See also
elements

Definition at line 54 of file element_import_handler.h.

ElementImportHandler::~ElementImportHandler ( )
virtual

Definition at line 32 of file element_import_handler.cc.

Member Function Documentation

void ElementImportHandler::add_name ( std::string  name)

Adds name to the list of used names.

Definition at line 45 of file element_import_handler.cc.

bool ElementImportHandler::check_name ( const std::string &  name) const

Checks whether or not an element with some name is queued or not

Parameters
namename to check
Returns
true if name is not used

Definition at line 39 of file element_import_handler.cc.

static bool ARDOUR::ElementImportHandler::dirty ( )
inlinestatic

Checks wheter or not all elements can be imported cleanly.

Definition at line 82 of file element_import_handler.h.

static bool ARDOUR::ElementImportHandler::errors ( )
inlinestatic

Checks wheter or not all elements were imported cleanly.

Definition at line 88 of file element_import_handler.h.

virtual std::string ARDOUR::ElementImportHandler::get_info ( ) const
pure virtual
void ElementImportHandler::remove_name ( const std::string &  name)

Removes name from the list of used names.

Definition at line 51 of file element_import_handler.cc.

static void ARDOUR::ElementImportHandler::set_dirty ( )
inlinestatic

Sets handler dirty.

Definition at line 85 of file element_import_handler.h.

static void ARDOUR::ElementImportHandler::set_errors ( )
inlinestatic

Sets handler dirty.

Definition at line 91 of file element_import_handler.h.

Member Data Documentation

bool ElementImportHandler::_dirty = false
staticprotected

Session XML readability.

Definition at line 101 of file element_import_handler.h.

bool ElementImportHandler::_errors = false
staticprotected

Errors post initialization.

Definition at line 104 of file element_import_handler.h.

ElementList ARDOUR::ElementImportHandler::elements

Elements this handler handles.

Definition at line 65 of file element_import_handler.h.

std::set<std::string> ARDOUR::ElementImportHandler::names
private

Set of names for duplicate checking.

Definition at line 108 of file element_import_handler.h.

ARDOUR::Session& ARDOUR::ElementImportHandler::session
protected

Destination session.

Definition at line 98 of file element_import_handler.h.

XMLTree const& ARDOUR::ElementImportHandler::source
protected

Source session XML tree.

Definition at line 95 of file element_import_handler.h.


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