Add ScriptUI to support XAML file (#320)
[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         internal bool Get(Size vectorValue)
1427         {
1428             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_6(swigCPtr, Size.getCPtr(vectorValue));
1429             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1430             return ret;
1431         }
1432
1433         /// <summary>
1434         /// Retrieves a Position value.
1435         /// </summary>
1436         /// <param name="vectorValue"> On return, a position value.</param>
1437         /// <since_tizen> 3 </since_tizen>
1438         public bool Get(Position vectorValue)
1439         {
1440             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_6(swigCPtr, Position.getCPtr(vectorValue));
1441             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1442             return ret;
1443         }
1444
1445         /// <summary>
1446         /// Retrieves a Color value.
1447         /// </summary>
1448         /// <param name="vectorValue"> On return, a color value.</param>
1449         /// <since_tizen> 3 </since_tizen>
1450         public bool Get(Color vectorValue)
1451         {
1452             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_7(swigCPtr, Color.getCPtr(vectorValue));
1453             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1454             return ret;
1455         }
1456
1457
1458
1459         /// <summary>
1460         /// The default constructor.
1461         /// </summary>
1462         /// <since_tizen> 3 </since_tizen>
1463         public PropertyValue() : this(NDalicPINVOKE.new_Property_Value__SWIG_0(), true)
1464         {
1465             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1466         }
1467
1468         /// <summary>
1469         /// Creates a boolean property value.
1470         /// </summary>
1471         /// <param name="boolValue">A boolean value.</param>
1472         /// <since_tizen> 3 </since_tizen>
1473         public PropertyValue(bool boolValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_1(boolValue), true)
1474         {
1475             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1476         }
1477
1478         /// <summary>
1479         /// Creates an integer property value.
1480         /// </summary>
1481         /// <param name="integerValue">An integer value.</param>
1482         /// <since_tizen> 3 </since_tizen>
1483         public PropertyValue(int integerValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_2(integerValue), true)
1484         {
1485             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1486         }
1487
1488         /// <summary>
1489         /// Creates a float property value.
1490         /// </summary>
1491         /// <param name="floatValue">A floating-point value.</param>
1492         /// <since_tizen> 3 </since_tizen>
1493         public PropertyValue(float floatValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_3(floatValue), true)
1494         {
1495             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1496         }
1497
1498         /// <summary>
1499         /// Creates a Vector2 property value.
1500         /// </summary>
1501         /// <param name="vectorValue">A vector of 2 floating-point values.</param>
1502         /// <since_tizen> 3 </since_tizen>
1503         public PropertyValue(Vector2 vectorValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_4(Vector2.getCPtr(vectorValue)), true)
1504         {
1505             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1506         }
1507
1508         /// <summary>
1509         /// Creates a Vector3 property value.
1510         /// </summary>
1511         /// <param name="vectorValue">A vector of 3 floating-point values.</param>
1512         /// <since_tizen> 3 </since_tizen>
1513         public PropertyValue(Vector3 vectorValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_5(Vector3.getCPtr(vectorValue)), true)
1514         {
1515             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1516         }
1517
1518         /// <summary>
1519         /// Creates a Vector4 property value.
1520         /// </summary>
1521         /// <param name="vectorValue">A vector of 4 floating-point values.</param>
1522         /// <since_tizen> 3 </since_tizen>
1523         public PropertyValue(Vector4 vectorValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_6(Vector4.getCPtr(vectorValue)), true)
1524         {
1525             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1526         }
1527
1528         internal PropertyValue(Matrix3 matrixValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_7(Matrix3.getCPtr(matrixValue)), true)
1529         {
1530             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1531         }
1532
1533         internal PropertyValue(Matrix matrixValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_8(Matrix.getCPtr(matrixValue)), true)
1534         {
1535             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1536         }
1537
1538         /// <summary>
1539         /// Creates a Rectangle property value.
1540         /// </summary>
1541         /// <param name="vectorValue">Rectangle values.</param>
1542         /// <since_tizen> 3 </since_tizen>
1543         public PropertyValue(Rectangle vectorValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_9(Rectangle.getCPtr(vectorValue)), true)
1544         {
1545             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1546         }
1547
1548         internal PropertyValue(AngleAxis angleAxis) : this(NDalicPINVOKE.new_Property_Value__SWIG_10(AngleAxis.getCPtr(angleAxis)), true)
1549         {
1550             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1551         }
1552
1553         /// <summary>
1554         /// Creates a Rotation property value.
1555         /// </summary>
1556         /// <param name="quaternion">Rotation values.</param>
1557         /// <since_tizen> 3 </since_tizen>
1558         public PropertyValue(Rotation quaternion) : this(NDalicPINVOKE.new_Property_Value__SWIG_11(Rotation.getCPtr(quaternion)), true)
1559         {
1560             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1561         }
1562
1563         /// <summary>
1564         /// Creates a string property value.
1565         /// </summary>
1566         /// <param name="stringValue">A string.</param>
1567         /// <since_tizen> 3 </since_tizen>
1568         public PropertyValue(string stringValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_12(stringValue), true)
1569         {
1570             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1571         }
1572
1573         /// <summary>
1574         /// Creates an array property value.
1575         /// </summary>
1576         /// <param name="arrayValue">An array.</param>
1577         /// <since_tizen> 3 </since_tizen>
1578         public PropertyValue(PropertyArray arrayValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_14(PropertyArray.getCPtr(arrayValue)), true)
1579         {
1580             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1581         }
1582
1583         /// <summary>
1584         /// Creates a map property value.
1585         /// </summary>
1586         /// <param name="mapValue">An array.</param>
1587         /// <since_tizen> 3 </since_tizen>
1588         public PropertyValue(PropertyMap mapValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_15(PropertyMap.getCPtr(mapValue)), true)
1589         {
1590             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1591         }
1592
1593         /// <summary>
1594         /// Creates a Extents value.
1595         /// </summary>
1596         /// <param name="extentsValue">A Extents value.</param>
1597         /// <since_tizen> 4 </since_tizen>
1598         public PropertyValue(Extents extentsValue) : this(NDalicPINVOKE.new_Property_Value__SWIG_16(Extents.getCPtr(extentsValue)), true)
1599         {
1600             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1601         }
1602
1603         /// <summary>
1604         /// Creates a PropertyType value.
1605         /// </summary>
1606         /// <param name="type">A PropertyType value.</param>
1607         /// <since_tizen> 3 </since_tizen>
1608         public PropertyValue(PropertyType type) : this(NDalicPINVOKE.new_Property_Value__SWIG_17((int)type), true)
1609         {
1610             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1611         }
1612
1613         /// <summary>
1614         /// Creates a PropertyValue value.
1615         /// </summary>
1616         /// <param name="value">A PropertyValue value.</param>
1617         /// <since_tizen> 3 </since_tizen>
1618         public PropertyValue(PropertyValue value) : this(NDalicPINVOKE.new_Property_Value__SWIG_18(PropertyValue.getCPtr(value)), true)
1619         {
1620             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1621         }
1622
1623         /// <summary>
1624         /// Queries the type of this property value.
1625         /// </summary>
1626         /// <returns>The type ID</returns>
1627         /// <since_tizen> 3 </since_tizen>
1628         public new PropertyType GetType()
1629         {
1630             PropertyType ret = (PropertyType)NDalicPINVOKE.Property_Value_GetType(swigCPtr);
1631             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1632             return ret;
1633         }
1634
1635         /// <summary>
1636         /// Retrieves a boolean value.
1637         /// </summary>
1638         /// <param name="boolValue">On return, a boolean value.</param>
1639         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1640         /// <since_tizen> 3 </since_tizen>
1641         public bool Get(out bool boolValue)
1642         {
1643             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_1(swigCPtr, out boolValue);
1644             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1645             return ret;
1646         }
1647
1648         /// <summary>
1649         /// Retrieves a floating-point value.
1650         /// </summary>
1651         /// <param name="floatValue">On return, a floating-point value.</param>
1652         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1653         /// <since_tizen> 3 </since_tizen>
1654         public bool Get(out float floatValue)
1655         {
1656             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_2(swigCPtr, out floatValue);
1657             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1658             return ret;
1659         }
1660
1661         /// <summary>
1662         /// Retrieves an integer value.
1663         /// </summary>
1664         /// <param name="integerValue">On return, an integer value.</param>
1665         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1666         /// <since_tizen> 3 </since_tizen>
1667         public bool Get(out int integerValue)
1668         {
1669             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_3(swigCPtr, out integerValue);
1670             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1671             return ret;
1672         }
1673
1674         /// <summary>
1675         /// Retrieves an integer rectangle.
1676         /// </summary>
1677         /// <param name="rect">On return, an integer rectangle.</param>
1678         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1679         /// <since_tizen> 3 </since_tizen>
1680         public bool Get(Rectangle rect)
1681         {
1682             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_4(swigCPtr, Rectangle.getCPtr(rect));
1683             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1684             return ret;
1685         }
1686
1687         /// <summary>
1688         /// Retrieves a vector value.
1689         /// </summary>
1690         /// <param name="vectorValue">On return, a vector value.</param>
1691         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1692         /// <since_tizen> 3 </since_tizen>
1693         public bool Get(Vector2 vectorValue)
1694         {
1695             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_5(swigCPtr, Vector2.getCPtr(vectorValue));
1696             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1697             return ret;
1698         }
1699
1700         /// <summary>
1701         /// Retrieves a vector value.
1702         /// </summary>
1703         /// <param name="vectorValue">On return, a vector value.</param>
1704         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1705         /// <since_tizen> 3 </since_tizen>
1706         public bool Get(Vector3 vectorValue)
1707         {
1708             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_6(swigCPtr, Vector3.getCPtr(vectorValue));
1709             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1710             return ret;
1711         }
1712
1713         /// <summary>
1714         /// Retrieves a vector value.
1715         /// </summary>
1716         /// <param name="vectorValue">On return, a vector value.</param>
1717         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1718         /// <since_tizen> 3 </since_tizen>
1719         public bool Get(Vector4 vectorValue)
1720         {
1721             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_7(swigCPtr, Vector4.getCPtr(vectorValue));
1722             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1723             return ret;
1724         }
1725
1726         internal bool Get(Matrix3 matrixValue)
1727         {
1728             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_8(swigCPtr, Matrix3.getCPtr(matrixValue));
1729             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1730             return ret;
1731         }
1732
1733         internal bool Get(Matrix matrixValue)
1734         {
1735             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_9(swigCPtr, Matrix.getCPtr(matrixValue));
1736             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1737             return ret;
1738         }
1739
1740         internal bool Get(AngleAxis angleAxisValue)
1741         {
1742             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_10(swigCPtr, AngleAxis.getCPtr(angleAxisValue));
1743             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1744             return ret;
1745         }
1746
1747         /// <summary>
1748         /// Retrieves a Rotation value.
1749         /// </summary>
1750         /// <param name="quaternionValue">On return, a rotation value.</param>
1751         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1752         /// <since_tizen> 3 </since_tizen>
1753         public bool Get(Rotation quaternionValue)
1754         {
1755             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_11(swigCPtr, Rotation.getCPtr(quaternionValue));
1756             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1757             return ret;
1758         }
1759
1760         /// <summary>
1761         /// Retrieves a string property value.
1762         /// </summary>
1763         /// <param name="stringValue">On return, a string.</param>
1764         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1765         /// <since_tizen> 3 </since_tizen>
1766         public bool Get(out string stringValue)
1767         {
1768             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_12(swigCPtr, out stringValue);
1769             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1770             return ret;
1771         }
1772
1773         /// <summary>
1774         /// Retrieves an array property value.
1775         /// </summary>
1776         /// <param name="arrayValue">On return, the array as a vector property values.</param>
1777         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1778         /// <since_tizen> 3 </since_tizen>
1779         public bool Get(PropertyArray arrayValue)
1780         {
1781             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_13(swigCPtr, PropertyArray.getCPtr(arrayValue));
1782             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1783             return ret;
1784         }
1785
1786         /// <summary>
1787         /// Retrieves a map property value.
1788         /// </summary>
1789         /// <param name="mapValue">On return, the map as vector of string and property value pairs.</param>
1790         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1791         /// <since_tizen> 3 </since_tizen>
1792         public bool Get(PropertyMap mapValue)
1793         {
1794             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_14(swigCPtr, PropertyMap.getCPtr(mapValue));
1795             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1796             return ret;
1797         }
1798
1799         /// <summary>
1800         /// Retrieves a Extents value.
1801         /// </summary>
1802         /// <param name="extentsValue">On return, a extents.</param>
1803         /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1804         /// <since_tizen> 4 </since_tizen>
1805         public bool Get(Extents extentsValue)
1806         {
1807             bool ret = NDalicPINVOKE.Property_Value_Get__SWIG_15(swigCPtr, Extents.getCPtr(extentsValue));
1808             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1809             return ret;
1810         }
1811     }
1812
1813     /// <summary>
1814     /// KeyValue class.
1815     /// </summary>
1816     public class KeyValue
1817     {
1818         private string _key = null;
1819         private object _originalValue = null;
1820         private object _originalKey = null;
1821
1822         /// <summary>
1823         /// Int key.
1824         /// </summary>
1825         public int? KeyInt = null;
1826
1827         /// <summary>
1828         /// String key.
1829         /// </summary>
1830         public string KeyString = null;
1831
1832         /// <summary>
1833         /// True value.
1834         /// </summary>
1835         public PropertyValue TrueValue = null;
1836
1837         /// <summary>
1838         /// Default Constructor.
1839         /// </summary>
1840         public KeyValue()
1841         {}
1842
1843         /// <summary>
1844         /// Key property.
1845         /// </summary>
1846         public string Key
1847         {
1848             get
1849             {
1850                 return _key;
1851             }
1852             set
1853             {
1854                 _key = value;
1855                 ParseKey(value);
1856             }
1857         }
1858
1859         /// <summary>
1860         /// OriginalKey property.
1861         /// </summary>
1862         public object OriginalKey
1863         {
1864             get
1865             {
1866                 return _originalKey;
1867             }
1868             set
1869             {
1870                 _originalKey = value;
1871                 if (value is int || value is Int32)
1872                 {
1873                     KeyInt = (int)value;
1874                 }
1875                 if (value is string)
1876                 {
1877                     KeyString = value.ToString();
1878                 }
1879
1880
1881                 if (value.GetType().Equals(typeof(int)) || value.GetType().Equals(typeof(Int32)))
1882                 {
1883                     KeyInt = (int)value;
1884                 }
1885                 else if (value.GetType().Equals(typeof(string)))
1886                 {
1887                     KeyString = value.ToString();
1888                 }
1889                 KeyInt = (int)value;
1890             }
1891         }
1892
1893         /// <summary>
1894         /// Value property.
1895         /// </summary>
1896         public object Value
1897         {
1898             get
1899             {
1900                 return _originalValue;
1901             }
1902             set
1903             {
1904                 _originalValue = value;
1905                 TrueValue = PropertyValue.CreateFromObject(value);
1906             }
1907         }
1908
1909         /// <summary>
1910         /// IntergerValue property.
1911         /// </summary>
1912         public int IntergerValue
1913         {
1914             set
1915             {
1916                 TrueValue = new PropertyValue(value);
1917             }
1918         }
1919
1920         /// <summary>
1921         /// BooleanValue property.
1922         /// </summary>
1923         public bool BooleanValue
1924         {
1925             set
1926             {
1927                 TrueValue = new PropertyValue(value);
1928             }
1929         }
1930
1931         /// <summary>
1932         /// SingleValue property.
1933         /// </summary>
1934         public float SingleValue
1935         {
1936             set
1937             {
1938                 TrueValue = new PropertyValue(value);
1939             }
1940         }
1941
1942         /// <summary>
1943         /// StringValue property.
1944         /// </summary>
1945         public string StringValue
1946         {
1947             set
1948             {
1949                 TrueValue = new PropertyValue(value);
1950             }
1951         }
1952
1953         /// <summary>
1954         /// Vector2Value property.
1955         /// </summary>
1956         public Vector2 Vector2Value
1957         {
1958             set
1959             {
1960                 TrueValue = new PropertyValue(value);
1961             }
1962         }
1963
1964         /// <summary>
1965         /// Vector3Value property.
1966         /// </summary>
1967         public Vector3 Vector3Value
1968         {
1969             set
1970             {
1971                 TrueValue = new PropertyValue(value);
1972             }
1973         }
1974
1975         /// <summary>
1976         /// Vector4Value property.
1977         /// </summary>
1978         public Vector4 Vector4Value
1979         {
1980             set
1981             {
1982                 TrueValue = new PropertyValue(value);
1983             }
1984         }
1985
1986         /// <summary>
1987         /// PositionValue property.
1988         /// </summary>
1989         public Position PositionValue
1990         {
1991             set
1992             {
1993                 TrueValue = new PropertyValue(value);
1994             }
1995         }
1996
1997         /// <summary>
1998         /// Position2DValue property.
1999         /// </summary>
2000         public Position2D Position2DValue
2001         {
2002             set
2003             {
2004                 TrueValue = new PropertyValue(value);
2005             }
2006         }
2007
2008         /// <summary>
2009         /// SizeValue property.
2010         /// </summary>
2011         public Size SizeValue
2012         {
2013             set
2014             {
2015                 TrueValue = new PropertyValue(value);
2016             }
2017         }
2018
2019         /// <summary>
2020         /// Size2DValue property.
2021         /// </summary>
2022         public Size2D Size2DValue
2023         {
2024             set
2025             {
2026                 TrueValue = new PropertyValue(value);
2027             }
2028         }
2029
2030         /// <summary>
2031         /// ColorValue property.
2032         /// </summary>
2033         public Color ColorValue
2034         {
2035             set
2036             {
2037                 TrueValue = new PropertyValue(value);
2038             }
2039         }
2040
2041         /// <summary>
2042         /// RectangleValue property.
2043         /// </summary>
2044         public Rectangle RectangleValue
2045         {
2046             set
2047             {
2048                 TrueValue = new PropertyValue(value);
2049             }
2050         }
2051
2052         /// <summary>
2053         /// RotationValue property.
2054         /// </summary>
2055         public Rotation RotationValue
2056         {
2057             set
2058             {
2059                 TrueValue = new PropertyValue(value);
2060             }
2061         }
2062
2063         /// <summary>
2064         /// RelativeVector2Value property.
2065         /// </summary>
2066         public RelativeVector2 RelativeVector2Value
2067         {
2068             set
2069             {
2070                 TrueValue = new PropertyValue(value);
2071             }
2072         }
2073
2074         /// <summary>
2075         /// RelativeVector3Value property.
2076         /// </summary>
2077         public RelativeVector3 RelativeVector3Value
2078         {
2079             set
2080             {
2081                 TrueValue = new PropertyValue(value);
2082             }
2083         }
2084
2085         /// <summary>
2086         /// RelativeVector4Value property.
2087         /// </summary>
2088         public RelativeVector4 RelativeVector4Value
2089         {
2090             set
2091             {
2092                 TrueValue = new PropertyValue(value);
2093             }
2094         }
2095
2096         /// <summary>
2097         /// ExtentsValue property.
2098         /// </summary>
2099         public Extents ExtentsValue
2100         {
2101             set
2102             {
2103                 TrueValue = new PropertyValue(value);
2104             }
2105         }
2106
2107         /// <summary>
2108         /// PropertyArrayValue property.
2109         /// </summary>
2110         public PropertyArray PropertyArrayValue
2111         {
2112             set
2113             {
2114                 TrueValue = new PropertyValue(value);
2115             }
2116         }
2117
2118         /// <summary>
2119         /// PropertyMapValue property.
2120         /// </summary>
2121         public PropertyMap PropertyMapValue
2122         {
2123             set
2124             {
2125                 TrueValue = new PropertyValue(value);
2126             }
2127         }
2128
2129         private void ParseKey(string key)
2130         {
2131             int v = -1;
2132             if (VisualExtension.KeyDictionary.ContainsKey(key))
2133             {
2134                 VisualExtension.KeyDictionary.TryGetValue(key, out v);
2135                 KeyInt = v;
2136             }
2137             else
2138             {
2139                 KeyString = Key;
2140             }
2141         }
2142     }
2143 }