2 * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
17 * @file attribute_facade.h
18 * @author Jaroslaw Osmanski (j.osmanski@samsung.com)
19 * @author Przemyslaw Dobrowolski (p.dobrowolsk@samsung.com)
21 * @brief This file contains the declaration of WebRuntimeImpl,
22 * ResourceInformationImpl, OperationSystemImpl
25 #ifndef ATTRIBUTE_FACADE_H
26 #define ATTRIBUTE_FACADE_H
32 #include <ace/WRT_INTERFACE.h>
36 class WebRuntimeImpl : public IWebRuntime
39 // Return current sessionId
40 int getAttributesValuesLoop(const Request &request,
41 std::list<ATTRIBUTE>* attributes,
42 WidgetExecutionPhase executionPhase);
44 int getAttributesValues(const Request &request,
45 std::list<ATTRIBUTE>* attributes);
46 virtual std::string getSessionId(const Request &request);
50 class ResourceInformationImpl : public IResourceInformation
53 int getAttributesValuesLoop(const Request &request,
54 std::list<ATTRIBUTE>* attributes,
55 WidgetExecutionPhase executionPhase);
56 int getAttributesValues(const Request &request,
57 std::list<ATTRIBUTE>* attributes);
58 ResourceInformationImpl();
61 class OperationSystemImpl : public IOperationSystem
65 * gather and set attributes values for specified attribute name
66 * @param attributes is a list of pairs(
67 * first: pointer to attribute name
68 * second: list of values for attribute (std::string) -
69 * its a list of string (BONDI requirement), but usually there
70 * will be only one string
72 int getAttributesValues(const Request &request,
73 std::list<ATTRIBUTE>* attributes);
74 OperationSystemImpl();
77 class FunctionParamImpl : public IFunctionParam
80 virtual int getAttributesValues(const Request & /*request*/,
81 std::list<ATTRIBUTE> *attributes);
82 void addAttribute(const std::string &key,
83 const std::string &value)
85 paramMap.insert(make_pair(key, value));
87 virtual ~FunctionParamImpl()
92 typedef std::multimap<std::string, std::string> ParamMap;
96 typedef std::vector <FunctionParamImpl> FunctionParams;
98 #endif //ATTRIBUTE_FACADE_H