Fawkes API  Fawkes Development Version
openrave.cpp
00001 
00002 /***************************************************************************
00003  *  openrave.cpp - OpenRave aspect for Fawkes
00004  *
00005  *  Created: Fri Feb 25 15:08:00 2011
00006  *  Copyright  2011  Bahram Maleki-Fard
00007  *
00008  ****************************************************************************/
00009 
00010 /*  This program is free software; you can redistribute it and/or modify
00011  *  it under the terms of the GNU General Public License as published by
00012  *  the Free Software Foundation; either version 2 of the License, or
00013  *  (at your option) any later version. A runtime exception applies to
00014  *  this software (see LICENSE.GPL_WRE file mentioned below for details).
00015  *
00016  *  This program is distributed in the hope that it will be useful,
00017  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
00018  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00019  *  GNU Library General Public License for more details.
00020  *
00021  *  Read the full text in the LICENSE.GPL_WRE file in the doc directory.
00022  */
00023 
00024 #include <plugins/openrave/aspect/openrave.h>
00025 
00026 namespace fawkes {
00027 #if 0 /* just to make Emacs auto-indent happy */
00028 }
00029 #endif
00030 
00031 /** @class OpenRaveAspect <plugins/openrave/aspect/openrave.h>
00032  * Thread aspect create, update, and graph round-robin databases (RRD).
00033  * Give this aspect to your thread to access the OpenRave environment,
00034  * add robots or objects, path plans for manipulator movement, etc.
00035  *
00036  * @ingroup Aspects
00037  * @author Bahram Maleki-Fard
00038  */
00039 
00040 /** @var fawkes::OpenRaveConnector *  OpenRaveAspect::openrave
00041  * Manager class to access OpenRave features. It will take care of properly
00042  * distributing the work.
00043  */
00044 
00045 /** Constructor. */
00046 OpenRaveAspect::OpenRaveAspect()
00047 {
00048   add_aspect("OpenRaveAspect");
00049 }
00050 
00051 
00052 /** Virtual empty destructor. */
00053 OpenRaveAspect::~OpenRaveAspect()
00054 {
00055 }
00056 
00057 
00058 /** Init OpenRave aspect.
00059  * This sets the OpenRave manager to access OpenRave.
00060  * It is guaranteed that this is called for an OpenRave Thread before start
00061  * is called (when running regularly inside Fawkes).
00062  * @param or_manager OpenRaveManager to use
00063  */
00064 void
00065 OpenRaveAspect::init_OpenRaveAspect(OpenRaveConnector *openrave)
00066 {
00067   this->openrave = openrave;
00068 }
00069 
00070 } // end namespace fawkes