Scopira  20080306
scopira::core::project_i Class Referenceabstract

#include <project.h>

Inheritance diagram for scopira::core::project_i:
scopira::core::model_i scopira::tool::object scopira::core::project_base

Public Types

typedef scopira::core::model_iterator model_iterator
 the model iterator type
 

Public Member Functions

virtual bool is_project (void) const
 I AM a project!
 
virtual void add_model (model_i *parent, model_i *rec)=0
 
virtual void remove_model (model_i *parent, model_i *rec)=0
 
virtual bool contains_model (model_i *parent, model_i *rec)=0
 
virtual bool contains_model (model_i *rec)=0
 
virtual model_iget_parent (model_i *child)=0
 
virtual model_ifind_model (model_i *parent, const std::string &title) const =0
 
virtual model_iterator get_model_iterator (model_i *parent) const =0
 gets a listing of all the sub models
 
virtual bool is_project_empty (void) const =0
 
virtual void clear_project (void)=0
 
virtual void move_project (scopira::core::project_i *rhs)=0
 
virtual bool get_tagged_model_from_project (model_i *parent, const std::string &name, scopira::tool::count_ptr< scopira::core::model_i > &out)=0
 used by model_i
 
- Public Member Functions inherited from scopira::core::model_i
virtual bool load (scopira::tool::iobjflow_i &in)
 for title, mostly
 
virtual void save (scopira::tool::oobjflow_i &out) const
 for title, mostly
 
virtual void set_title (const std::string &newtitle)
 
const std::string & get_title (void) const
 
void add_view (view_i *ins) const
 
void remove_view (view_i *ins) const
 
void notify_views (view_i *src)
 
void add_rename_reactor (tool::rename_reactor_i *r) const
 
void remove_rename_reactor (tool::rename_reactor_i *r) const
 
virtual void set_project (project_i *newowner)
 
project_iget_project (void) const
 
void set_tagged_model (const std::string &name, model_i *what)
 
template<class W >
bool get_tagged_model (const std::string &name, W &out)
 
- Public Member Functions inherited from scopira::tool::object
virtual ~object ()
 
int add_ref (void) const
 
bool sub_ref (void) const
 
void auto_ref (void) const
 
int current_ref (void) const
 
virtual scopira::tool::oflow_iprint (scopira::tool::oflow_i &o) const
 
bool is_alive_object (void) const
 
bool is_dead_object (void) const
 

Protected Member Functions

 project_i (void)
 Default initing ctor.
 
 project_i (const std::string &title)
 title initing ctor
 
- Protected Member Functions inherited from scopira::core::model_i
 model_i (void)
 Default initing ctor.
 
 model_i (const std::string &title)
 title initing ctor
 
 model_i (const model_i &src)
 copy ctor
 
virtual ~model_i ()
 dtor (mainly, to flush the cache
 
- Protected Member Functions inherited from scopira::tool::object
 object (void)
 
 object (bool neverusecounter)
 

Detailed Description

The project interface.

a project houses a collection of one or more models, and other information.

Author
Aleksander Demko

Member Function Documentation

◆ add_model()

virtual void scopira::core::project_i::add_model ( model_i parent,
model_i rec 
)
pure virtual

Adds a model. null parent == root node

Author
Aleksander Demko

Implemented in scopira::core::project_base.

Referenced by is_project().

◆ clear_project()

virtual void scopira::core::project_i::clear_project ( void  )
pure virtual

Clears or resets the project to empty state.

Author
Aleksander Demko

Implemented in scopira::core::project_base.

Referenced by is_project().

◆ contains_model() [1/2]

virtual bool scopira::core::project_i::contains_model ( model_i parent,
model_i rec 
)
pure virtual

Does this group have the given model? null parent == root node

Author
Aleksander Demko

Implemented in scopira::core::project_base.

Referenced by is_project().

◆ contains_model() [2/2]

virtual bool scopira::core::project_i::contains_model ( model_i rec)
pure virtual

Does the group have this model anywhere, regarless of root.

Author
Aleksander Demko

Implemented in scopira::core::project_base.

◆ find_model()

virtual model_i* scopira::core::project_i::find_model ( model_i parent,
const std::string &  title 
) const
pure virtual

Finds a model by name. There may be many of them – this finds the "first" one. Returns 0 if none was found.

Author
Aleksander Demko

Implemented in scopira::core::project_base.

Referenced by is_project().

◆ get_parent()

virtual model_i* scopira::core::project_i::get_parent ( model_i child)
pure virtual

Gets the parent model of a given model. May be null (for root).

Author
Aleksander Demko

Implemented in scopira::core::project_base.

Referenced by is_project().

◆ is_project_empty()

virtual bool scopira::core::project_i::is_project_empty ( void  ) const
pure virtual

Is the project "empty?"

Author
Aleksander Demko

Implemented in scopira::core::project_base.

Referenced by is_project().

◆ move_project()

virtual void scopira::core::project_i::move_project ( scopira::core::project_i rhs)
pure virtual

Move a project's contents into this one.

Author
Aleksander Demko

Implemented in scopira::core::project_base.

Referenced by is_project().

◆ remove_model()

virtual void scopira::core::project_i::remove_model ( model_i parent,
model_i rec 
)
pure virtual

Removes the given model null parent == root node

Author
Aleksander Demko

Implemented in scopira::core::project_base.

Referenced by is_project().


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