WIP: interface/framwork skeleton

This commit is contained in:
Fischlurch 2009-06-08 04:46:07 +02:00
parent 529d4bd459
commit ba37045b48
9 changed files with 479 additions and 0 deletions

View file

@ -120,6 +120,9 @@ liblumiproccontrol_la_CFLAGS = $(AM_CFLAGS) -std=gnu99 -Wall -Wextra -Werror
liblumiproccontrol_la_CXXFLAGS = $(AM_CXXFLAGS) -Wall -Wextra
liblumiproccontrol_la_SOURCES = \
$(liblumiproccontrol_la_srcdir)/command.cpp \
$(liblumiproccontrol_la_srcdir)/handling-pattern.cpp \
$(liblumiproccontrol_la_srcdir)/proc-dispatcher.cpp \
$(liblumiproccontrol_la_srcdir)/pathmanager.cpp \
$(liblumiproccontrol_la_srcdir)/stypemanager.cpp

View file

@ -0,0 +1,65 @@
/*
COMMAND-CLOSURE.hpp - defining execution targets and parameters for commands
Copyright (C) Lumiera.org
2009, Hermann Vosseler <Ichthyostega@web.de>
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
published by the Free Software Foundation; either version 2 of the
License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
/** @file command-closure.hpp
** A closure enabling self-contained execution of commands within the ProcDispatcher.
** //TODO
**
** @see Command
** @see ProcDispatcher
**
*/
#ifndef CONTROL_COMMAND_CLOSURE_H
#define CONTROL_COMMAND_CLOSURE_H
//#include "pre.hpp"
//#include <tr1/memory>
namespace control {
// using lumiera::Symbol;
// using std::tr1::shared_ptr;
/**
* @todo Type-comment
*/
class CommandClosure
{
public:
};
////////////////TODO currently just fleshing out the API....
} // namespace control
#endif

View file

@ -0,0 +1,48 @@
/*
Command - Key abstraction for proc/edit operations and UNDO management
Copyright (C) Lumiera.org
2008, Hermann Vosseler <Ichthyostega@web.de>
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
published by the Free Software Foundation; either version 2 of the
License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
* *****************************************************/
/** @file command.cpp
** //TODO
**
** @see command.hpp
**
*/
#include "proc/control/command.hpp"
//#include "proc/mobject/mobject-ref.hpp"
//#include "proc/mobject/mobject.hpp"
//#include "proc/mobject/placement.hpp"
//#include <boost/format.hpp>
//using boost::str;
namespace control {
/** */
} // namespace control

View file

@ -0,0 +1,69 @@
/*
COMMAND.hpp - Key abstraction for proc/edit operations and UNDO management
Copyright (C) Lumiera.org
2009, Hermann Vosseler <Ichthyostega@web.de>
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
published by the Free Software Foundation; either version 2 of the
License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
/** @file command.hpp
** //TODO
**
** @see ProcDispatcher
** @see Session
**
*/
#ifndef CONTROL_COMMAND_H
#define CONTROL_COMMAND_H
//#include "pre.hpp"
#include "include/symbol.hpp"
#include "proc/control/mutation.hpp"
#include "proc/control/command-closure.hpp"
//#include <tr1/memory>
///////////////////////////////////////////TODO: define an C-API representation here, make the header multilingual!
namespace control {
using lumiera::Symbol;
// using std::tr1::shared_ptr;
/**
* @todo Type-comment
*/
class Command
{
public:
};
////////////////TODO currently just fleshing out the API....
} // namespace control
#endif

View file

@ -0,0 +1,41 @@
/*
HandlingPattern - A skeleton for executing commands, including standard implementations
Copyright (C) Lumiera.org
2008, Hermann Vosseler <Ichthyostega@web.de>
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
published by the Free Software Foundation; either version 2 of the
License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
* *****************************************************/
#include "proc/control/handling-pattern.hpp"
//#include "proc/mobject/mobject-ref.hpp"
//#include "proc/mobject/mobject.hpp"
//#include "proc/mobject/placement.hpp"
//#include <boost/format.hpp>
//using boost::str;
namespace control {
/** */
///////////////////////////////////////////////////////////////////////TODO: is this implementation file actually required??
} // namespace control

View file

@ -0,0 +1,68 @@
/*
HANDLILNG-PATTERN.hpp - A skeleton for executing commands, including standard implementations
Copyright (C) Lumiera.org
2009, Hermann Vosseler <Ichthyostega@web.de>
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
published by the Free Software Foundation; either version 2 of the
License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
/** @file handling-pattern.hpp
** //TODO
**
** @see ProcDispatcher
** @see Session
**
*/
#ifndef CONTROL_HANDLING_PATTERN_H
#define CONTROL_HANDLING_PATTERN_H
//#include "pre.hpp"
//#include "include/symbol.hpp"
//#include <tr1/memory>
namespace control {
using lumiera::Symbol;
// using std::tr1::shared_ptr;
class Command;
/**
* @todo Type-comment
*/
class HandlingPattern
{
public:
};
////////////////TODO currently just fleshing out the API....
} // namespace control
#endif

View file

@ -0,0 +1,77 @@
/*
MUTATION.hpp - a functor encapsulating the actual operation of a proc-Command
Copyright (C) Lumiera.org
2009, Hermann Vosseler <Ichthyostega@web.de>
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
published by the Free Software Foundation; either version 2 of the
License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
/** @file mutation.hpp
** The core of a proc-Layer command: functor containing the actual operation to be executed.
** //TODO
**
** @see Command
** @see ProcDispatcher
**
*/
#ifndef CONTROL_MUTATION_H
#define CONTROL_MUTATION_H
//#include "pre.hpp"
//#include <tr1/memory>
namespace control {
// using lumiera::Symbol;
// using std::tr1::shared_ptr;
/**
* @todo Type-comment
*/
class Mutation
{
public:
};
/**
* @todo Type-comment
*/
class UndoMutation
: public Mutation
{
public:
};
////////////////TODO currently just fleshing out the API....
} // namespace control
#endif

View file

@ -0,0 +1,41 @@
/*
ProcDispatcher - Proc-Layer command dispatch and execution
Copyright (C) Lumiera.org
2008, Hermann Vosseler <Ichthyostega@web.de>
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
published by the Free Software Foundation; either version 2 of the
License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
* *****************************************************/
#include "proc/control/proc-dispatcher.hpp"
//#include "proc/mobject/mobject-ref.hpp"
//#include "proc/mobject/mobject.hpp"
//#include "proc/mobject/placement.hpp"
//#include <boost/format.hpp>
//using boost::str;
namespace control {
/** */
} // namespace control

View file

@ -0,0 +1,67 @@
/*
PROC-DISPATCHER.hpp - Proc-Layer command dispatch and execution
Copyright (C) Lumiera.org
2009, Hermann Vosseler <Ichthyostega@web.de>
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
published by the Free Software Foundation; either version 2 of the
License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
/** @file proc-dispatcher.hpp
** Dispatch and execute mutation operations on the High-level model.
** //TODO
**
** @see Command
** @see Session
**
*/
#ifndef CONTROL_PROC_DISPATCHER_H
#define CONTROL_PROC_DISPATCHER_H
//#include "pre.hpp"
//#include "include/symbol.hpp"
#include "proc/control/command.hpp"
//#include <tr1/memory>
namespace control {
using lumiera::Symbol;
// using std::tr1::shared_ptr;
/**
* @todo Type-comment
*/
class ProcDispatcher
{
public:
};
////////////////TODO currently just fleshing out the API....
} // namespace control
#endif