update for beta universally
[profile/ivi/wrt-plugins-tizen.git] / src / platform / API / Calendar / OnDeleteEventsChanged.h
1 /*
2  * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
3  *
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
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
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.
15  */
16
17
18 #ifndef _ON_DELETE_EVENTS_CHANGED_H_
19 #define _ON_DELETE_EVENTS_CHANGED_H_
20
21 #include <vector>
22 #include <Commons/IEvent.h>
23 #include <dpl/shared_ptr.h>
24 #include <Commons/ListenerEvent.h>
25 #include <Commons/ListenerEventEmitter.h>
26 #include "EventId.h"
27
28 namespace TizenApis {
29 namespace Api {
30 namespace Calendar {
31
32 class OnDeleteEventsChanged : public WrtDeviceApis::Commons::ListenerEvent<OnDeleteEventsChanged>
33 {
34     public:
35     typedef enum
36     {
37                 SUCCESS_ALL,
38                 FAIL_ALL,
39                 EVENT_DELETE_SUCCESS,
40                 EVENT_DELETE_FAIL
41     } EventDeleteStatus;
42
43     void setResult (bool value) {
44         m_result = value;
45     }   
46     bool getResult() const {
47         return m_result;
48     }
49
50     void setEventId(EventIdPtr value) {
51         m_eventId = value;
52     }
53     EventIdPtr getEventId() const {
54         return m_eventId;
55     }
56
57     void setStatus(EventDeleteStatus value) {
58         m_status = value;
59     }
60     EventDeleteStatus getStatus() const {
61         return m_status;
62     }
63
64     OnDeleteEventsChanged() : m_result(false) {
65     }
66     ~OnDeleteEventsChanged() {
67     }
68
69     private:
70     EventIdPtr m_eventId;
71     EventDeleteStatus m_status;
72     bool m_result;
73 };
74
75 typedef DPL::SharedPtr<OnDeleteEventsChanged> OnDeleteEventsChangedPtr;
76 typedef WrtDeviceApis::Commons::ListenerEventEmitter<OnDeleteEventsChanged> OnDeleteEventsChangedEmitter;
77 typedef DPL::SharedPtr<OnDeleteEventsChangedEmitter> OnDeleteEventsChangedEmitterPtr;
78
79 }
80 }
81 }
82
83 #endif //_ON_DELETE_EVENTS_CHANGED_H_