diff --git a/Actions/actions.h b/Actions/actions.h new file mode 100644 index 0000000000..f1830fe0b0 --- /dev/null +++ b/Actions/actions.h @@ -0,0 +1,89 @@ +//////////////////////////////////////////////////////////////////////////////// +/// @brief vocbase +/// +/// @file +/// +/// DISCLAIMER +/// +/// Copyright 2010-2011 triagens GmbH, Cologne, Germany +/// +/// Licensed under the Apache License, Version 2.0 (the "License"); +/// you may not use this file except in compliance with the License. +/// You may obtain a copy of the License at +/// +/// http://www.apache.org/licenses/LICENSE-2.0 +/// +/// Unless required by applicable law or agreed to in writing, software +/// distributed under the License is distributed on an "AS IS" BASIS, +/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +/// See the License for the specific language governing permissions and +/// limitations under the License. +/// +/// Copyright holder is triAGENS GmbH, Cologne, Germany +/// +/// @author Dr. Frank Celler +/// @author Copyright 2011, triagens GmbH, Cologne, Germany +//////////////////////////////////////////////////////////////////////////////// + +#ifndef TRIAGENS_DURHAM_VOC_BASE_VOCBASE_H +#define TRIAGENS_DURHAM_VOC_BASE_VOCBASE_H 1 + +#include + +// ----------------------------------------------------------------------------- +// --SECTION-- forward declarations +// ----------------------------------------------------------------------------- + +// ----------------------------------------------------------------------------- +// --SECTION-- public types +// ----------------------------------------------------------------------------- + +//////////////////////////////////////////////////////////////////////////////// +/// @addtogroup VocBase +/// @{ +//////////////////////////////////////////////////////////////////////////////// + +//////////////////////////////////////////////////////////////////////////////// +/// @brief parameter type +//////////////////////////////////////////////////////////////////////////////// + +typedef enum { + TRI_ACT_STRING, + TRI_ACT_NUMBER, + TRI_ACT_COLLECTION, + TRI_ACT_COLLECTION_NAME, + TRI_ACT_COLLECTION_ID +} +TRI_action_parameter_type_e; + +//////////////////////////////////////////////////////////////////////////////// +/// @brief action descriptor +//////////////////////////////////////////////////////////////////////////////// + +typedef struct TRI_action_s { + void execute (rest::HttpRequest const& + std::string _url; + size_t _urlParts; + bool _isPrefix; + map _parameter; +} +TRI_action_t; + +//////////////////////////////////////////////////////////////////////////////// +/// @} +//////////////////////////////////////////////////////////////////////////////// + +// ----------------------------------------------------------------------------- +// --SECTION-- END-OF-LINE +// ----------------------------------------------------------------------------- + +#ifdef __cplusplus +} +#endif + +#endif + +// Local Variables: +// mode: outline-minor +// outline-regexp: "^\\(/// @brief\\|/// {@inheritDoc}\\|/// @addtogroup\\|// --SECTION--\\|/// @\\}\\)" +// End: diff --git a/V8/v8-actions.h b/V8/v8-actions.h index 68c1ec2885..237a3076ac 100644 --- a/V8/v8-actions.h +++ b/V8/v8-actions.h @@ -149,34 +149,6 @@ namespace triagens { /// @{ //////////////////////////////////////////////////////////////////////////////// -//////////////////////////////////////////////////////////////////////////////// -/// @brief parameter type -//////////////////////////////////////////////////////////////////////////////// - -typedef enum { - TRI_ACT_STRING, - TRI_ACT_NUMBER, - TRI_ACT_COLLECTION, - TRI_ACT_COLLECTION_NAME, - TRI_ACT_COLLECTION_ID -} -TRI_action_parameter_type_e; - -//////////////////////////////////////////////////////////////////////////////// -/// @brief parameter definition -//////////////////////////////////////////////////////////////////////////////// - -typedef struct TRI_action_parameter_s { - TRI_action_parameter_s () - : _name(), - _type(TRI_ACT_NUMBER) { - } - - std::string _name; - TRI_action_parameter_type_e _type; -} -TRI_action_parameter_t; - //////////////////////////////////////////////////////////////////////////////// /// @brief action options definition ////////////////////////////////////////////////////////////////////////////////