English Review: NUI public files (#434)
[platform/core/csapi/tizenfx.git] / src / Tizen.NUI / src / public / Property.cs
1 /*
2  * Copyright(c) 2017 Samsung Electronics Co., Ltd.
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 using System;
19 using System.ComponentModel;
20 using System.Collections.Generic;
21 using Tizen.NUI.Binding;
22
23 namespace Tizen.NUI
24 {
25
26     internal class Property : global::System.IDisposable
27     {
28         private global::System.Runtime.InteropServices.HandleRef swigCPtr;
29         /// <summary>
30         /// swigCMemOwn
31         /// </summary>
32         /// <since_tizen> 3 </since_tizen>
33         protected bool swigCMemOwn;
34
35         internal Property(global::System.IntPtr cPtr, bool cMemoryOwn)
36         {
37             swigCMemOwn = cMemoryOwn;
38             swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
39         }
40
41         internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Property obj)
42         {
43             return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
44         }
45
46         //A Flag to check who called Dispose(). (By User or DisposeQueue)
47         private bool isDisposeQueued = false;
48         /// <summary>
49         /// <since_tizen> 3 </since_tizen>
50         /// A Flat to check if it is already disposed.
51         /// </summary>
52         protected bool disposed = false;
53
54         ~Property()
55         {
56             if(!isDisposeQueued)
57             {
58                 isDisposeQueued = true;
59                 DisposeQueue.Instance.Add(this);
60             }
61         }
62
63         public void Dispose()
64         {
65             //Throw excpetion if Dispose() is called in separate thread.
66             if (!Window.IsInstalled())
67             {
68                 throw new System.InvalidOperationException("This API called from separate thread. This API must be called from MainThread.");
69             }
70
71             if (isDisposeQueued)
72             {
73                 Dispose(DisposeTypes.Implicit);
74             }
75             else
76             {
77                 Dispose(DisposeTypes.Explicit);
78                 System.GC.SuppressFinalize(this);
79             }
80         }
81
82         protected virtual void Dispose(DisposeTypes type)
83         {
84             if (disposed)
85             {
86                 return;
87             }
88
89             if(type == DisposeTypes.Explicit)
90             {
91                 //Called by User
92                 //Release your own managed resources here.
93                 //You should release all of your own disposable objects here.
94             }
95
96             //Release your own unmanaged resources here.
97             //You should not access any managed member here except static instance.
98             //because the execution order of Finalizes is non-deterministic.
99
100             if (swigCPtr.Handle != global::System.IntPtr.Zero)
101             {
102                 if (swigCMemOwn)
103                 {
104                     swigCMemOwn = false;
105                     NDalicPINVOKE.delete_Property(swigCPtr);
106                 }
107                 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
108             }
109             disposed = true;
110         }
111
112
113         internal static int INVALID_INDEX
114         {
115             get
116             {
117                 int ret = NDalicPINVOKE.Property_INVALID_INDEX_get();
118                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
119                 return ret;
120             }
121         }
122
123         internal static int INVALID_KEY
124         {
125             get
126             {
127                 int ret = NDalicPINVOKE.Property_INVALID_KEY_get();
128                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
129                 return ret;
130             }
131         }
132
133         internal static int INVALID_COMPONENT_INDEX
134         {
135             get
136             {
137                 int ret = NDalicPINVOKE.Property_INVALID_COMPONENT_INDEX_get();
138                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
139                 return ret;
140             }
141         }
142
143         /// <summary>
144         /// This constructor creates a property instance.
145         /// </summary>
146         /// <param name="arg0">A valid handle to the target object.</param>
147         /// <param name="propertyIndex">The index of a property.</param>
148         /// <since_tizen> 3 </since_tizen>
149         public Property(Animatable arg0, int propertyIndex) : this(NDalicPINVOKE.new_Property__SWIG_0(Animatable.getCPtr(arg0), propertyIndex), true)
150         {
151             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
152         }
153
154         /// <summary>
155         /// This constructor creates a property instance.
156         /// </summary>
157         /// <param name="arg0">A valid handle to the target object.</param>
158         /// <param name="propertyIndex">The index of a property.</param>
159         /// <param name="componentIndex">Index to a sub component of a property, for use with Vector2, Vector3 and Vector4. -1 for the main property (default is -1).</param>
160         /// <since_tizen> 3 </since_tizen>
161         public Property(Animatable arg0, int propertyIndex, int componentIndex) : this(NDalicPINVOKE.new_Property__SWIG_1(Animatable.getCPtr(arg0), propertyIndex, componentIndex), true)
162         {
163             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
164         }
165
166         /// <summary>
167         /// This constructor creates a property instance.<br />
168         /// This performs a property index query and is therefore slower than constructing a property directly with the index.<br />
169         /// </summary>
170         /// <param name="arg0">A valid handle to the target object.</param>
171         /// <param name="propertyName">The property name.</param>
172         /// <since_tizen> 3 </since_tizen>
173         public Property(Animatable arg0, string propertyName) : this(NDalicPINVOKE.new_Property__SWIG_2(Animatable.getCPtr(arg0), propertyName), true)
174         {
175             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
176         }
177
178         /// <summary>
179         /// This constructor creates a property instance.<br />
180         /// This performs a property index query and is therefore slower than constructing a property directly with the index.<br />
181         /// </summary>
182         /// <param name="arg0">A valid handle to the target object.</param>
183         /// <param name="propertyName">The property name.</param>
184         /// <param name="componentIndex">Index to a sub component of a property, for use with Vector2, Vector3 and Vector4. -1 for main property (default is -1).</param>
185         /// <since_tizen> 3 </since_tizen>
186         public Property(Animatable arg0, string propertyName, int componentIndex) : this(NDalicPINVOKE.new_Property__SWIG_3(Animatable.getCPtr(arg0), propertyName, componentIndex), true)
187         {
188             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
189         }
190
191         internal Animatable _object
192         {
193             set
194             {
195                 NDalicPINVOKE.Property__object_set(swigCPtr, Animatable.getCPtr(value));
196                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
197             }
198             get
199             {
200                 Animatable ret = new Animatable(NDalicPINVOKE.Property__object_get(swigCPtr), false);
201                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
202                 return ret;
203             }
204         }
205
206         /// <summary>
207         /// Gets or sets the index of the property.
208         /// </summary>
209         /// <since_tizen> 3 </since_tizen>
210         public int propertyIndex
211         {
212             set
213             {
214                 NDalicPINVOKE.Property_propertyIndex_set(swigCPtr, value);
215                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
216             }
217             get
218             {
219                 int ret = NDalicPINVOKE.Property_propertyIndex_get(swigCPtr);
220                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
221                 return ret;
222             }
223         }
224
225         /// <summary>
226         /// Gets or sets the component index of the property.
227         /// </summary>
228         /// <since_tizen> 3 </since_tizen>
229         public int componentIndex
230         {
231             set
232             {
233                 NDalicPINVOKE.Property_componentIndex_set(swigCPtr, value);
234                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
235             }
236             get
237             {
238                 int ret = NDalicPINVOKE.Property_componentIndex_get(swigCPtr);
239                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
240                 return ret;
241             }
242         }
243
244     }
245
246     /// <summary>
247     /// An array of property values.
248     /// </summary>
249     /// <since_tizen> 3 </since_tizen>
250     public class PropertyArray : global::System.IDisposable
251     {
252         private global::System.Runtime.InteropServices.HandleRef swigCPtr;
253         /// <summary>
254         /// swigCMemOwn
255         /// </summary>
256         /// <since_tizen> 3 </since_tizen>
257         protected bool swigCMemOwn;
258
259         internal PropertyArray(global::System.IntPtr cPtr, bool cMemoryOwn)
260         {
261             swigCMemOwn = cMemoryOwn;
262             swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
263         }
264
265         internal static global::System.Runtime.InteropServices.HandleRef getCPtr(PropertyArray obj)
266         {
267             return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
268         }
269
270         //A Flag to check who called Dispose(). (By User or DisposeQueue)
271         private bool isDisposeQueued = false;
272         /// <summary>
273         /// A Flat to check if it is already disposed.
274         /// </summary>
275         /// <since_tizen> 3 </since_tizen>
276         protected bool disposed = false;
277
278         /// <summary>
279         /// Dispose.
280         /// </summary>
281         /// <since_tizen> 3 </since_tizen>
282         ~PropertyArray()
283         {
284             if(!isDisposeQueued)
285             {
286                 isDisposeQueued = true;
287                 DisposeQueue.Instance.Add(this);
288             }
289         }
290
291         /// <summary>
292         /// Dispose.
293         /// </summary>
294         /// <since_tizen> 3 </since_tizen>
295         public void Dispose()
296         {
297             //Throw excpetion if Dispose() is called in separate thread.
298             if (!Window.IsInstalled())
299             {
300                 throw new System.InvalidOperationException("This API called from separate thread. This API must be called from MainThread.");
301             }
302
303             if (isDisposeQueued)
304             {
305                 Dispose(DisposeTypes.Implicit);
306             }
307             else
308             {
309                 Dispose(DisposeTypes.Explicit);
310                 System.GC.SuppressFinalize(this);
311             }
312         }
313
314         /// <summary>
315         /// Dispose.
316         /// </summary>
317         /// <since_tizen> 3 </since_tizen>
318         protected virtual void Dispose(DisposeTypes type)
319         {
320             if (disposed)
321             {
322                 return;
323             }
324
325             if(type == DisposeTypes.Explicit)
326             {
327                 //Called by User
328                 //Release your own managed resources here.
329                 //You should release all of your own disposable objects here.
330             }
331
332             //Release your own unmanaged resources here.
333             //You should not access any managed member here except static instance.
334             //because the execution order of Finalizes is non-deterministic.
335
336             if (swigCPtr.Handle != global::System.IntPtr.Zero)
337             {
338                 if (swigCMemOwn)
339                 {
340                     swigCMemOwn = false;
341                     NDalicPINVOKE.delete_Property_Array(swigCPtr);
342                 }
343                 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
344             }
345             disposed = true;
346         }
347
348         /// <summary>
349         /// The operator to access an element.
350         /// </summary>
351         /// <param name="index">The element index to access. No bounds checking is performed.</param>
352         /// <returns>The reference to the element.</returns>
353         /// <since_tizen> 3 </since_tizen>
354         public PropertyValue this[uint index]
355         {
356             get
357             {
358                 return ValueOfIndex(index);
359             }
360         }
361
362         /// <summary>
363         /// The constructor.
364         /// </summary>
365         /// <since_tizen> 3 </since_tizen>
366         public PropertyArray() : this(NDalicPINVOKE.new_Property_Array__SWIG_0(), true)
367         {
368             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
369         }
370
371         internal PropertyArray(PropertyArray other) : this(NDalicPINVOKE.new_Property_Array__SWIG_1(PropertyArray.getCPtr(other)), true)
372         {
373             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
374         }
375
376         /// <summary>
377         /// Retrieves the number of elements in the array.
378         /// </summary>
379         /// <returns>The number of elements in the array.</returns>
380         /// <since_tizen> 3 </since_tizen>
381         public uint Size()
382         {
383             uint ret = NDalicPINVOKE.Property_Array_Size(swigCPtr);
384             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
385             return ret;
386         }
387
388         /// <summary>
389         /// Retrieves the number of elements in the array.
390         /// </summary>
391         /// <returns>The number of elements in the array.</returns>
392         /// <since_tizen> 3 </since_tizen>
393         public uint Count()
394         {
395             uint ret = NDalicPINVOKE.Property_Array_Count(swigCPtr);
396             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
397             return ret;
398         }
399
400         /// <summary>
401         /// Returns whether the array is empty.
402         /// </summary>
403         /// <returns>Returns true if empty, false otherwise.</returns>
404         /// <since_tizen> 3 </since_tizen>
405         public bool Empty()
406         {
407             bool ret = NDalicPINVOKE.Property_Array_Empty(swigCPtr);
408             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
409             return ret;
410         }
411
412         /// <summary>
413         /// Clears the array.
414         /// </summary>
415         /// <since_tizen> 3 </since_tizen>
416         public void Clear()
417         {
418             NDalicPINVOKE.Property_Array_Clear(swigCPtr);
419             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
420         }
421
422         /// <summary>
423         /// Increases the capacity of the array.
424         /// </summary>
425         /// <param name="size">The size to reserve.</param>
426         /// <since_tizen> 3 </since_tizen>
427         public void Reserve(uint size)
428         {
429             NDalicPINVOKE.Property_Array_Reserve(swigCPtr, size);
430             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
431         }
432
433         /// <summary>
434         /// Resizes to size.
435         /// </summary>
436         /// <param name="size">The size to resize</param>
437         /// <since_tizen> 3 </since_tizen>
438         public void Resize(uint size)
439         {
440             NDalicPINVOKE.Property_Array_Resize(swigCPtr, size);
441             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
442         }
443
444         /// <summary>
445         /// Retrieves the capacity of the array.
446         /// </summary>
447         /// <returns>The allocated capacity of the array.</returns>
448         /// <since_tizen> 3 </since_tizen>
449         public uint Capacity()
450         {
451             uint ret = NDalicPINVOKE.Property_Array_Capacity(swigCPtr);
452             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
453             return ret;
454         }
455
456         /// <summary>
457         /// Adds an element to the array.
458         /// </summary>
459         /// <param name="value">The value to add at the end of the array.</param>
460         /// <since_tizen> 3 </since_tizen>
461         public void PushBack(PropertyValue value)
462         {
463             NDalicPINVOKE.Property_Array_PushBack(swigCPtr, PropertyValue.getCPtr(value));
464             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
465         }
466
467         /// <summary>
468         /// Adds an keyvalue to the array.
469         /// This function should be first
470         /// </summary>
471         /// <param name="value">The value to add at the end of the array.</param>
472         public PropertyArray Add(KeyValue value)
473         {
474             PropertyArray ret = new PropertyArray(NDalicPINVOKE.Property_Array_Add(swigCPtr, PropertyValue.getCPtr(value.TrueValue)), false);
475             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
476             return ret;
477         }
478
479         /// <summary>
480         /// Adds an element to the array.
481         /// </summary>
482         /// <param name="value">The value to add at the end of the array.</param>
483         /// <since_tizen> 3 </since_tizen>
484         public PropertyArray Add(PropertyValue value)
485         {
486             PropertyArray ret = new PropertyArray(NDalicPINVOKE.Property_Array_Add(swigCPtr, PropertyValue.getCPtr(value)), false);
487             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
488             return ret;
489         }
490
491         /// <summary>
492         /// Accesses an element.
493         /// </summary>
494         /// <param name="index">The element index to access. No bounds checking is performed.</param>
495         /// <returns>The reference to the element.</returns>
496         /// <since_tizen> 3 </since_tizen>
497         public PropertyValue GetElementAt(uint index)
498         {
499             PropertyValue ret = new PropertyValue(NDalicPINVOKE.Property_Array_GetElementAt__SWIG_0(swigCPtr, index), false);
500             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
501             return ret;
502         }
503
504         /// <summary>
505         /// Retrieves the value of elements in the array.
506         /// </summary>
507         /// <param name="index">The element index to retrieve.</param>
508         /// <returns>The reference to the element.</returns>
509         private PropertyValue ValueOfIndex(uint index)
510         {
511             PropertyValue ret = new PropertyValue(NDalicPINVOKE.Property_Array_ValueOfIndex__SWIG_0(swigCPtr, index), false);
512             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
513             return ret;
514         }
515     }
516
517     /// <summary>
518     /// A key type which can be either a std::string or a Property::Index.
519     /// </summary>
520     /// <since_tizen> 3 </since_tizen>
521     public class PropertyKey : global::System.IDisposable
522     {
523         private global::System.Runtime.InteropServices.HandleRef swigCPtr;
524         /// <summary>
525         /// swigCMemOwn
526         /// </summary>
527         /// <since_tizen> 3 </since_tizen>
528         protected bool swigCMemOwn;
529
530         internal PropertyKey(global::System.IntPtr cPtr, bool cMemoryOwn)
531         {
532             swigCMemOwn = cMemoryOwn;
533             swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
534         }
535
536         internal static global::System.Runtime.InteropServices.HandleRef getCPtr(PropertyKey obj)
537         {
538             return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
539         }
540
541         //A Flag to check who called Dispose(). (By User or DisposeQueue)
542         private bool isDisposeQueued = false;
543         /// <summary>
544         /// A Flat to check if it is already disposed.
545         /// </summary>
546         /// <since_tizen> 3 </since_tizen>
547         protected bool disposed = false;
548
549         /// <summary>
550         /// Dispose.
551         /// </summary>
552         /// <since_tizen> 3 </since_tizen>
553         ~PropertyKey()
554         {
555             if(!isDisposeQueued)
556             {
557                 isDisposeQueued = true;
558                 DisposeQueue.Instance.Add(this);
559             }
560         }
561
562         /// <summary>
563         /// Dispose.
564         /// </summary>
565         /// <since_tizen> 3 </since_tizen>
566         public void Dispose()
567         {
568             //Throw excpetion if Dispose() is called in separate thread.
569             if (!Window.IsInstalled())
570             {
571                 throw new System.InvalidOperationException("This API called from separate thread. This API must be called from MainThread.");
572             }
573
574             if (isDisposeQueued)
575             {
576                 Dispose(DisposeTypes.Implicit);
577             }
578             else
579             {
580                 Dispose(DisposeTypes.Explicit);
581                 System.GC.SuppressFinalize(this);
582             }
583         }
584
585         /// <summary>
586         /// Dispose.
587         /// </summary>
588         /// <since_tizen> 3 </since_tizen>
589         protected virtual void Dispose(DisposeTypes type)
590         {
591             if (disposed)
592             {
593                 return;
594             }
595
596             if(type == DisposeTypes.Explicit)
597             {
598                 //Called by User
599                 //Release your own managed resources here.
600                 //You should release all of your own disposable objects here.
601             }
602
603             //Release your own unmanaged resources here.
604             //You should not access any managed member here except static instance.
605             //because the execution order of Finalizes is non-deterministic.
606
607             if (swigCPtr.Handle != global::System.IntPtr.Zero)
608             {
609                 if (swigCMemOwn)
610                 {
611                     swigCMemOwn = false;
612                     NDalicPINVOKE.delete_Property_Key(swigCPtr);
613                 }
614                 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
615             }
616             disposed = true;
617         }
618
619         /// <summary>
620         /// The type of the key.
621         /// </summary>
622         /// <since_tizen> 3 </since_tizen>
623         public PropertyKey.KeyType Type
624         {
625             set
626             {
627                 NDalicPINVOKE.Property_Key_type_set(swigCPtr, (int)value);
628                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
629             }
630             get
631             {
632                 PropertyKey.KeyType ret = (PropertyKey.KeyType)NDalicPINVOKE.Property_Key_type_get(swigCPtr);
633                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
634                 return ret;
635             }
636         }
637
638         /// <summary>
639         /// The index key.
640         /// </summary>
641         /// <since_tizen> 3 </since_tizen>
642         public int IndexKey
643         {
644             set
645             {
646                 NDalicPINVOKE.Property_Key_indexKey_set(swigCPtr, value);
647                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
648             }
649             get
650             {
651                 int ret = NDalicPINVOKE.Property_Key_indexKey_get(swigCPtr);
652                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
653                 return ret;
654             }
655         }
656
657         /// <summary>
658         /// The string key.
659         /// </summary>
660         /// <since_tizen> 3 </since_tizen>
661         public string StringKey
662         {
663             set
664             {
665                 NDalicPINVOKE.Property_Key_stringKey_set(swigCPtr, value);
666                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
667             }
668             get
669             {
670                 string ret = NDalicPINVOKE.Property_Key_stringKey_get(swigCPtr);
671                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
672                 return ret;
673             }
674         }
675
676         /// <summary>
677         /// The constructor.
678         /// </summary>
679         /// <param name="key">The string key.</param>
680         /// <since_tizen> 3 </since_tizen>
681         public PropertyKey(string key) : this(NDalicPINVOKE.new_Property_Key__SWIG_0(key), true)
682         {
683             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
684         }
685
686         /// <summary>
687         /// The constructor.
688         /// </summary>
689         /// <param name="key">The index key.</param>
690         /// <since_tizen> 3 </since_tizen>
691         public PropertyKey(int key) : this(NDalicPINVOKE.new_Property_Key__SWIG_1(key), true)
692         {
693             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
694         }
695
696         /// <summary>
697         /// Compares if rhs is equal to.
698         /// </summary>
699         /// <param name="rhs">A string key to compare against.</param>
700         /// <returns>Returns true if the key compares, or false if it isn't equal or of the wrong type.</returns>
701         /// <since_tizen> 3 </since_tizen>
702         public bool EqualTo(string rhs)
703         {
704             bool ret = NDalicPINVOKE.Property_Key_EqualTo__SWIG_0(swigCPtr, rhs);
705             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
706             return ret;
707         }
708
709         /// <summary>
710         /// Compares if rhs is equal to.
711         /// </summary>
712         /// <param name="rhs">The index key to compare against.</param>
713         /// <returns>Returns true if the key compares, or false if it isn't equal or of the wrong type.</returns>
714         /// <since_tizen> 3 </since_tizen>
715         public bool EqualTo(int rhs)
716         {
717             bool ret = NDalicPINVOKE.Property_Key_EqualTo__SWIG_1(swigCPtr, rhs);
718             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
719             return ret;
720         }
721
722         /// <summary>
723         /// Compares if rhs is equal to
724         /// </summary>
725         /// <param name="rhs">A key to compare against</param>
726         /// <returns>Returns true if the keys are of the same type and have the same value.</returns>
727         /// <since_tizen> 3 </since_tizen>
728         public bool EqualTo(PropertyKey rhs)
729         {
730             bool ret = NDalicPINVOKE.Property_Key_EqualTo__SWIG_2(swigCPtr, PropertyKey.getCPtr(rhs));
731             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
732             return ret;
733         }
734
735         /// <summary>
736         /// Compares if rhs is not equal to.
737         /// </summary>
738         /// <param name="rhs">The index key to compare against.</param>
739         /// <returns>Returns true if the key is not equal or not a string key.</returns>
740         /// <since_tizen> 3 </since_tizen>
741         public bool NotEqualTo(string rhs)
742         {
743             bool ret = NDalicPINVOKE.Property_Key_NotEqualTo__SWIG_0(swigCPtr, rhs);
744             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
745             return ret;
746         }
747
748         /// <summary>
749         /// Compares if rhs is not equal to.
750         /// </summary>
751         /// <param name="rhs">The index key to compare against.</param>
752         /// <returns>Returns true if the key is not equal, or not the index key.</returns>
753         /// <since_tizen> 3 </since_tizen>
754         public bool NotEqualTo(int rhs)
755         {
756             bool ret = NDalicPINVOKE.Property_Key_NotEqualTo__SWIG_1(swigCPtr, rhs);
757             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
758             return ret;
759         }
760
761         /// <summary>
762         /// Compares if rhs is not equal to.
763         /// </summary>
764         /// <param name="rhs">A key to compare against.</param>
765         /// <returns>Returns true if the keys are not of the same type or are not equal.</returns>
766         /// <since_tizen> 3 </since_tizen>
767         public bool NotEqualTo(PropertyKey rhs)
768         {
769             bool ret = NDalicPINVOKE.Property_Key_NotEqualTo__SWIG_2(swigCPtr, PropertyKey.getCPtr(rhs));
770             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
771             return ret;
772         }
773
774         /// <summary>
775         /// The type of key.
776         /// </summary>
777         /// <since_tizen> 3 </since_tizen>
778         public enum KeyType
779         {
780             /// <summary>
781             /// The type of key is index.
782             /// </summary>
783             /// <since_tizen> 3 </since_tizen>
784             Index,
785             /// <summary>
786             /// The type of key is string.
787             /// </summary>
788             /// <since_tizen> 3 </since_tizen>
789             String
790         }
791
792     }
793
794     /// <summary>
795     /// A map of property values, the key type could be string or Property::Index.
796     /// </summary>
797     /// <since_tizen> 3 </since_tizen>
798     public class PropertyMap : global::System.IDisposable
799     {
800         private global::System.Runtime.InteropServices.HandleRef swigCPtr;
801         /// <summary>
802         /// swigCMemOwn
803         /// </summary>
804         /// <since_tizen> 3 </since_tizen>
805         protected bool swigCMemOwn;
806
807         internal PropertyMap(global::System.IntPtr cPtr, bool cMemoryOwn)
808         {
809             swigCMemOwn = cMemoryOwn;
810             swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
811         }
812
813         internal static global::System.Runtime.InteropServices.HandleRef getCPtr(PropertyMap obj)
814         {
815             return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
816         }
817
818         //A Flag to check who called Dispose(). (By User or DisposeQueue)
819         private bool isDisposeQueued = false;
820         /// <summary>
821         /// A Flat to check if it is already disposed.
822         /// </summary>
823         /// <since_tizen> 3 </since_tizen>
824         protected bool disposed = false;
825
826         /// <summary>
827         /// Dispose.
828         /// </summary>
829         /// <since_tizen> 3 </since_tizen>
830         ~PropertyMap()
831         {
832             if(!isDisposeQueued)
833             {
834                 isDisposeQueued = true;
835                 DisposeQueue.Instance.Add(this);
836             }
837         }
838
839         /// <summary>
840         /// Dispose.
841         /// </summary>
842         /// <since_tizen> 3 </since_tizen>
843         public void Dispose()
844         {
845             //Throw excpetion if Dispose() is called in separate thread.
846             if (!Window.IsInstalled())
847             {
848                 throw new System.InvalidOperationException("This API called from separate thread. This API must be called from MainThread.");
849             }
850
851             if (isDisposeQueued)
852             {
853                 Dispose(DisposeTypes.Implicit);
854             }
855             else
856             {
857                 Dispose(DisposeTypes.Explicit);
858                 System.GC.SuppressFinalize(this);
859             }
860         }
861
862         /// <summary>
863         /// Dispose.
864         /// </summary>
865         /// <since_tizen> 3 </since_tizen>
866         protected virtual void Dispose(DisposeTypes type)
867         {
868             if (disposed)
869             {
870                 return;
871             }
872
873             if(type == DisposeTypes.Explicit)
874             {
875                 //Called by User
876                 //Release your own managed resources here.
877                 //You should release all of your own disposable objects here.
878             }
879
880             //Release your own unmanaged resources here.
881             //You should not access any managed member here except static instance.
882             //because the execution order of Finalizes is non-deterministic.
883
884             if (swigCPtr.Handle != global::System.IntPtr.Zero)
885             {
886                 if (swigCMemOwn)
887                 {
888                     swigCMemOwn = false;
889                     NDalicPINVOKE.delete_Property_Map(swigCPtr);
890                 }
891                 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
892             }
893             disposed = true;
894         }
895
896         /// <summary>
897         /// The operator to access the element with the specified string key.<br />
898         /// If an element with the key does not exist, then it is created.<br />
899         /// </summary>
900         /// <param name="key">The key whose value to access.</param>
901         /// <returns>A value for the element with the specified key.</returns>
902         /// <since_tizen> 3 </since_tizen>
903         public PropertyValue this[string key]
904         {
905             get
906             {
907                 return ValueOfIndex(key);
908             }
909         }
910
911         /// <summary>
912         /// The operator to access the element with the specified index key.<br />
913         /// If an element with the key does not exist, then it is created.<br />
914         /// </summary>
915         /// <param name="key">The key whose value to access.</param>
916         /// <returns>A value for the element with the specified key.</returns>
917         /// <since_tizen> 3 </since_tizen>
918         public PropertyValue this[int key]
919         {
920             get
921             {
922                 return ValueOfIndex(key);
923             }
924         }
925
926         /// <summary>
927         /// The constructor.
928         /// </summary>
929         /// <since_tizen> 3 </since_tizen>
930         public PropertyMap() : this(NDalicPINVOKE.new_Property_Map__SWIG_0(), true)
931         {
932             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
933         }
934
935         /// <summary>
936         /// The copy constructor.
937         /// </summary>
938         /// <param name="other">The map to copy from.</param>
939         /// <since_tizen> 3 </since_tizen>
940         public PropertyMap(PropertyMap other) : this(NDalicPINVOKE.new_Property_Map__SWIG_1(PropertyMap.getCPtr(other)), true)
941         {
942             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
943         }
944
945         /// <summary>
946         /// Retrieves the number of elements in the map.
947         /// </summary>
948         /// <returns>The number of elements in the map.</returns>
949         /// <since_tizen> 3 </since_tizen>
950         public uint Count()
951         {
952             uint ret = NDalicPINVOKE.Property_Map_Count(swigCPtr);
953             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
954             return ret;
955         }
956
957         /// <summary>
958         /// Returns whether the map is empty.
959         /// </summary>
960         /// <returns>Returns true if empty, false otherwise.</returns>
961         /// <since_tizen> 3 </since_tizen>
962         public bool Empty()
963         {
964             bool ret = NDalicPINVOKE.Property_Map_Empty(swigCPtr);
965             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
966             return ret;
967         }
968
969         /// <summary>
970         /// Inserts the key-value pair in the map, with the key type as string.<br />
971         /// Does not check for duplicates.<br />
972         /// </summary>
973         /// <param name="key">The key to insert.</param>
974         /// <param name="value">The value to insert.</param>
975         /// <since_tizen> 3 </since_tizen>
976         public void Insert(string key, PropertyValue value)
977         {
978             NDalicPINVOKE.Property_Map_Insert__SWIG_0(swigCPtr, key, PropertyValue.getCPtr(value));
979             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
980         }
981
982         /// <summary>
983         /// Inserts the key-value pair in the map, with the key type as index.<br />
984         /// Does not check for duplicates.<br />
985         /// </summary>
986         /// <param name="key">The key to insert.</param>
987         /// <param name="value">The value to insert.</param>
988         /// <since_tizen> 3 </since_tizen>
989         public void Insert(int key, PropertyValue value)
990         {
991             NDalicPINVOKE.Property_Map_Insert__SWIG_2(swigCPtr, key, PropertyValue.getCPtr(value));
992             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
993         }
994
995         /// <summary>
996         /// Inserts the key-value pair in the map, with the key type as string.<br />
997         /// Does not check for duplicates.<br />
998         /// </summary>
999         /// <param name="key">The key to insert.</param>
1000         /// <param name="value">The value to insert.</param>
1001         /// <returns>Returns a reference to this object.</returns>
1002         /// <since_tizen> 3 </since_tizen>
1003         public PropertyMap Add(string key, PropertyValue value)
1004         {
1005             PropertyMap ret = new PropertyMap(NDalicPINVOKE.Property_Map_Add__SWIG_0(swigCPtr, key, PropertyValue.getCPtr(value)), false);
1006             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1007             return ret;
1008         }
1009
1010         /// <summary>
1011         /// Inserts the key-value pair in the map, with the key type as string.<br />
1012         /// Does not check for duplicates.<br />
1013         /// </summary>
1014         /// <param name="key">The key to insert.</param>
1015         /// <param name="value">The value to insert.</param>
1016         /// <returns>Returns a reference to this object.</returns>
1017         /// <since_tizen> 3 </since_tizen>
1018         public PropertyMap Add(int key, PropertyValue value)
1019         {
1020             PropertyMap ret = new PropertyMap(NDalicPINVOKE.Property_Map_Add__SWIG_2(swigCPtr, key, PropertyValue.getCPtr(value)), false);
1021             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1022             return ret;
1023         }
1024
1025         /// <summary>
1026         /// Inserts the keyvalue to the map.<br />
1027         /// Does not check for duplicates.<br />
1028         /// </summary>
1029         /// <param name="keyValue">The keyvalue to insert.</param>
1030         /// <returns>Returns a reference to this object.</returns>
1031         public PropertyMap Add(KeyValue keyValue)
1032         {
1033             PropertyMap ret = new PropertyMap();
1034             if ( keyValue.KeyInt != null )
1035             {
1036                 ret = new PropertyMap(NDalicPINVOKE.Property_Map_Add__SWIG_2(swigCPtr, (int)keyValue.KeyInt, PropertyValue.getCPtr(keyValue.TrueValue)), false);
1037             }
1038             else if ( keyValue.KeyString != null)
1039             {
1040                 ret = new PropertyMap(NDalicPINVOKE.Property_Map_Add__SWIG_0(swigCPtr, keyValue.KeyString, PropertyValue.getCPtr(keyValue.TrueValue)), false);
1041             }
1042             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1043
1044             return ret;
1045         }
1046
1047         /// <summary>
1048         /// Retrieves the value at the specified position.
1049         /// </summary>
1050         /// <param name="position">The specified position.</param>
1051         /// <returns>A reference to the value at the specified position.</returns>
1052         /// <since_tizen> 3 </since_tizen>
1053         public PropertyValue GetValue(uint position)
1054         {
1055             PropertyValue ret = new PropertyValue(NDalicPINVOKE.Property_Map_GetValue(swigCPtr, position), false);
1056             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1057             return ret;
1058         }
1059
1060         /// <summary>
1061         /// Retrieves the key at the specified position.
1062         /// </summary>
1063         /// <param name="position">The specified position.</param>
1064         /// <returns>A copy of the key at the specified position.</returns>
1065         /// <since_tizen> 3 </since_tizen>
1066         public PropertyKey GetKeyAt(uint position)
1067         {
1068             PropertyKey ret = new PropertyKey(NDalicPINVOKE.Property_Map_GetKeyAt(swigCPtr, position), true);
1069             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1070             return ret;
1071         }
1072
1073         /// <summary>
1074         /// Finds the value for the specified key if it exists.
1075         /// </summary>
1076         /// <param name="key">The key to find.</param>
1077         /// <returns>The value if it exists, an empty object otherwise.</returns>
1078         /// <since_tizen> 3 </since_tizen>
1079         public PropertyValue Find(int key)
1080         {
1081             global::System.IntPtr cPtr = NDalicPINVOKE.Property_Map_Find__SWIG_2(swigCPtr, key);
1082             PropertyValue ret = (cPtr == global::System.IntPtr.Zero) ? null : new PropertyValue(cPtr, false);
1083             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1084             return ret;
1085         }
1086
1087         /// <summary>
1088         /// Finds the value for the specified keys if either exist.
1089         /// </summary>
1090         /// <param name="indexKey">The index key to find.</param>
1091         /// <param name="stringKey">The string key to find.</param>
1092         /// <returns>The value if it exists, an empty object otherwise.</returns>
1093         /// <since_tizen> 3 </since_tizen>
1094         public PropertyValue Find(int indexKey, string stringKey)
1095         {
1096             global::System.IntPtr cPtr = NDalicPINVOKE.Property_Map_Find__SWIG_3(swigCPtr, indexKey, stringKey);
1097             PropertyValue ret = (cPtr == global::System.IntPtr.Zero) ? null : new PropertyValue(cPtr, false);
1098             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1099             return ret;
1100         }
1101
1102         /// <summary>
1103         /// Clears the map.
1104         /// </summary>
1105         /// <since_tizen> 3 </since_tizen>
1106         public void Clear()
1107         {
1108             NDalicPINVOKE.Property_Map_Clear(swigCPtr);
1109             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1110         }
1111
1112         /// <summary>
1113         /// Merges values from the map 'from' to the current.<br />
1114         /// Any values in 'from' will overwrite the values in the current map.<br />
1115         /// </summary>
1116         /// <param name="from">The map to merge from.</param>
1117         /// <since_tizen> 3 </since_tizen>
1118         public void Merge(PropertyMap from)
1119         {
1120             NDalicPINVOKE.Property_Map_Merge(swigCPtr, PropertyMap.getCPtr(from));
1121             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1122         }
1123
1124         /// <summary>
1125         /// Retrieves the element with the specified string key.
1126         /// </summary>
1127         /// <param name="key">The key whose value to retrieve.</param>
1128         /// <returns>The value for the element with the specified key.</returns>
1129         internal PropertyValue ValueOfIndex(string key)
1130         {
1131             PropertyValue ret = new PropertyValue(NDalicPINVOKE.Property_Map_ValueOfIndex__SWIG_0(swigCPtr, key), false);
1132             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1133             return ret;
1134         }
1135
1136         /// <summary>
1137         /// Retrieves the element with the specified index key.
1138         /// </summary>
1139         /// <param name="key">The key whose value to retrieve.</param>
1140         /// <returns>The value for the element with the specified key.</returns>
1141         internal PropertyValue ValueOfIndex(int key)
1142         {
1143             PropertyValue ret = new PropertyValue(NDalicPINVOKE.Property_Map_ValueOfIndex__SWIG_2(swigCPtr, key), false);
1144             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1145             return ret;
1146         }
1147     }
1148
1149     /// <summary>
1150     /// A value-type representing a property value.
1151     /// </summary>
1152     /// <since_tizen> 3 </since_tizen>
1153     public class PropertyValue : global::System.IDisposable
1154     {
1155         private global::System.Runtime.InteropServices.HandleRef swigCPtr;
1156         /// <summary>
1157         /// swigCMemOwn
1158         /// </summary>
1159         /// <since_tizen> 3 </since_tizen>
1160         protected bool swigCMemOwn;
1161
1162         internal PropertyValue(global::System.IntPtr cPtr, bool cMemoryOwn)
1163         {
1164             swigCMemOwn = cMemoryOwn;
1165             swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
1166         }
1167
1168         internal static global::System.Runtime.InteropServices.HandleRef getCPtr(PropertyValue obj)
1169         {
1170             return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
1171         }
1172
1173         //A Flag to check who called Dispose(). (By User or DisposeQueue)
1174         private bool isDisposeQueued = false;
1175         /// <summary>
1176         /// A Flat to check if it is already disposed.
1177         /// </summary>
1178         /// <since_tizen> 3 </since_tizen>
1179         protected bool disposed = false;
1180
1181         /// <summary>
1182         /// Dispose.
1183         /// </summary>
1184         /// <since_tizen> 3 </since_tizen>
1185         ~PropertyValue()
1186         {
1187             if(!isDisposeQueued)
1188             {
1189                 isDisposeQueued = true;
1190                 DisposeQueue.Instance.Add(this);
1191             }
1192         }
1193
1194         /// <summary>
1195         /// Dispose.
1196         /// </summary>
1197         /// <since_tizen> 3 </since_tizen>
1198         public void Dispose()
1199         {
1200             //Throw excpetion if Dispose() is called in separate thread.
1201             if (!Window.IsInstalled())
1202             {
1203                 throw new System.InvalidOperationException("This API called from separate thread. This API must be called from MainThread.");
1204             }
1205
1206             if (isDisposeQueued)
1207             {
1208                 Dispose(DisposeTypes.Implicit);
1209             }
1210             else
1211             {
1212                 Dispose(DisposeTypes.Explicit);
1213                 System.GC.SuppressFinalize(this);
1214             }
1215         }
1216
1217         /// <summary>
1218         /// Dispose.
1219         /// </summary>
1220         /// <since_tizen> 3 </since_tizen>
1221         protected virtual void Dispose(DisposeTypes type)
1222         {
1223             if (disposed)
1224             {
1225                 return;
1226             }
1227
1228             if(type == DisposeTypes.Explicit)
1229             {
1230                 //Called by User
1231                 //Release your own managed resources here.
1232                 //You should release all of your own disposable objects here.
1233             }
1234
1235             //Release your own unmanaged resources here.
1236             //You should not access any managed member here except static instance.
1237             //because the execution order of Finalizes is non-deterministic.
1238
1239             if (swigCPtr.Handle != global::System.IntPtr.Zero)
1240             {
1241                 if (swigCMemOwn)
1242                 {
1243                     swigCMemOwn = false;
1244                     NDalicPINVOKE.delete_Property_Value(swigCPtr);
1245                 }
1246                 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
1247             }
1248             disposed = true;
1249         }
1250
1251
1252         /// <summary>
1253         /// An extension to the property value class that allows us to create a
1254         /// Property value from a C# object, for example, integer, float, or string.<br />
1255         /// </summary>
1256         /// <param name="obj">An object to create.</param>
1257         /// <returns>The created value.</returns>
1258         /// <since_tizen> 3 </since_tizen>
1259         static public PropertyValue CreateFromObject(System.Object obj)
1260         {
1261             System.Type type = obj.GetType();
1262
1263             PropertyValue value;
1264             if (type.IsEnum)
1265             {
1266                 value = new PropertyValue((int)obj);//Enum.Parse(type, str);
1267             }
1268             else if (type.Equals(typeof(int)))
1269             {
1270                 value = new PropertyValue((int)obj);
1271             }
1272             else if (type.Equals(typeof(System.Int32)))
1273             {
1274                 value = new PropertyValue((int)obj);
1275             }
1276             else if (type.Equals(typeof(bool)))
1277             {
1278                 value = new PropertyValue((bool)obj);
1279             }
1280             else if (type.Equals(typeof(float)))
1281             {
1282                 value = new PropertyValue((float)obj);
1283             }
1284             else if (type.Equals(typeof(string)))
1285             {
1286                 value = new PropertyValue((string)obj);
1287             }
1288             else if (type.Equals(typeof(Vector2)))
1289             {
1290                 value = new PropertyValue((Vector2)obj);
1291             }
1292             else if (type.Equals(typeof(Vector3)))
1293             {
1294                 value = new PropertyValue((Vector3)obj);
1295             }
1296             else if (type.Equals(typeof(Vector4)))
1297             {
1298                 value = new PropertyValue((Vector4)obj);
1299             }
1300             else if (type.Equals(typeof(Position)))
1301             {
1302                 value = new PropertyValue((Position)obj);
1303             }
1304             else if (type.Equals(typeof(Position2D)))
1305             {
1306                 value = new PropertyValue((Position2D)obj);
1307             }
1308             else if (type.Equals(typeof(Size)))
1309             {
1310                 value = new PropertyValue((Size)obj);
1311             }
1312             else if (type.Equals(typeof(Size2D)))
1313             {
1314                 value = new PropertyValue((Size2D)obj);
1315             }
1316             else if (type.Equals(typeof(Color)))
1317             {
1318                 value = new PropertyValue((Color)obj);
1319             }
1320             else if (type.Equals(typeof(Rotation)))
1321             {
1322                 value = new PropertyValue((Rotation)obj);
1323             }
1324             else if (type.Equals(typeof(RelativeVector2)))
1325             {
1326                 value = new PropertyValue((RelativeVector2)obj);
1327             }
1328             else if (type.Equals(typeof(RelativeVector3)))
1329             {
1330                 value = new PropertyValue((RelativeVector3)obj);
1331             }
1332             else if (type.Equals(typeof(RelativeVector4)))
1333             {
1334                 value = new PropertyValue((RelativeVector4)obj);
1335             }
1336             else if(type.Equals(typeof(Extents)))
1337             {
1338                 value = new PropertyValue((Extents)obj);
1339             }
1340             else
1341             {
1342                 throw new global::System.InvalidOperationException("Unimplemented type for Property Value :" + type.Name);
1343             }
1344             //NUILog.Debug(" got an property value of =" + type.Name);
1345             return value;
1346         }
1347
1348         /// <summary>
1349         /// Creates a Size2D property value.
1350         /// </summary>
1351         /// <param name="vectorValue">Size2D values.</param>
1352         /// <since_tizen> 3 </since_tizen>
1353         public PropertyValue(Size2D vectorValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_4(Size2D.getCPtr(vectorValue)), true)
1354         {
1355             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1356         }
1357
1358         /// <summary>
1359         /// Creates a Position2D property value.
1360         /// </summary>
1361         /// <param name="vectorValue">Position2D values.</param>
1362         /// <since_tizen> 3 </since_tizen>
1363         public PropertyValue(Position2D vectorValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_4(Position2D.getCPtr(vectorValue)), true)
1364         {
1365             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1366         }
1367
1368         /// <summary>
1369         /// Creates a Size property value.
1370         /// </summary>
1371         /// <param name="vectorValue">Size values.</param>
1372         internal PropertyValue(Size vectorValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_5(Size.getCPtr(vectorValue)), true)
1373         {
1374             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1375         }
1376
1377         /// <summary>
1378         /// Creates a Position property value.
1379         /// </summary>
1380         /// <param name="vectorValue">Position values.</param>
1381         /// <since_tizen> 3 </since_tizen>
1382         public PropertyValue(Position vectorValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_5(Position.getCPtr(vectorValue)), true)
1383         {
1384             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1385         }
1386
1387         /// <summary>
1388         /// Creates a Color property value.
1389         /// </summary>
1390         /// <param name="vectorValue">Color values.</param>
1391         /// <since_tizen> 3 </since_tizen>
1392         public PropertyValue(Color vectorValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_6(Color.getCPtr(vectorValue)), true)
1393         {
1394             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1395         }
1396
1397
1398         /// <summary>
1399         /// Retrieves a Size2D value.
1400         /// </summary>
1401         /// <param name="vectorValue"> On return, a Size2D value.</param>
1402         /// <since_tizen> 3 </since_tizen>
1403         public bool Get(Size2D vectorValue)
1404         {
1405             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_5(swigCPtr, Size2D.getCPtr(vectorValue));
1406             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1407             return ret;
1408         }
1409
1410         /// <summary>
1411         /// Retrieves a Position2D value.
1412         /// </summary>
1413         /// <param name="vectorValue"> On return, a Position2D value.</param>
1414         /// <since_tizen> 3 </since_tizen>
1415         public bool Get(Position2D vectorValue)
1416         {
1417             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_5(swigCPtr, Position2D.getCPtr(vectorValue));
1418             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1419             return ret;
1420         }
1421
1422         /// <summary>
1423         /// Retrieves a Size value.
1424         /// </summary>
1425         /// <param name="vectorValue"> On return, a size value.</param>
1426         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1427         [EditorBrowsable(EditorBrowsableState.Never)]
1428         public bool Get(Size vectorValue)
1429         {
1430             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_6(swigCPtr, Size.getCPtr(vectorValue));
1431             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1432             return ret;
1433         }
1434
1435         /// <summary>
1436         /// Retrieves a Position value.
1437         /// </summary>
1438         /// <param name="vectorValue"> On return, a position value.</param>
1439         /// <since_tizen> 3 </since_tizen>
1440         public bool Get(Position vectorValue)
1441         {
1442             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_6(swigCPtr, Position.getCPtr(vectorValue));
1443             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1444             return ret;
1445         }
1446
1447         /// <summary>
1448         /// Retrieves a Color value.
1449         /// </summary>
1450         /// <param name="vectorValue"> On return, a color value.</param>
1451         /// <since_tizen> 3 </since_tizen>
1452         public bool Get(Color vectorValue)
1453         {
1454             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_7(swigCPtr, Color.getCPtr(vectorValue));
1455             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1456             return ret;
1457         }
1458
1459
1460
1461         /// <summary>
1462         /// The default constructor.
1463         /// </summary>
1464         /// <since_tizen> 3 </since_tizen>
1465         public PropertyValue() : this(NDalicPINVOKE.new_Property_Value__SWIG_0(), true)
1466         {
1467             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1468         }
1469
1470         /// <summary>
1471         /// Creates a boolean property value.
1472         /// </summary>
1473         /// <param name="boolValue">A boolean value.</param>
1474         /// <since_tizen> 3 </since_tizen>
1475         public PropertyValue(bool boolValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_1(boolValue), true)
1476         {
1477             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1478         }
1479
1480         /// <summary>
1481         /// Creates an integer property value.
1482         /// </summary>
1483         /// <param name="integerValue">An integer value.</param>
1484         /// <since_tizen> 3 </since_tizen>
1485         public PropertyValue(int integerValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_2(integerValue), true)
1486         {
1487             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1488         }
1489
1490         /// <summary>
1491         /// Creates a float property value.
1492         /// </summary>
1493         /// <param name="floatValue">A floating-point value.</param>
1494         /// <since_tizen> 3 </since_tizen>
1495         public PropertyValue(float floatValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_3(floatValue), true)
1496         {
1497             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1498         }
1499
1500         /// <summary>
1501         /// Creates a Vector2 property value.
1502         /// </summary>
1503         /// <param name="vectorValue">A vector of 2 floating-point values.</param>
1504         /// <since_tizen> 3 </since_tizen>
1505         public PropertyValue(Vector2 vectorValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_4(Vector2.getCPtr(vectorValue)), true)
1506         {
1507             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1508         }
1509
1510         /// <summary>
1511         /// Creates a Vector3 property value.
1512         /// </summary>
1513         /// <param name="vectorValue">A vector of 3 floating-point values.</param>
1514         /// <since_tizen> 3 </since_tizen>
1515         public PropertyValue(Vector3 vectorValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_5(Vector3.getCPtr(vectorValue)), true)
1516         {
1517             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1518         }
1519
1520         /// <summary>
1521         /// Creates a Vector4 property value.
1522         /// </summary>
1523         /// <param name="vectorValue">A vector of 4 floating-point values.</param>
1524         /// <since_tizen> 3 </since_tizen>
1525         public PropertyValue(Vector4 vectorValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_6(Vector4.getCPtr(vectorValue)), true)
1526         {
1527             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1528         }
1529
1530         internal PropertyValue(Matrix3 matrixValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_7(Matrix3.getCPtr(matrixValue)), true)
1531         {
1532             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1533         }
1534
1535         internal PropertyValue(Matrix matrixValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_8(Matrix.getCPtr(matrixValue)), true)
1536         {
1537             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1538         }
1539
1540         /// <summary>
1541         /// Creates a Rectangle property value.
1542         /// </summary>
1543         /// <param name="vectorValue">Rectangle values.</param>
1544         /// <since_tizen> 3 </since_tizen>
1545         public PropertyValue(Rectangle vectorValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_9(Rectangle.getCPtr(vectorValue)), true)
1546         {
1547             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1548         }
1549
1550         internal PropertyValue(AngleAxis angleAxis) : this(NDalicPINVOKE.new_Property_Value__SWIG_10(AngleAxis.getCPtr(angleAxis)), true)
1551         {
1552             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1553         }
1554
1555         /// <summary>
1556         /// Creates a Rotation property value.
1557         /// </summary>
1558         /// <param name="quaternion">Rotation values.</param>
1559         /// <since_tizen> 3 </since_tizen>
1560         public PropertyValue(Rotation quaternion) : this(NDalicPINVOKE.new_Property_Value__SWIG_11(Rotation.getCPtr(quaternion)), true)
1561         {
1562             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1563         }
1564
1565         /// <summary>
1566         /// Creates a string property value.
1567         /// </summary>
1568         /// <param name="stringValue">A string.</param>
1569         /// <since_tizen> 3 </since_tizen>
1570         public PropertyValue(string stringValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_12(stringValue), true)
1571         {
1572             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1573         }
1574
1575         /// <summary>
1576         /// Creates an array property value.
1577         /// </summary>
1578         /// <param name="arrayValue">An array.</param>
1579         /// <since_tizen> 3 </since_tizen>
1580         public PropertyValue(PropertyArray arrayValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_14(PropertyArray.getCPtr(arrayValue)), true)
1581         {
1582             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1583         }
1584
1585         /// <summary>
1586         /// Creates a map property value.
1587         /// </summary>
1588         /// <param name="mapValue">An array.</param>
1589         /// <since_tizen> 3 </since_tizen>
1590         public PropertyValue(PropertyMap mapValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_15(PropertyMap.getCPtr(mapValue)), true)
1591         {
1592             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1593         }
1594
1595         /// <summary>
1596         /// Creates a Extents value.
1597         /// </summary>
1598         /// <param name="extentsValue">A Extents value.</param>
1599         /// <since_tizen> 4 </since_tizen>
1600         public PropertyValue(Extents extentsValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_16(Extents.getCPtr(extentsValue)), true)
1601         {
1602             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1603         }
1604
1605         /// <summary>
1606         /// Creates a PropertyType value.
1607         /// </summary>
1608         /// <param name="type">A PropertyType value.</param>
1609         /// <since_tizen> 3 </since_tizen>
1610         public PropertyValue(PropertyType type) : this(NDalicPINVOKE.new_Property_Value__SWIG_17((int)type), true)
1611         {
1612             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1613         }
1614
1615         /// <summary>
1616         /// Creates a PropertyValue value.
1617         /// </summary>
1618         /// <param name="value">A PropertyValue value.</param>
1619         /// <since_tizen> 3 </since_tizen>
1620         public PropertyValue(PropertyValue value) : this(NDalicPINVOKE.new_Property_Value__SWIG_18(PropertyValue.getCPtr(value)), true)
1621         {
1622             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1623         }
1624
1625         /// <summary>
1626         /// Queries the type of this property value.
1627         /// </summary>
1628         /// <returns>The type ID</returns>
1629         /// <since_tizen> 3 </since_tizen>
1630         public new PropertyType GetType()
1631         {
1632             PropertyType ret = (PropertyType)NDalicPINVOKE.Property_Value_GetType(swigCPtr);
1633             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1634             return ret;
1635         }
1636
1637         /// <summary>
1638         /// Retrieves a boolean value.
1639         /// </summary>
1640         /// <param name="boolValue">On return, a boolean value.</param>
1641         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1642         /// <since_tizen> 3 </since_tizen>
1643         public bool Get(out bool boolValue)
1644         {
1645             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_1(swigCPtr, out boolValue);
1646             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1647             return ret;
1648         }
1649
1650         /// <summary>
1651         /// Retrieves a floating-point value.
1652         /// </summary>
1653         /// <param name="floatValue">On return, a floating-point value.</param>
1654         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1655         /// <since_tizen> 3 </since_tizen>
1656         public bool Get(out float floatValue)
1657         {
1658             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_2(swigCPtr, out floatValue);
1659             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1660             return ret;
1661         }
1662
1663         /// <summary>
1664         /// Retrieves an integer value.
1665         /// </summary>
1666         /// <param name="integerValue">On return, an integer value.</param>
1667         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1668         /// <since_tizen> 3 </since_tizen>
1669         public bool Get(out int integerValue)
1670         {
1671             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_3(swigCPtr, out integerValue);
1672             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1673             return ret;
1674         }
1675
1676         /// <summary>
1677         /// Retrieves an integer rectangle.
1678         /// </summary>
1679         /// <param name="rect">On return, an integer rectangle.</param>
1680         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1681         /// <since_tizen> 3 </since_tizen>
1682         public bool Get(Rectangle rect)
1683         {
1684             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_4(swigCPtr, Rectangle.getCPtr(rect));
1685             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1686             return ret;
1687         }
1688
1689         /// <summary>
1690         /// Retrieves a vector value.
1691         /// </summary>
1692         /// <param name="vectorValue">On return, a vector value.</param>
1693         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1694         /// <since_tizen> 3 </since_tizen>
1695         public bool Get(Vector2 vectorValue)
1696         {
1697             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_5(swigCPtr, Vector2.getCPtr(vectorValue));
1698             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1699             return ret;
1700         }
1701
1702         /// <summary>
1703         /// Retrieves a vector value.
1704         /// </summary>
1705         /// <param name="vectorValue">On return, a vector value.</param>
1706         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1707         /// <since_tizen> 3 </since_tizen>
1708         public bool Get(Vector3 vectorValue)
1709         {
1710             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_6(swigCPtr, Vector3.getCPtr(vectorValue));
1711             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1712             return ret;
1713         }
1714
1715         /// <summary>
1716         /// Retrieves a vector value.
1717         /// </summary>
1718         /// <param name="vectorValue">On return, a vector value.</param>
1719         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1720         /// <since_tizen> 3 </since_tizen>
1721         public bool Get(Vector4 vectorValue)
1722         {
1723             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_7(swigCPtr, Vector4.getCPtr(vectorValue));
1724             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1725             return ret;
1726         }
1727
1728         /// <summary>
1729         /// Retrieves a vector value.
1730         /// </summary>
1731         /// <param name="vectorValue">On return, a vector value.</param>
1732         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1733         /// <since_tizen> 5 </since_tizen>
1734         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1735         [EditorBrowsable(EditorBrowsableState.Never)]
1736         public bool Get(RelativeVector2 vectorValue)
1737         {
1738             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_5(swigCPtr, RelativeVector2.getCPtr(vectorValue));
1739             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1740             return ret;
1741         }
1742
1743         /// <summary>
1744         /// Retrieves a vector value.
1745         /// </summary>
1746         /// <param name="vectorValue">On return, a vector value.</param>
1747         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1748         /// <since_tizen> 5 </since_tizen>
1749         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1750         [EditorBrowsable(EditorBrowsableState.Never)]
1751         public bool Get(RelativeVector3 vectorValue)
1752         {
1753             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_6(swigCPtr, RelativeVector3.getCPtr(vectorValue));
1754             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1755             return ret;
1756         }
1757
1758         /// <summary>
1759         /// Retrieves a vector value.
1760         /// </summary>
1761         /// <param name="vectorValue">On return, a vector value.</param>
1762         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1763         /// <since_tizen> 5 </since_tizen>
1764         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1765         [EditorBrowsable(EditorBrowsableState.Never)]
1766         public bool Get(RelativeVector4 vectorValue)
1767         {
1768             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_7(swigCPtr, RelativeVector4.getCPtr(vectorValue));
1769             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1770             return ret;
1771         }
1772
1773         internal bool Get(Matrix3 matrixValue)
1774         {
1775             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_8(swigCPtr, Matrix3.getCPtr(matrixValue));
1776             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1777             return ret;
1778         }
1779
1780         internal bool Get(Matrix matrixValue)
1781         {
1782             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_9(swigCPtr, Matrix.getCPtr(matrixValue));
1783             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1784             return ret;
1785         }
1786
1787         internal bool Get(AngleAxis angleAxisValue)
1788         {
1789             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_10(swigCPtr, AngleAxis.getCPtr(angleAxisValue));
1790             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1791             return ret;
1792         }
1793
1794         /// <summary>
1795         /// Retrieves a rotation value.
1796         /// </summary>
1797         /// <param name="quaternionValue">On return, a rotation value.</param>
1798         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1799         /// <since_tizen> 3 </since_tizen>
1800         public bool Get(Rotation quaternionValue)
1801         {
1802             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_11(swigCPtr, Rotation.getCPtr(quaternionValue));
1803             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1804             return ret;
1805         }
1806
1807         /// <summary>
1808         /// Retrieves a string property value.
1809         /// </summary>
1810         /// <param name="stringValue">On return, a string.</param>
1811         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1812         /// <since_tizen> 3 </since_tizen>
1813         public bool Get(out string stringValue)
1814         {
1815             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_12(swigCPtr, out stringValue);
1816             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1817             return ret;
1818         }
1819
1820         /// <summary>
1821         /// Retrieves an array property value.
1822         /// </summary>
1823         /// <param name="arrayValue">On return, the array as a vector property values.</param>
1824         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1825         /// <since_tizen> 3 </since_tizen>
1826         public bool Get(PropertyArray arrayValue)
1827         {
1828             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_13(swigCPtr, PropertyArray.getCPtr(arrayValue));
1829             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1830             return ret;
1831         }
1832
1833         /// <summary>
1834         /// Retrieves a map property value.
1835         /// </summary>
1836         /// <param name="mapValue">On return, the map as vector of string and property value pairs.</param>
1837         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1838         /// <since_tizen> 3 </since_tizen>
1839         public bool Get(PropertyMap mapValue)
1840         {
1841             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_14(swigCPtr, PropertyMap.getCPtr(mapValue));
1842             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1843             return ret;
1844         }
1845
1846         /// <summary>
1847         /// Retrieves a Extents value.
1848         /// </summary>
1849         /// <param name="extentsValue">On return, a extents.</param>
1850         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1851         /// <since_tizen> 4 </since_tizen>
1852         public bool Get(Extents extentsValue)
1853         {
1854             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_15(swigCPtr, Extents.getCPtr(extentsValue));
1855             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1856             return ret;
1857         }
1858     }
1859
1860     /// <summary>
1861     /// KeyValue class.
1862     /// </summary>
1863     public class KeyValue
1864     {
1865         private string _key = null;
1866         private object _originalValue = null;
1867         private object _originalKey = null;
1868
1869         /// <summary>
1870         /// Int key.
1871         /// </summary>
1872         public int? KeyInt = null;
1873
1874         /// <summary>
1875         /// String key.
1876         /// </summary>
1877         public string KeyString = null;
1878
1879         /// <summary>
1880         /// True value.
1881         /// </summary>
1882         public PropertyValue TrueValue = null;
1883
1884         /// <summary>
1885         /// Default Constructor.
1886         /// </summary>
1887         public KeyValue()
1888         {}
1889
1890         /// <summary>
1891         /// Key property.
1892         /// </summary>
1893         public string Key
1894         {
1895             get
1896             {
1897                 return _key;
1898             }
1899             set
1900             {
1901                 _key = value;
1902                 ParseKey(value);
1903             }
1904         }
1905
1906         /// <summary>
1907         /// OriginalKey property.
1908         /// </summary>
1909         public object OriginalKey
1910         {
1911             get
1912             {
1913                 return _originalKey;
1914             }
1915             set
1916             {
1917                 _originalKey = value;
1918                 if (value is int || value is Int32)
1919                 {
1920                     KeyInt = (int)value;
1921                 }
1922                 else if (value is string)
1923                 {
1924                     KeyString = value.ToString();
1925                 }
1926                 else if (value.GetType().Equals(typeof(int)) || value.GetType().Equals(typeof(Int32)))
1927                 {
1928                     KeyInt = (int)value;
1929                 }
1930                 else if (value.GetType().Equals(typeof(string)))
1931                 {
1932                     KeyString = value.ToString();
1933                 }
1934             }
1935         }
1936
1937         /// <summary>
1938         /// Value property.
1939         /// </summary>
1940         public object Value
1941         {
1942             get
1943             {
1944                 return _originalValue;
1945             }
1946             set
1947             {
1948                 _originalValue = value;
1949                 TrueValue = PropertyValue.CreateFromObject(value);
1950             }
1951         }
1952
1953         /// <summary>
1954         /// IntergerValue property.
1955         /// </summary>
1956         public int IntergerValue
1957         {
1958             set
1959             {
1960                 TrueValue = new PropertyValue(value);
1961             }
1962         }
1963
1964         /// <summary>
1965         /// BooleanValue property.
1966         /// </summary>
1967         public bool BooleanValue
1968         {
1969             set
1970             {
1971                 TrueValue = new PropertyValue(value);
1972             }
1973         }
1974
1975         /// <summary>
1976         /// SingleValue property.
1977         /// </summary>
1978         public float SingleValue
1979         {
1980             set
1981             {
1982                 TrueValue = new PropertyValue(value);
1983             }
1984         }
1985
1986         /// <summary>
1987         /// StringValue property.
1988         /// </summary>
1989         public string StringValue
1990         {
1991             set
1992             {
1993                 TrueValue = new PropertyValue(value);
1994             }
1995         }
1996
1997         /// <summary>
1998         /// Vector2Value property.
1999         /// </summary>
2000         public Vector2 Vector2Value
2001         {
2002             set
2003             {
2004                 TrueValue = new PropertyValue(value);
2005             }
2006         }
2007
2008         /// <summary>
2009         /// Vector3Value property.
2010         /// </summary>
2011         public Vector3 Vector3Value
2012         {
2013             set
2014             {
2015                 TrueValue = new PropertyValue(value);
2016             }
2017         }
2018
2019         /// <summary>
2020         /// Vector4Value property.
2021         /// </summary>
2022         public Vector4 Vector4Value
2023         {
2024             set
2025             {
2026                 TrueValue = new PropertyValue(value);
2027             }
2028         }
2029
2030         /// <summary>
2031         /// PositionValue property.
2032         /// </summary>
2033         public Position PositionValue
2034         {
2035             set
2036             {
2037                 TrueValue = new PropertyValue(value);
2038             }
2039         }
2040
2041         /// <summary>
2042         /// Position2DValue property.
2043         /// </summary>
2044         public Position2D Position2DValue
2045         {
2046             set
2047             {
2048                 TrueValue = new PropertyValue(value);
2049             }
2050         }
2051
2052         /// <summary>
2053         /// SizeValue property.
2054         /// </summary>
2055         public Size SizeValue
2056         {
2057             set
2058             {
2059                 TrueValue = new PropertyValue(value);
2060             }
2061         }
2062
2063         /// <summary>
2064         /// Size2DValue property.
2065         /// </summary>
2066         public Size2D Size2DValue
2067         {
2068             set
2069             {
2070                 TrueValue = new PropertyValue(value);
2071             }
2072         }
2073
2074         /// <summary>
2075         /// ColorValue property.
2076         /// </summary>
2077         public Color ColorValue
2078         {
2079             set
2080             {
2081                 TrueValue = new PropertyValue(value);
2082             }
2083         }
2084
2085         /// <summary>
2086         /// RectangleValue property.
2087         /// </summary>
2088         public Rectangle RectangleValue
2089         {
2090             set
2091             {
2092                 TrueValue = new PropertyValue(value);
2093             }
2094         }
2095
2096         /// <summary>
2097         /// RotationValue property.
2098         /// </summary>
2099         public Rotation RotationValue
2100         {
2101             set
2102             {
2103                 TrueValue = new PropertyValue(value);
2104             }
2105         }
2106
2107         /// <summary>
2108         /// RelativeVector2Value property.
2109         /// </summary>
2110         public RelativeVector2 RelativeVector2Value
2111         {
2112             set
2113             {
2114                 TrueValue = new PropertyValue(value);
2115             }
2116         }
2117
2118         /// <summary>
2119         /// RelativeVector3Value property.
2120         /// </summary>
2121         public RelativeVector3 RelativeVector3Value
2122         {
2123             set
2124             {
2125                 TrueValue = new PropertyValue(value);
2126             }
2127         }
2128
2129         /// <summary>
2130         /// RelativeVector4Value property.
2131         /// </summary>
2132         public RelativeVector4 RelativeVector4Value
2133         {
2134             set
2135             {
2136                 TrueValue = new PropertyValue(value);
2137             }
2138         }
2139
2140         /// <summary>
2141         /// ExtentsValue property.
2142         /// </summary>
2143         public Extents ExtentsValue
2144         {
2145             set
2146             {
2147                 TrueValue = new PropertyValue(value);
2148             }
2149         }
2150
2151         /// <summary>
2152         /// PropertyArrayValue property.
2153         /// </summary>
2154         public PropertyArray PropertyArrayValue
2155         {
2156             set
2157             {
2158                 TrueValue = new PropertyValue(value);
2159             }
2160         }
2161
2162         /// <summary>
2163         /// PropertyMapValue property.
2164         /// </summary>
2165         public PropertyMap PropertyMapValue
2166         {
2167             set
2168             {
2169                 TrueValue = new PropertyValue(value);
2170             }
2171         }
2172
2173         private void ParseKey(string key)
2174         {
2175             int v = -1;
2176             if (VisualExtension.KeyDictionary.ContainsKey(key))
2177             {
2178                 VisualExtension.KeyDictionary.TryGetValue(key, out v);
2179                 KeyInt = v;
2180             }
2181             else
2182             {
2183                 KeyString = Key;
2184             }
2185         }
2186     }
2187 }