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 IEventLaunchApplication.h
18 * @author Lukasz Marek (l.marek@samsung.com)
23 #ifndef _ABSTRACT_LAYER_IEVENT_LAUNCH_APPLICATION_H_
24 #define _ABSTRACT_LAYER_IEVENT_LAUNCH_APPLICATION_H_
28 #include <dpl/shared_ptr.h>
29 #include <commons/IEvent.h>
30 #include <commons/EventReceiver.h>
32 namespace WrtPlugins {
34 namespace AppLauncher {
35 /* this event is sent when application is launched */
36 class EventLaunchApplication : public WrtPlugins::Platform::IEvent<
37 EventLaunchApplication>
39 //Uri type. http://, file://, sms:, mailto: etc
40 ApplicationUriType m_applicationUriType;
41 // used as param to uriType, for example http address, path to file, phone
43 std::string m_applicationUriParam;
44 //optional parameters for file://
45 std::vector<std::string> m_applicationParameters;
48 void addApplicationParameter(const std::string &value)
50 m_applicationParameters.push_back(value);
52 std::vector<std::string> getApplicationParameters() const
54 return m_applicationParameters;
56 void setApplicationUriType(const ApplicationUriType value)
58 m_applicationUriType = value;
60 ApplicationUriType getApplicationUriType() const
62 return m_applicationUriType;
64 void setApplicationUriParam(const std::string &value)
66 m_applicationUriParam = value;
68 std::string getApplicationUriParam() const
70 return m_applicationUriParam;
72 virtual void clearOnCancel()
74 EventLaunchApplication() : m_applicationUriType(
75 APPLICATION_URI_TYPE_UNDEFINED)
79 typedef DPL::SharedPtr<EventLaunchApplication> EventLaunchApplicationPtr;
84 #endif /* _ABSTRACT_LAYER_IEVENT_LAUNCH_APPLICATION_H_ */