2 * Copyright(c) 2017 Samsung Electronics Co., Ltd.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
19 using System.ComponentModel;
20 using System.Collections.Generic;
21 using Tizen.NUI.Binding;
26 /// An array of property values.
28 /// <since_tizen> 3 </since_tizen>
29 public class PropertyArray : Disposable
34 /// <since_tizen> 3 </since_tizen>
35 protected bool swigCMemOwn;
36 private global::System.Runtime.InteropServices.HandleRef swigCPtr;
41 /// <since_tizen> 3 </since_tizen>
42 public PropertyArray() : this(Interop.Property.new_Property_Array__SWIG_0(), true)
44 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
47 internal PropertyArray(PropertyArray other) : this(Interop.Property.new_Property_Array__SWIG_1(PropertyArray.getCPtr(other)), true)
49 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
52 internal PropertyArray(global::System.IntPtr cPtr, bool cMemoryOwn)
54 swigCMemOwn = cMemoryOwn;
55 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
59 /// The operator to access an element.
61 /// <param name="index">The element index to access. No bounds checking is performed.</param>
62 /// <returns>The reference to the element.</returns>
63 /// <since_tizen> 3 </since_tizen>
64 public PropertyValue this[uint index]
68 return ValueOfIndex(index);
73 /// Retrieves the number of elements in the array.
75 /// <returns>The number of elements in the array.</returns>
76 /// <since_tizen> 3 </since_tizen>
79 uint ret = Interop.Property.Property_Array_Size(swigCPtr);
80 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
85 /// Retrieves the number of elements in the array.
87 /// <returns>The number of elements in the array.</returns>
88 /// <since_tizen> 3 </since_tizen>
91 uint ret = Interop.Property.Property_Array_Count(swigCPtr);
92 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
97 /// Returns whether the array is empty.
99 /// <returns>Returns true if empty, false otherwise.</returns>
100 /// <since_tizen> 3 </since_tizen>
103 bool ret = Interop.Property.Property_Array_Empty(swigCPtr);
104 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
109 /// Clears the array.
111 /// <since_tizen> 3 </since_tizen>
114 Interop.Property.Property_Array_Clear(swigCPtr);
115 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
119 /// Increases the capacity of the array.
121 /// <param name="size">The size to reserve.</param>
122 /// <since_tizen> 3 </since_tizen>
123 public void Reserve(uint size)
125 Interop.Property.Property_Array_Reserve(swigCPtr, size);
126 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
132 /// <param name="size">The size to resize</param>
133 /// <since_tizen> 3 </since_tizen>
134 public void Resize(uint size)
136 Interop.Property.Property_Array_Resize(swigCPtr, size);
137 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
141 /// Retrieves the capacity of the array.
143 /// <returns>The allocated capacity of the array.</returns>
144 /// <since_tizen> 3 </since_tizen>
145 public uint Capacity()
147 uint ret = Interop.Property.Property_Array_Capacity(swigCPtr);
148 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
153 /// Adds an element to the array.
155 /// <param name="value">The value to add at the end of the array.</param>
156 /// <since_tizen> 3 </since_tizen>
157 public void PushBack(PropertyValue value)
159 Interop.Property.Property_Array_PushBack(swigCPtr, PropertyValue.getCPtr(value));
160 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
164 /// Adds an keyvalue to the array.
165 /// This function should be first
167 /// <param name="value">The value to add at the end of the array.</param>
168 public PropertyArray Add(KeyValue value)
170 PropertyArray ret = new PropertyArray(Interop.Property.Property_Array_Add(swigCPtr, PropertyValue.getCPtr(value.TrueValue)), false);
171 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
176 /// Adds an element to the array.
178 /// <param name="value">The value to add at the end of the array.</param>
179 /// <since_tizen> 3 </since_tizen>
180 public PropertyArray Add(PropertyValue value)
182 PropertyArray ret = new PropertyArray(Interop.Property.Property_Array_Add(swigCPtr, PropertyValue.getCPtr(value)), false);
183 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
188 /// Accesses an element.
190 /// <param name="index">The element index to access. No bounds checking is performed.</param>
191 /// <returns>The reference to the element.</returns>
192 /// <since_tizen> 3 </since_tizen>
193 public PropertyValue GetElementAt(uint index)
195 PropertyValue ret = new PropertyValue(Interop.Property.Property_Array_GetElementAt__SWIG_0(swigCPtr, index), false);
196 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
200 internal static global::System.Runtime.InteropServices.HandleRef getCPtr(PropertyArray obj)
202 return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
208 /// <since_tizen> 3 </since_tizen>
209 protected override void Dispose(DisposeTypes type)
216 //Release your own unmanaged resources here.
217 //You should not access any managed member here except static instance.
218 //because the execution order of Finalizes is non-deterministic.
220 if (swigCPtr.Handle != global::System.IntPtr.Zero)
225 Interop.Property.delete_Property_Array(swigCPtr);
227 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
233 /// Retrieves the value of elements in the array.
235 /// <param name="index">The element index to retrieve.</param>
236 /// <returns>The reference to the element.</returns>
237 private PropertyValue ValueOfIndex(uint index)
239 PropertyValue ret = new PropertyValue(Interop.Property.Property_Array_ValueOfIndex__SWIG_0(swigCPtr, index), false);
240 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
246 /// A key type which can be either a std::string or a Property::Index.
248 /// <since_tizen> 3 </since_tizen>
249 public class PropertyKey : Disposable
254 /// <since_tizen> 3 </since_tizen>
255 protected bool swigCMemOwn;
256 private global::System.Runtime.InteropServices.HandleRef swigCPtr;
261 /// <param name="key">The string key.</param>
262 /// <since_tizen> 3 </since_tizen>
263 public PropertyKey(string key) : this(Interop.Property.new_Property_Key__SWIG_0(key), true)
265 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
271 /// <param name="key">The index key.</param>
272 /// <since_tizen> 3 </since_tizen>
273 public PropertyKey(int key) : this(Interop.Property.new_Property_Key__SWIG_1(key), true)
275 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
278 internal PropertyKey(global::System.IntPtr cPtr, bool cMemoryOwn)
280 swigCMemOwn = cMemoryOwn;
281 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
287 /// <since_tizen> 3 </since_tizen>
291 /// The type of key is index.
293 /// <since_tizen> 3 </since_tizen>
296 /// The type of key is string.
298 /// <since_tizen> 3 </since_tizen>
303 /// The type of the key.
305 /// <since_tizen> 3 </since_tizen>
306 public PropertyKey.KeyType Type
310 Interop.Property.Property_Key_type_set(swigCPtr, (int)value);
311 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
315 PropertyKey.KeyType ret = (PropertyKey.KeyType)Interop.Property.Property_Key_type_get(swigCPtr);
316 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
324 /// <since_tizen> 3 </since_tizen>
329 Interop.Property.Property_Key_indexKey_set(swigCPtr, value);
330 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
334 int ret = Interop.Property.Property_Key_indexKey_get(swigCPtr);
335 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
343 /// <since_tizen> 3 </since_tizen>
344 public string StringKey
348 Interop.Property.Property_Key_stringKey_set(swigCPtr, value);
349 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
353 string ret = Interop.Property.Property_Key_stringKey_get(swigCPtr);
354 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
360 /// Compares if rhs is equal to.
362 /// <param name="rhs">A string key to compare against.</param>
363 /// <returns>Returns true if the key compares, or false if it isn't equal or of the wrong type.</returns>
364 /// <since_tizen> 3 </since_tizen>
365 public bool EqualTo(string rhs)
367 bool ret = Interop.Property.Property_Key_EqualTo__SWIG_0(swigCPtr, rhs);
368 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
373 /// Compares if rhs is equal to.
375 /// <param name="rhs">The index key to compare against.</param>
376 /// <returns>Returns true if the key compares, or false if it isn't equal or of the wrong type.</returns>
377 /// <since_tizen> 3 </since_tizen>
378 public bool EqualTo(int rhs)
380 bool ret = Interop.Property.Property_Key_EqualTo__SWIG_1(swigCPtr, rhs);
381 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
386 /// Compares if rhs is equal to
388 /// <param name="rhs">A key to compare against</param>
389 /// <returns>Returns true if the keys are of the same type and have the same value.</returns>
390 /// <since_tizen> 3 </since_tizen>
391 public bool EqualTo(PropertyKey rhs)
393 bool ret = Interop.Property.Property_Key_EqualTo__SWIG_2(swigCPtr, PropertyKey.getCPtr(rhs));
394 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
399 /// Compares if rhs is not equal to.
401 /// <param name="rhs">The index key to compare against.</param>
402 /// <returns>Returns true if the key is not equal or not a string key.</returns>
403 /// <since_tizen> 3 </since_tizen>
404 public bool NotEqualTo(string rhs)
406 bool ret = Interop.Property.Property_Key_NotEqualTo__SWIG_0(swigCPtr, rhs);
407 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
412 /// Compares if rhs is not equal to.
414 /// <param name="rhs">The index key to compare against.</param>
415 /// <returns>Returns true if the key is not equal, or not the index key.</returns>
416 /// <since_tizen> 3 </since_tizen>
417 public bool NotEqualTo(int rhs)
419 bool ret = Interop.Property.Property_Key_NotEqualTo__SWIG_1(swigCPtr, rhs);
420 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
425 /// Compares if rhs is not equal to.
427 /// <param name="rhs">A key to compare against.</param>
428 /// <returns>Returns true if the keys are not of the same type or are not equal.</returns>
429 /// <since_tizen> 3 </since_tizen>
430 public bool NotEqualTo(PropertyKey rhs)
432 bool ret = Interop.Property.Property_Key_NotEqualTo__SWIG_2(swigCPtr, PropertyKey.getCPtr(rhs));
433 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
437 internal static global::System.Runtime.InteropServices.HandleRef getCPtr(PropertyKey obj)
439 return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
445 /// <since_tizen> 3 </since_tizen>
446 protected override void Dispose(DisposeTypes type)
453 //Release your own unmanaged resources here.
454 //You should not access any managed member here except static instance.
455 //because the execution order of Finalizes is non-deterministic.
457 if (swigCPtr.Handle != global::System.IntPtr.Zero)
462 Interop.Property.delete_Property_Key(swigCPtr);
464 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
471 /// A map of property values, the key type could be string or Property::Index.
473 /// <since_tizen> 3 </since_tizen>
474 public class PropertyMap : Disposable
479 /// <since_tizen> 3 </since_tizen>
480 protected bool swigCMemOwn;
481 private global::System.Runtime.InteropServices.HandleRef swigCPtr;
486 /// <since_tizen> 3 </since_tizen>
487 public PropertyMap() : this(Interop.PropertyMap.new_Property_Map__SWIG_0(), true)
489 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
493 /// The copy constructor.
495 /// <param name="other">The map to copy from.</param>
496 /// <since_tizen> 3 </since_tizen>
497 public PropertyMap(PropertyMap other) : this(Interop.PropertyMap.new_Property_Map__SWIG_1(PropertyMap.getCPtr(other)), true)
499 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
502 internal PropertyMap(global::System.IntPtr cPtr, bool cMemoryOwn)
504 swigCMemOwn = cMemoryOwn;
505 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
509 /// The operator to access the element with the specified string key.<br />
510 /// If an element with the key does not exist, then it is created.<br />
512 /// <param name="key">The key whose value to access.</param>
513 /// <returns>A value for the element with the specified key.</returns>
514 /// <since_tizen> 3 </since_tizen>
515 public PropertyValue this[string key]
519 return ValueOfIndex(key);
524 /// The operator to access the element with the specified index key.<br />
525 /// If an element with the key does not exist, then it is created.<br />
527 /// <param name="key">The key whose value to access.</param>
528 /// <returns>A value for the element with the specified key.</returns>
529 /// <since_tizen> 3 </since_tizen>
530 public PropertyValue this[int key]
534 return ValueOfIndex(key);
539 /// Retrieves the number of elements in the map.
541 /// <returns>The number of elements in the map.</returns>
542 /// <since_tizen> 3 </since_tizen>
545 uint ret = Interop.PropertyMap.Property_Map_Count(swigCPtr);
546 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
551 /// Returns whether the map is empty.
553 /// <returns>Returns true if empty, false otherwise.</returns>
554 /// <since_tizen> 3 </since_tizen>
557 bool ret = Interop.PropertyMap.Property_Map_Empty(swigCPtr);
558 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
563 /// Inserts the key-value pair in the map, with the key type as string.<br />
564 /// Does not check for duplicates.<br />
566 /// <param name="key">The key to insert.</param>
567 /// <param name="value">The value to insert.</param>
568 /// <since_tizen> 3 </since_tizen>
569 public void Insert(string key, PropertyValue value)
571 Interop.PropertyMap.Property_Map_Insert__SWIG_0(swigCPtr, key, PropertyValue.getCPtr(value));
572 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
576 /// Inserts the key-value pair in the map, with the key type as index.<br />
577 /// Does not check for duplicates.<br />
579 /// <param name="key">The key to insert.</param>
580 /// <param name="value">The value to insert.</param>
581 /// <since_tizen> 3 </since_tizen>
582 public void Insert(int key, PropertyValue value)
584 Interop.PropertyMap.Property_Map_Insert__SWIG_2(swigCPtr, key, PropertyValue.getCPtr(value));
585 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
589 /// Inserts the key-value pair in the map, with the key type as string.<br />
590 /// Does not check for duplicates.<br />
592 /// <param name="key">The key to insert.</param>
593 /// <param name="value">The value to insert.</param>
594 /// <returns>Returns a reference to this object.</returns>
595 /// <since_tizen> 3 </since_tizen>
596 public PropertyMap Add(string key, PropertyValue value)
598 PropertyMap ret = new PropertyMap(Interop.PropertyMap.Property_Map_Add__SWIG_0(swigCPtr, key, PropertyValue.getCPtr(value)), false);
599 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
604 /// Inserts the key-value pair in the map, with the key type as string.<br />
605 /// Does not check for duplicates.<br />
607 /// <param name="key">The key to insert.</param>
608 /// <param name="value">The value to insert.</param>
609 /// <returns>Returns a reference to this object.</returns>
610 /// <since_tizen> 3 </since_tizen>
611 public PropertyMap Add(int key, PropertyValue value)
613 PropertyMap ret = new PropertyMap(Interop.PropertyMap.Property_Map_Add__SWIG_2(swigCPtr, key, PropertyValue.getCPtr(value)), false);
614 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
619 /// Inserts the keyvalue to the map.<br />
620 /// Does not check for duplicates.<br />
622 /// <param name="keyValue">The keyvalue to insert.</param>
623 /// <returns>Returns a reference to this object.</returns>
624 public PropertyMap Add(KeyValue keyValue)
626 PropertyMap ret = new PropertyMap();
627 if ( keyValue.KeyInt != null )
629 ret = new PropertyMap(Interop.PropertyMap.Property_Map_Add__SWIG_2(swigCPtr, (int)keyValue.KeyInt, PropertyValue.getCPtr(keyValue.TrueValue)), false);
631 else if ( keyValue.KeyString != null)
633 ret = new PropertyMap(Interop.PropertyMap.Property_Map_Add__SWIG_0(swigCPtr, keyValue.KeyString, PropertyValue.getCPtr(keyValue.TrueValue)), false);
635 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
641 /// Retrieves the value at the specified position.
643 /// <param name="position">The specified position.</param>
644 /// <returns>A reference to the value at the specified position.</returns>
645 /// <since_tizen> 3 </since_tizen>
646 public PropertyValue GetValue(uint position)
648 PropertyValue ret = new PropertyValue(Interop.PropertyMap.Property_Map_GetValue(swigCPtr, position), false);
649 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
654 /// Retrieves the key at the specified position.
656 /// <param name="position">The specified position.</param>
657 /// <returns>A copy of the key at the specified position.</returns>
658 /// <since_tizen> 3 </since_tizen>
659 public PropertyKey GetKeyAt(uint position)
661 PropertyKey ret = new PropertyKey(Interop.PropertyMap.Property_Map_GetKeyAt(swigCPtr, position), true);
662 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
667 /// Finds the value for the specified key if it exists.
669 /// <param name="key">The key to find.</param>
670 /// <returns>The value if it exists, an empty object otherwise.</returns>
671 /// <since_tizen> 3 </since_tizen>
672 public PropertyValue Find(int key)
674 global::System.IntPtr cPtr = Interop.PropertyMap.Property_Map_Find__SWIG_2(swigCPtr, key);
675 PropertyValue ret = (cPtr == global::System.IntPtr.Zero) ? null : new PropertyValue(cPtr, false);
676 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
681 /// Finds the value for the specified keys if either exist.
683 /// <param name="indexKey">The index key to find.</param>
684 /// <param name="stringKey">The string key to find.</param>
685 /// <returns>The value if it exists, an empty object otherwise.</returns>
686 /// <since_tizen> 3 </since_tizen>
687 public PropertyValue Find(int indexKey, string stringKey)
689 global::System.IntPtr cPtr = Interop.PropertyMap.Property_Map_Find__SWIG_3(swigCPtr, indexKey, stringKey);
690 PropertyValue ret = (cPtr == global::System.IntPtr.Zero) ? null : new PropertyValue(cPtr, false);
691 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
698 /// <since_tizen> 3 </since_tizen>
701 Interop.PropertyMap.Property_Map_Clear(swigCPtr);
702 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
706 /// Merges values from the map 'from' to the current.<br />
707 /// Any values in 'from' will overwrite the values in the current map.<br />
709 /// <param name="from">The map to merge from.</param>
710 /// <since_tizen> 3 </since_tizen>
711 public void Merge(PropertyMap from)
713 Interop.PropertyMap.Property_Map_Merge(swigCPtr, PropertyMap.getCPtr(from));
714 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
718 /// Retrieves the element with the specified string key.
720 /// <param name="key">The key whose value to retrieve.</param>
721 /// <returns>The value for the element with the specified key.</returns>
722 internal PropertyValue ValueOfIndex(string key)
724 PropertyValue ret = new PropertyValue(Interop.PropertyMap.Property_Map_ValueOfIndex__SWIG_0(swigCPtr, key), false);
725 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
730 /// Retrieves the element with the specified index key.
732 /// <param name="key">The key whose value to retrieve.</param>
733 /// <returns>The value for the element with the specified key.</returns>
734 internal PropertyValue ValueOfIndex(int key)
736 PropertyValue ret = new PropertyValue(Interop.PropertyMap.Property_Map_ValueOfIndex__SWIG_2(swigCPtr, key), false);
737 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
741 internal static global::System.Runtime.InteropServices.HandleRef getCPtr(PropertyMap obj)
743 return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
749 /// <since_tizen> 3 </since_tizen>
750 protected override void Dispose(DisposeTypes type)
757 //Release your own unmanaged resources here.
758 //You should not access any managed member here except static instance.
759 //because the execution order of Finalizes is non-deterministic.
761 if (swigCPtr.Handle != global::System.IntPtr.Zero)
766 Interop.PropertyMap.delete_Property_Map(swigCPtr);
768 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
775 /// A value-type representing a property value.
777 /// <since_tizen> 3 </since_tizen>
778 public class PropertyValue : Disposable
783 /// <since_tizen> 3 </since_tizen>
784 protected bool swigCMemOwn;
785 private global::System.Runtime.InteropServices.HandleRef swigCPtr;
788 /// Creates a Size2D property value.
790 /// <param name="vectorValue">Size2D values.</param>
791 /// <since_tizen> 3 </since_tizen>
792 public PropertyValue(Size2D vectorValue) : this(Interop.PropertyValue.new_Property_Value__SWIG_4(Size2D.getCPtr(vectorValue)), true)
794 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
798 /// Creates a Position2D property value.
800 /// <param name="vectorValue">Position2D values.</param>
801 /// <since_tizen> 3 </since_tizen>
802 public PropertyValue(Position2D vectorValue) : this(Interop.PropertyValue.new_Property_Value__SWIG_4(Position2D.getCPtr(vectorValue)), true)
804 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
808 /// Creates a Position property value.
810 /// <param name="vectorValue">Position values.</param>
811 /// <since_tizen> 3 </since_tizen>
812 public PropertyValue(Position vectorValue) : this(Interop.PropertyValue.new_Property_Value__SWIG_5(Position.getCPtr(vectorValue)), true)
814 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
818 /// Creates a Color property value.
820 /// <param name="vectorValue">Color values.</param>
821 /// <since_tizen> 3 </since_tizen>
822 public PropertyValue(Color vectorValue) : this(Interop.PropertyValue.new_Property_Value__SWIG_6(Color.getCPtr(vectorValue)), true)
824 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
828 /// The default constructor.
830 /// <since_tizen> 3 </since_tizen>
831 public PropertyValue() : this(Interop.PropertyValue.new_Property_Value__SWIG_0(), true)
833 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
837 /// Creates a boolean property value.
839 /// <param name="boolValue">A boolean value.</param>
840 /// <since_tizen> 3 </since_tizen>
841 public PropertyValue(bool boolValue) : this(Interop.PropertyValue.new_Property_Value__SWIG_1(boolValue), true)
843 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
847 /// Creates an integer property value.
849 /// <param name="integerValue">An integer value.</param>
850 /// <since_tizen> 3 </since_tizen>
851 public PropertyValue(int integerValue) : this(Interop.PropertyValue.new_Property_Value__SWIG_2(integerValue), true)
853 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
857 /// Creates a float property value.
859 /// <param name="floatValue">A floating-point value.</param>
860 /// <since_tizen> 3 </since_tizen>
861 public PropertyValue(float floatValue) : this(Interop.PropertyValue.new_Property_Value__SWIG_3(floatValue), true)
863 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
867 /// Creates a Vector2 property value.
869 /// <param name="vectorValue">A vector of 2 floating-point values.</param>
870 /// <since_tizen> 3 </since_tizen>
871 public PropertyValue(Vector2 vectorValue) : this(Interop.PropertyValue.new_Property_Value__SWIG_4(Vector2.getCPtr(vectorValue)), true)
873 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
877 /// Creates a Vector3 property value.
879 /// <param name="vectorValue">A vector of 3 floating-point values.</param>
880 /// <since_tizen> 3 </since_tizen>
881 public PropertyValue(Vector3 vectorValue) : this(Interop.PropertyValue.new_Property_Value__SWIG_5(Vector3.getCPtr(vectorValue)), true)
883 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
887 /// Creates a Vector4 property value.
889 /// <param name="vectorValue">A vector of 4 floating-point values.</param>
890 /// <since_tizen> 3 </since_tizen>
891 public PropertyValue(Vector4 vectorValue) : this(Interop.PropertyValue.new_Property_Value__SWIG_6(Vector4.getCPtr(vectorValue)), true)
893 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
897 /// Creates a Rectangle property value.
899 /// <param name="vectorValue">Rectangle values.</param>
900 /// <since_tizen> 3 </since_tizen>
901 public PropertyValue(Rectangle vectorValue) : this(Interop.PropertyValue.new_Property_Value__SWIG_9(Rectangle.getCPtr(vectorValue)), true)
903 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
907 /// Creates a Rotation property value.
909 /// <param name="quaternion">Rotation values.</param>
910 /// <since_tizen> 3 </since_tizen>
911 public PropertyValue(Rotation quaternion) : this(Interop.PropertyValue.new_Property_Value__SWIG_11(Rotation.getCPtr(quaternion)), true)
913 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
917 /// Creates a string property value.
919 /// <param name="stringValue">A string.</param>
920 /// <since_tizen> 3 </since_tizen>
921 public PropertyValue(string stringValue) : this(Interop.PropertyValue.new_Property_Value__SWIG_12(stringValue), true)
923 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
927 /// Creates an array property value.
929 /// <param name="arrayValue">An array.</param>
930 /// <since_tizen> 3 </since_tizen>
931 public PropertyValue(PropertyArray arrayValue) : this(Interop.PropertyValue.new_Property_Value__SWIG_14(PropertyArray.getCPtr(arrayValue)), true)
933 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
937 /// Creates a map property value.
939 /// <param name="mapValue">An array.</param>
940 /// <since_tizen> 3 </since_tizen>
941 public PropertyValue(PropertyMap mapValue) : this(Interop.PropertyValue.new_Property_Value__SWIG_15(PropertyMap.getCPtr(mapValue)), true)
943 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
947 /// Creates a Extents value.
949 /// <param name="extentsValue">A Extents value.</param>
950 /// <since_tizen> 4 </since_tizen>
951 public PropertyValue(Extents extentsValue) : this(Interop.PropertyValue.new_Property_Value__SWIG_16(Extents.getCPtr(extentsValue)), true)
953 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
957 /// Creates a PropertyType value.
959 /// <param name="type">A PropertyType value.</param>
960 /// <since_tizen> 3 </since_tizen>
961 public PropertyValue(PropertyType type) : this(Interop.PropertyValue.new_Property_Value__SWIG_17((int)type), true)
963 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
967 /// Creates a PropertyValue value.
969 /// <param name="value">A PropertyValue value.</param>
970 /// <since_tizen> 3 </since_tizen>
971 public PropertyValue(PropertyValue value) : this(Interop.PropertyValue.new_Property_Value__SWIG_18(PropertyValue.getCPtr(value)), true)
973 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
977 /// Creates a Size property value.
979 /// <param name="vectorValue">Size values.</param>
980 internal PropertyValue(Size vectorValue) : this(Interop.PropertyValue.new_Property_Value__SWIG_5(Size.getCPtr(vectorValue)), true)
982 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
985 internal PropertyValue(global::System.IntPtr cPtr, bool cMemoryOwn)
987 swigCMemOwn = cMemoryOwn;
988 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
991 internal PropertyValue(Matrix3 matrixValue) : this(Interop.PropertyValue.new_Property_Value__SWIG_7(Matrix3.getCPtr(matrixValue)), true)
993 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
996 internal PropertyValue(Matrix matrixValue) : this(Interop.PropertyValue.new_Property_Value__SWIG_8(Matrix.getCPtr(matrixValue)), true)
998 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1001 internal PropertyValue(AngleAxis angleAxis) : this(Interop.PropertyValue.new_Property_Value__SWIG_10(AngleAxis.getCPtr(angleAxis)), true)
1003 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1007 /// An extension to the property value class that allows us to create a
1008 /// Property value from a C# object, for example, integer, float, or string.<br />
1010 /// <param name="obj">An object to create.</param>
1011 /// <returns>The created value.</returns>
1012 /// <since_tizen> 3 </since_tizen>
1013 static public PropertyValue CreateFromObject(System.Object obj)
1015 System.Type type = obj.GetType();
1017 PropertyValue value;
1020 value = new PropertyValue((int)obj);//Enum.Parse(type, str);
1022 else if (type.Equals(typeof(int)))
1024 value = new PropertyValue((int)obj);
1026 else if (type.Equals(typeof(System.Int32)))
1028 value = new PropertyValue((int)obj);
1030 else if (type.Equals(typeof(bool)))
1032 value = new PropertyValue((bool)obj);
1034 else if (type.Equals(typeof(float)))
1036 value = new PropertyValue((float)obj);
1038 else if (type.Equals(typeof(string)))
1040 value = new PropertyValue((string)obj);
1042 else if (type.Equals(typeof(Vector2)))
1044 value = new PropertyValue((Vector2)obj);
1046 else if (type.Equals(typeof(Vector3)))
1048 value = new PropertyValue((Vector3)obj);
1050 else if (type.Equals(typeof(Vector4)))
1052 value = new PropertyValue((Vector4)obj);
1054 else if (type.Equals(typeof(Position)))
1056 value = new PropertyValue((Position)obj);
1058 else if (type.Equals(typeof(Position2D)))
1060 value = new PropertyValue((Position2D)obj);
1062 else if (type.Equals(typeof(Size)))
1064 value = new PropertyValue((Size)obj);
1066 else if (type.Equals(typeof(Size2D)))
1068 value = new PropertyValue((Size2D)obj);
1070 else if (type.Equals(typeof(Color)))
1072 value = new PropertyValue((Color)obj);
1074 else if (type.Equals(typeof(Rotation)))
1076 value = new PropertyValue((Rotation)obj);
1078 else if (type.Equals(typeof(RelativeVector2)))
1080 value = new PropertyValue((RelativeVector2)obj);
1082 else if (type.Equals(typeof(RelativeVector3)))
1084 value = new PropertyValue((RelativeVector3)obj);
1086 else if (type.Equals(typeof(RelativeVector4)))
1088 value = new PropertyValue((RelativeVector4)obj);
1090 else if(type.Equals(typeof(Extents)))
1092 value = new PropertyValue((Extents)obj);
1096 throw new global::System.InvalidOperationException("Unimplemented type for Property Value :" + type.Name);
1098 //NUILog.Debug(" got an property value of =" + type.Name);
1103 /// Retrieves a Size2D value.
1105 /// <param name="vectorValue"> On return, a Size2D value.</param>
1106 /// <since_tizen> 3 </since_tizen>
1107 public bool Get(Size2D vectorValue)
1109 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_5(swigCPtr, Size2D.getCPtr(vectorValue));
1110 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1115 /// Retrieves a Position2D value.
1117 /// <param name="vectorValue"> On return, a Position2D value.</param>
1118 /// <since_tizen> 3 </since_tizen>
1119 public bool Get(Position2D vectorValue)
1121 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_5(swigCPtr, Position2D.getCPtr(vectorValue));
1122 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1127 /// Retrieves a Size value.
1129 /// <param name="vectorValue"> On return, a size value.</param>
1130 /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1131 [EditorBrowsable(EditorBrowsableState.Never)]
1132 public bool Get(Size vectorValue)
1134 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_6(swigCPtr, Size.getCPtr(vectorValue));
1135 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1140 /// Retrieves a Position value.
1142 /// <param name="vectorValue"> On return, a position value.</param>
1143 /// <since_tizen> 3 </since_tizen>
1144 public bool Get(Position vectorValue)
1146 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_6(swigCPtr, Position.getCPtr(vectorValue));
1147 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1152 /// Retrieves a Color value.
1154 /// <param name="vectorValue"> On return, a color value.</param>
1155 /// <since_tizen> 3 </since_tizen>
1156 public bool Get(Color vectorValue)
1158 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_7(swigCPtr, Color.getCPtr(vectorValue));
1159 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1164 /// Queries the type of this property value.
1166 /// <returns>The type ID</returns>
1167 /// <since_tizen> 3 </since_tizen>
1168 public new PropertyType GetType()
1170 PropertyType ret = (PropertyType)Interop.PropertyValue.Property_Value_GetType(swigCPtr);
1171 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1176 /// Retrieves a boolean value.
1178 /// <param name="boolValue">On return, a boolean value.</param>
1179 /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1180 /// <since_tizen> 3 </since_tizen>
1181 public bool Get(out bool boolValue)
1183 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_1(swigCPtr, out boolValue);
1184 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1189 /// Retrieves a floating-point value.
1191 /// <param name="floatValue">On return, a floating-point value.</param>
1192 /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1193 /// <since_tizen> 3 </since_tizen>
1194 public bool Get(out float floatValue)
1196 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_2(swigCPtr, out floatValue);
1197 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1202 /// Retrieves an integer value.
1204 /// <param name="integerValue">On return, an integer value.</param>
1205 /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1206 /// <since_tizen> 3 </since_tizen>
1207 public bool Get(out int integerValue)
1209 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_3(swigCPtr, out integerValue);
1210 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1215 /// Retrieves an integer rectangle.
1217 /// <param name="rect">On return, an integer rectangle.</param>
1218 /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1219 /// <since_tizen> 3 </since_tizen>
1220 public bool Get(Rectangle rect)
1222 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_4(swigCPtr, Rectangle.getCPtr(rect));
1223 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1228 /// Retrieves a vector value.
1230 /// <param name="vectorValue">On return, a vector value.</param>
1231 /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1232 /// <since_tizen> 3 </since_tizen>
1233 public bool Get(Vector2 vectorValue)
1235 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_5(swigCPtr, Vector2.getCPtr(vectorValue));
1236 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1241 /// Retrieves a vector value.
1243 /// <param name="vectorValue">On return, a vector value.</param>
1244 /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1245 /// <since_tizen> 3 </since_tizen>
1246 public bool Get(Vector3 vectorValue)
1248 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_6(swigCPtr, Vector3.getCPtr(vectorValue));
1249 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1254 /// Retrieves a vector value.
1256 /// <param name="vectorValue">On return, a vector value.</param>
1257 /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1258 /// <since_tizen> 3 </since_tizen>
1259 public bool Get(Vector4 vectorValue)
1261 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_7(swigCPtr, Vector4.getCPtr(vectorValue));
1262 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1267 /// Retrieves a vector value.
1269 /// <param name="vectorValue">On return, a vector value.</param>
1270 /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1271 /// <since_tizen> 5 </since_tizen>
1272 /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1273 [EditorBrowsable(EditorBrowsableState.Never)]
1274 public bool Get(RelativeVector2 vectorValue)
1276 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_5(swigCPtr, RelativeVector2.getCPtr(vectorValue));
1277 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1282 /// Retrieves a vector value.
1284 /// <param name="vectorValue">On return, a vector value.</param>
1285 /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1286 /// <since_tizen> 5 </since_tizen>
1287 /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1288 [EditorBrowsable(EditorBrowsableState.Never)]
1289 public bool Get(RelativeVector3 vectorValue)
1291 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_6(swigCPtr, RelativeVector3.getCPtr(vectorValue));
1292 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1297 /// Retrieves a vector value.
1299 /// <param name="vectorValue">On return, a vector value.</param>
1300 /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1301 /// <since_tizen> 5 </since_tizen>
1302 /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1303 [EditorBrowsable(EditorBrowsableState.Never)]
1304 public bool Get(RelativeVector4 vectorValue)
1306 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_7(swigCPtr, RelativeVector4.getCPtr(vectorValue));
1307 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1312 /// Retrieves a rotation value.
1314 /// <param name="quaternionValue">On return, a rotation value.</param>
1315 /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1316 /// <since_tizen> 3 </since_tizen>
1317 public bool Get(Rotation quaternionValue)
1319 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_11(swigCPtr, Rotation.getCPtr(quaternionValue));
1320 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1325 /// Retrieves a string property value.
1327 /// <param name="stringValue">On return, a string.</param>
1328 /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1329 /// <since_tizen> 3 </since_tizen>
1330 public bool Get(out string stringValue)
1332 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_12(swigCPtr, out stringValue);
1333 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1338 /// Retrieves an array property value.
1340 /// <param name="arrayValue">On return, the array as a vector property values.</param>
1341 /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1342 /// <since_tizen> 3 </since_tizen>
1343 public bool Get(PropertyArray arrayValue)
1345 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_13(swigCPtr, PropertyArray.getCPtr(arrayValue));
1346 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1351 /// Retrieves a map property value.
1353 /// <param name="mapValue">On return, the map as vector of string and property value pairs.</param>
1354 /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1355 /// <since_tizen> 3 </since_tizen>
1356 public bool Get(PropertyMap mapValue)
1358 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_14(swigCPtr, PropertyMap.getCPtr(mapValue));
1359 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1364 /// Retrieves a Extents value.
1366 /// <param name="extentsValue">On return, a extents.</param>
1367 /// <returns>Returns true if the value is successfully retrieved, false if the type is not convertible.</returns>
1368 /// <since_tizen> 4 </since_tizen>
1369 public bool Get(Extents extentsValue)
1371 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_15(swigCPtr, Extents.getCPtr(extentsValue));
1372 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1376 internal static global::System.Runtime.InteropServices.HandleRef getCPtr(PropertyValue obj)
1378 return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
1381 internal bool Get(Matrix3 matrixValue)
1383 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_8(swigCPtr, Matrix3.getCPtr(matrixValue));
1384 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1388 internal bool Get(Matrix matrixValue)
1390 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_9(swigCPtr, Matrix.getCPtr(matrixValue));
1391 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1395 internal bool Get(AngleAxis angleAxisValue)
1397 bool ret = Interop.PropertyValue.Property_Value_Get__SWIG_10(swigCPtr, AngleAxis.getCPtr(angleAxisValue));
1398 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1405 /// <since_tizen> 3 </since_tizen>
1406 protected override void Dispose(DisposeTypes type)
1413 //Release your own unmanaged resources here.
1414 //You should not access any managed member here except static instance.
1415 //because the execution order of Finalizes is non-deterministic.
1417 if (swigCPtr.Handle != global::System.IntPtr.Zero)
1421 swigCMemOwn = false;
1422 Interop.PropertyValue.delete_Property_Value(swigCPtr);
1424 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
1433 public class KeyValue
1438 public int? KeyInt = null;
1443 public string KeyString = null;
1448 public PropertyValue TrueValue = null;
1450 private string _key = null;
1451 private object _originalValue = null;
1452 private object _originalKey = null;
1455 /// Default Constructor.
1477 /// OriginalKey property.
1479 public object OriginalKey
1483 return _originalKey;
1487 _originalKey = value;
1488 if (value is int || value is Int32)
1490 KeyInt = (int)value;
1492 else if (value is string)
1494 KeyString = value.ToString();
1496 else if (value.GetType().Equals(typeof(int)) || value.GetType().Equals(typeof(Int32)))
1498 KeyInt = (int)value;
1500 else if (value.GetType().Equals(typeof(string)))
1502 KeyString = value.ToString();
1514 return _originalValue;
1518 _originalValue = value;
1519 TrueValue = PropertyValue.CreateFromObject(value);
1524 /// IntergerValue property.
1526 public int IntergerValue
1530 TrueValue = new PropertyValue(value);
1535 /// BooleanValue property.
1537 public bool BooleanValue
1541 TrueValue = new PropertyValue(value);
1546 /// SingleValue property.
1548 public float SingleValue
1552 TrueValue = new PropertyValue(value);
1557 /// StringValue property.
1559 public string StringValue
1563 TrueValue = new PropertyValue(value);
1568 /// Vector2Value property.
1570 public Vector2 Vector2Value
1574 TrueValue = new PropertyValue(value);
1579 /// Vector3Value property.
1581 public Vector3 Vector3Value
1585 TrueValue = new PropertyValue(value);
1590 /// Vector4Value property.
1592 public Vector4 Vector4Value
1596 TrueValue = new PropertyValue(value);
1601 /// PositionValue property.
1603 public Position PositionValue
1607 TrueValue = new PropertyValue(value);
1612 /// Position2DValue property.
1614 public Position2D Position2DValue
1618 TrueValue = new PropertyValue(value);
1623 /// SizeValue property.
1625 public Size SizeValue
1629 TrueValue = new PropertyValue(value);
1634 /// Size2DValue property.
1636 public Size2D Size2DValue
1640 TrueValue = new PropertyValue(value);
1645 /// ColorValue property.
1647 public Color ColorValue
1651 TrueValue = new PropertyValue(value);
1656 /// RectangleValue property.
1658 public Rectangle RectangleValue
1662 TrueValue = new PropertyValue(value);
1667 /// RotationValue property.
1669 public Rotation RotationValue
1673 TrueValue = new PropertyValue(value);
1678 /// RelativeVector2Value property.
1680 public RelativeVector2 RelativeVector2Value
1684 TrueValue = new PropertyValue(value);
1689 /// RelativeVector3Value property.
1691 public RelativeVector3 RelativeVector3Value
1695 TrueValue = new PropertyValue(value);
1700 /// RelativeVector4Value property.
1702 public RelativeVector4 RelativeVector4Value
1706 TrueValue = new PropertyValue(value);
1711 /// ExtentsValue property.
1713 public Extents ExtentsValue
1717 TrueValue = new PropertyValue(value);
1722 /// PropertyArrayValue property.
1724 public PropertyArray PropertyArrayValue
1728 TrueValue = new PropertyValue(value);
1733 /// PropertyMapValue property.
1735 public PropertyMap PropertyMapValue
1739 TrueValue = new PropertyValue(value);
1743 private void ParseKey(string key)
1746 if (VisualExtension.KeyDictionary.ContainsKey(key))
1748 VisualExtension.KeyDictionary.TryGetValue(key, out v);
1758 internal class Property : Disposable
1763 /// <since_tizen> 3 </since_tizen>
1764 protected bool swigCMemOwn;
1766 private global::System.Runtime.InteropServices.HandleRef swigCPtr;
1769 /// This constructor creates a property instance.
1771 /// <param name="arg0">A valid handle to the target object.</param>
1772 /// <param name="propertyIndex">The index of a property.</param>
1773 /// <since_tizen> 3 </since_tizen>
1774 public Property(Animatable arg0, int propertyIndex) : this(Interop.Property.new_Property__SWIG_0(Animatable.getCPtr(arg0), propertyIndex), true)
1776 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1780 /// This constructor creates a property instance.
1782 /// <param name="arg0">A valid handle to the target object.</param>
1783 /// <param name="propertyIndex">The index of a property.</param>
1784 /// <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>
1785 /// <since_tizen> 3 </since_tizen>
1786 public Property(Animatable arg0, int propertyIndex, int componentIndex) : this(Interop.Property.new_Property__SWIG_1(Animatable.getCPtr(arg0), propertyIndex, componentIndex), true)
1788 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1792 /// This constructor creates a property instance.<br />
1793 /// This performs a property index query and is therefore slower than constructing a property directly with the index.<br />
1795 /// <param name="arg0">A valid handle to the target object.</param>
1796 /// <param name="propertyName">The property name.</param>
1797 /// <since_tizen> 3 </since_tizen>
1798 public Property(Animatable arg0, string propertyName) : this(Interop.Property.new_Property__SWIG_2(Animatable.getCPtr(arg0), propertyName), true)
1800 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1804 /// This constructor creates a property instance.<br />
1805 /// This performs a property index query and is therefore slower than constructing a property directly with the index.<br />
1807 /// <param name="arg0">A valid handle to the target object.</param>
1808 /// <param name="propertyName">The property name.</param>
1809 /// <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>
1810 /// <since_tizen> 3 </since_tizen>
1811 public Property(Animatable arg0, string propertyName, int componentIndex) : this(Interop.Property.new_Property__SWIG_3(Animatable.getCPtr(arg0), propertyName, componentIndex), true)
1813 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1816 internal Property(global::System.IntPtr cPtr, bool cMemoryOwn)
1818 swigCMemOwn = cMemoryOwn;
1819 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
1823 /// Gets or sets the index of the property.
1825 /// <since_tizen> 3 </since_tizen>
1826 public int propertyIndex
1830 Interop.Property.Property_propertyIndex_set(swigCPtr, value);
1831 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1835 int ret = Interop.Property.Property_propertyIndex_get(swigCPtr);
1836 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1842 /// Gets or sets the component index of the property.
1844 /// <since_tizen> 3 </since_tizen>
1845 public int componentIndex
1849 Interop.Property.Property_componentIndex_set(swigCPtr, value);
1850 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1854 int ret = Interop.Property.Property_componentIndex_get(swigCPtr);
1855 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1860 internal static int INVALID_INDEX
1864 int ret = Interop.Property.Property_INVALID_INDEX_get();
1865 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1870 internal static int INVALID_KEY
1874 int ret = Interop.Property.Property_INVALID_KEY_get();
1875 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1880 internal static int INVALID_COMPONENT_INDEX
1884 int ret = Interop.Property.Property_INVALID_COMPONENT_INDEX_get();
1885 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1890 internal Animatable _object
1894 Interop.Property.Property__object_set(swigCPtr, Animatable.getCPtr(value));
1895 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1899 Animatable ret = new Animatable(Interop.Property.Property__object_get(swigCPtr), false);
1900 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1905 internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Property obj)
1907 return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
1910 protected override void Dispose(DisposeTypes type)
1917 //Release your own unmanaged resources here.
1918 //You should not access any managed member here except static instance.
1919 //because the execution order of Finalizes is non-deterministic.
1921 if (swigCPtr.Handle != global::System.IntPtr.Zero)
1925 swigCMemOwn = false;
1926 Interop.Property.delete_Property(swigCPtr);
1928 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);