Tizen 2.1 base
[framework/osp/uifw.git] / inc / FUiIDataBindingListener.h
1 //
2 // Open Service Platform
3 // Copyright (c) 2012-2013 Samsung Electronics Co., Ltd.
4 //
5 // Licensed under the Flora License, Version 1.0 (the License);
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
8 //
9 //     http://floralicense.org/license/
10 //
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an AS IS BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
16 //
17
18 /**
19  * @file        FUiIDataBindingListener.h
20  * @brief       This is the header file for the %IDataBindingListener interface.
21  *
22  * This header file contains the declarations of the %IDataBindingListener interface.
23  */
24
25 #ifndef _FUI_IDATA_BINDING_LISTENER_H_
26 #define _FUI_IDATA_BINDING_LISTENER_H_
27
28 #include <FBaseRtIEventListener.h>
29 #include <FUiDataBindingTypes.h>
30
31 namespace Tizen { namespace Ui
32 {
33
34 /**
35  * @interface           IDataBindingListener
36  * @brief                       This interface is the listener interface for receiving data binding-related events.
37  *
38  * @since 2.0
39  *
40  * The %IDataBindingListener interface defines methods for receiving data binding-related events.
41  */
42 class _OSP_EXPORT_ IDataBindingListener
43         : public Tizen::Base::Runtime::IEventListener
44 {
45 public:
46         /**
47          * This polymorphic destructor should be overridden if required. This way, the destructors of the derived classes are called when the destructor of this interface is called.
48          *
49          * @since 2.0
50          */
51         virtual ~IDataBindingListener(void) {};
52
53         /**
54          * Called when the data transfer for source is completed by the data binding.
55          *
56          * @since 2.0
57          *
58          * @param[in]    bindingId        The binding ID
59          * @param[in]    controlName      The name of binding target control
60          * @param[in]    propertyName     The name of binding target property
61          */
62         virtual void OnDataBindingSourceUpdated(const Tizen::Base::String& bindingId, const Tizen::Base::String& controlName, const Tizen::Base::String& propertyName) = 0;
63
64         /**
65          * Called when the data transfer for target is completed by the data binding.
66          *
67          * @since 2.0
68          *
69          * @param[in]    bindingId       The binding ID
70          * @param[in]    controlName     The name of binding target control
71          * @param[in]    propertyName    The name of binding target property
72          */
73         virtual void OnDataBindingTargetUpdated(const Tizen::Base::String& bindingId, const Tizen::Base::String& controlName, const Tizen::Base::String& propertyName) = 0;
74
75         /**
76          * Called when a validation has failed during data transfer.
77          *
78          * @since 2.0
79          *
80          * @param[in]    bindingId       The binding ID
81          * @param[in]    controlName     The name of binding target control
82          * @param[in]    propertyName    The name of binding target property
83          * @param[in]    destType        The data binding destination type
84          */
85         virtual void OnDataBindingValidationFailed(const Tizen::Base::String& bindingId, const Tizen::Base::String& controlName, const Tizen::Base::String& propertyName, DataBindingDestinationType destType) = 0;
86
87 protected:
88         //
89         // This method is for internal use only. Using this method can cause behavioral, security-related,
90         // and consistency-related issues in the application.
91         //
92         // This method is reserved and may change its name at any time without
93         // prior notice.
94         //
95         virtual void IDataBindingListener_Reserved1(void) {}
96
97         //
98         // This method is for internal use only. Using this method can cause behavioral, security-related,
99         // and consistency-related issues in the application.
100         //
101         // This method is reserved and may change its name at any time without
102         // prior notice.
103         //
104         virtual void IDataBindingListener_Reserved2(void) {}
105
106         //
107         // This method is for internal use only. Using this method can cause behavioral, security-related,
108         // and consistency-related issues in the application.
109         //
110         // This method is reserved and may change its name at any time without
111         // prior notice.
112         //
113         virtual void IDataBindingListener_Reserved3(void) {}
114
115 }; // IDataBindingListener;
116
117 }} // Tizen::Ui
118 #endif // _FUI_IDATA_BINDING_LISTENER_H_