Release 4.0.0-preview1-00235
[platform/core/csapi/tizenfx.git] / src / Tizen.NUI / src / public / Position.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
20 namespace Tizen.NUI
21 {
22
23     /// <summary>
24     /// Position is a three-dimensional vector.
25     /// </summary>
26     public class Position : global::System.IDisposable
27     {
28         private global::System.Runtime.InteropServices.HandleRef swigCPtr;
29         protected bool swigCMemOwn;
30
31         internal Position(global::System.IntPtr cPtr, bool cMemoryOwn)
32         {
33             swigCMemOwn = cMemoryOwn;
34             swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
35         }
36
37         internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Position obj)
38         {
39             return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
40         }
41
42         //A Flag to check who called Dispose(). (By User or DisposeQueue)
43         private bool isDisposeQueued = false;
44         //A Flat to check if it is already disposed.
45         protected bool disposed = false;
46
47         ~Position()
48         {
49             if(!isDisposeQueued)
50             {
51                 isDisposeQueued = true;
52                 DisposeQueue.Instance.Add(this);
53             }
54         }
55
56         public void Dispose()
57         {
58             //Throw excpetion if Dispose() is called in separate thread.
59             if (!Window.IsInstalled())
60             {
61                 throw new System.InvalidOperationException("This API called from separate thread. This API must be called from MainThread.");
62             }
63
64             if (isDisposeQueued)
65             {
66                 Dispose(DisposeTypes.Implicit);
67             }
68             else
69             {
70                 Dispose(DisposeTypes.Explicit);
71                 System.GC.SuppressFinalize(this);
72             }
73         }
74
75         protected virtual void Dispose(DisposeTypes type)
76         {
77             if (disposed)
78             {
79                 return;
80             }
81
82             if(type == DisposeTypes.Explicit)
83             {
84                 //Called by User
85                 //Release your own managed resources here.
86                 //You should release all of your own disposable objects here.
87             }
88
89             //Release your own unmanaged resources here.
90             //You should not access any managed member here except static instance.
91             //because the execution order of Finalizes is non-deterministic.
92
93             if (swigCPtr.Handle != global::System.IntPtr.Zero)
94             {
95                 if (swigCMemOwn)
96                 {
97                     swigCMemOwn = false;
98                     NDalicPINVOKE.delete_Vector3(swigCPtr);
99                 }
100                 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
101             }
102             disposed = true;
103         }
104
105
106         /// <summary>
107         /// An addition operator.
108         /// </summary>
109         /// <param name="arg1">The vector to add.</param>
110         /// <param name="arg2">The vector to add.</param>
111         /// <returns>The vector containing the result of the addition.</returns>
112         public static Position operator +(Position arg1, Position arg2)
113         {
114             return arg1.Add(arg2);
115         }
116
117         /// <summary>
118         /// The subtraction operator.
119         /// </summary>
120         /// <param name="arg1">The vector to subtract.</param>
121         /// <param name="arg2">The vector to subtract.</param>
122         /// <returns>The vector containing the result of the subtraction.</returns>
123         public static Position operator -(Position arg1, Position arg2)
124         {
125             return arg1.Subtract(arg2);
126         }
127
128         /// <summary>
129         /// The unary negation operator.
130         /// </summary>
131         /// <param name="arg1">The vector to negate.</param>
132         /// <returns>The vector containg the negation.</returns>
133         public static Position operator -(Position arg1)
134         {
135             return arg1.Subtract();
136         }
137
138         /// <summary>
139         /// The multiplication operator.
140         /// </summary>
141         /// <param name="arg1">The vector to multiply.</param>
142         /// <param name="arg2">The vector to multiply.</param>
143         /// <returns>The vector containing the result of the multiplication.</returns>
144         public static Position operator *(Position arg1, Position arg2)
145         {
146             return arg1.Multiply(arg2);
147         }
148
149         /// <summary>
150         /// The multiplication operator.
151         /// </summary>
152         /// <param name="arg1">The vector to multiply</param>
153         /// <param name="arg2">The float value to scale the vector.</param>
154         /// <returns>The vector containing the result of scaling.</returns>
155         public static Position operator *(Position arg1, float arg2)
156         {
157             return arg1.Multiply(arg2);
158         }
159
160         /// <summary>
161         /// The division operator.
162         /// </summary>
163         /// <param name="arg1">The vector to divide.</param>
164         /// <param name="arg2">The vector to divide.</param>
165         /// <returns>The vector containing the result of the division.</returns>
166         public static Position operator /(Position arg1, Position arg2)
167         {
168             return arg1.Divide(arg2);
169         }
170
171         /// <summary>
172         /// The division operator.
173         /// </summary>
174         /// <param name="arg1">The vector to divide.</param>
175         /// <param name="arg2">The float value to scale the vector by.</param>
176         /// <returns>The vector containing the result of scaling.</returns>
177         public static Position operator /(Position arg1, float arg2)
178         {
179             return arg1.Divide(arg2);
180         }
181
182
183         /// <summary>
184         /// The const array subscript operator overload. Should be 0, 1, or 2.
185         /// </summary>
186         /// <param name="index">The subscript index.</param>
187         /// <returns>The float at the given index.</returns>
188         public float this[uint index]
189         {
190             get
191             {
192                 return ValueOfIndex(index);
193             }
194         }
195
196         internal static Position GetPositionFromPtr(global::System.IntPtr cPtr)
197         {
198             Position ret = new Position(cPtr, false);
199             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
200             return ret;
201         }
202
203
204         /// <summary>
205         /// The constructor.
206         /// </summary>
207         public Position() : this(NDalicPINVOKE.new_Vector3__SWIG_0(), true)
208         {
209             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
210         }
211
212         /// <summary>
213         /// The constructor.
214         /// </summary>
215         /// <param name="x">The x component.</param>
216         /// <param name="y">The y component.</param>
217         /// <param name="z">The z component.</param>
218         public Position(float x, float y, float z) : this(NDalicPINVOKE.new_Vector3__SWIG_1(x, y, z), true)
219         {
220             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
221         }
222
223         /// <summary>
224         /// The constructor.
225         /// </summary>
226         /// <param name="position2d">Position2D to create this vector from.</param>
227         public Position(Position2D position2d) : this(NDalicPINVOKE.new_Vector3__SWIG_3(Position2D.getCPtr(position2d)), true)
228         {
229             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
230         }
231
232
233
234         private Position Add(Position rhs)
235         {
236             Position ret = new Position(NDalicPINVOKE.Vector3_Add(swigCPtr, Position.getCPtr(rhs)), true);
237             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
238             return ret;
239         }
240
241         private Position Subtract(Position rhs)
242         {
243             Position ret = new Position(NDalicPINVOKE.Vector3_Subtract__SWIG_0(swigCPtr, Position.getCPtr(rhs)), true);
244             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
245             return ret;
246         }
247
248         private Position Multiply(Position rhs)
249         {
250             Position ret = new Position(NDalicPINVOKE.Vector3_Multiply__SWIG_0(swigCPtr, Position.getCPtr(rhs)), true);
251             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
252             return ret;
253         }
254
255         private Position Multiply(float rhs)
256         {
257             Position ret = new Position(NDalicPINVOKE.Vector3_Multiply__SWIG_1(swigCPtr, rhs), true);
258             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
259             return ret;
260         }
261
262         private Position Divide(Position rhs)
263         {
264             Position ret = new Position(NDalicPINVOKE.Vector3_Divide__SWIG_0(swigCPtr, Position.getCPtr(rhs)), true);
265             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
266             return ret;
267         }
268
269         private Position Divide(float rhs)
270         {
271             Position ret = new Position(NDalicPINVOKE.Vector3_Divide__SWIG_1(swigCPtr, rhs), true);
272             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
273             return ret;
274         }
275
276         private Position Subtract()
277         {
278             Position ret = new Position(NDalicPINVOKE.Vector3_Subtract__SWIG_1(swigCPtr), true);
279             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
280             return ret;
281         }
282
283         private float ValueOfIndex(uint index)
284         {
285             float ret = NDalicPINVOKE.Vector3_ValueOfIndex__SWIG_0(swigCPtr, index);
286             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
287             return ret;
288         }
289
290         /// <summary>
291         /// Compares if rhs is equal to.
292         /// </summary>
293         /// <param name="rhs">The vector to compare.</param>
294         /// <returns>Returns true if the two vectors are equal, otherwise false.</returns>
295         public bool EqualTo(Position rhs)
296         {
297             bool ret = NDalicPINVOKE.Vector3_EqualTo(swigCPtr, Position.getCPtr(rhs));
298             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
299             return ret;
300         }
301
302         /// <summary>
303         /// Compares if rhs is not equal to.
304         /// </summary>
305         /// <param name="rhs">The vector to compare.</param>
306         /// <returns>Returns true if the two vectors are not equal, otherwise false.</returns>
307         public bool NotEqualTo(Position rhs)
308         {
309             bool ret = NDalicPINVOKE.Vector3_NotEqualTo(swigCPtr, Position.getCPtr(rhs));
310             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
311             return ret;
312         }
313
314
315         /// <summary>
316         /// The x component.
317         /// </summary>
318         public float X
319         {
320             set
321             {
322                 NDalicPINVOKE.Vector3_X_set(swigCPtr, value);
323                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
324             }
325             get
326             {
327                 float ret = NDalicPINVOKE.Vector3_X_get(swigCPtr);
328                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
329                 return ret;
330             }
331         }
332
333         /// <summary>
334         /// The y component.
335         /// </summary>
336         public float Y
337         {
338             set
339             {
340                 NDalicPINVOKE.Vector3_Y_set(swigCPtr, value);
341                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
342             }
343             get
344             {
345                 float ret = NDalicPINVOKE.Vector3_Y_get(swigCPtr);
346                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
347                 return ret;
348             }
349         }
350
351         /// <summary>
352         /// The z component.
353         /// </summary>
354         public float Z
355         {
356             set
357             {
358                 NDalicPINVOKE.Vector3_Z_set(swigCPtr, value);
359                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
360             }
361             get
362             {
363                 float ret = NDalicPINVOKE.Vector3_Z_get(swigCPtr);
364                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
365                 return ret;
366             }
367         }
368
369         /// <summary>
370         /// ParentOrigin constants. It's 0.0.
371         /// </summary>
372         public static float ParentOriginTop
373         {
374             get
375             {
376                 float ret = NDalicPINVOKE.ParentOriginTop_get();
377                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
378                 return ret;
379             }
380         }
381
382         /// <summary>
383         /// ParentOrigin constants. It's 1.0.
384         /// </summary>
385         public static float ParentOriginBottom
386         {
387             get
388             {
389                 float ret = NDalicPINVOKE.ParentOriginBottom_get();
390                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
391                 return ret;
392             }
393         }
394
395         /// <summary>
396         /// ParentOrigin constants. It's 0.0.
397         /// </summary>
398         public static float ParentOriginLeft
399         {
400             get
401             {
402                 float ret = NDalicPINVOKE.ParentOriginLeft_get();
403                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
404                 return ret;
405             }
406         }
407
408         /// <summary>
409         /// ParentOrigin constants. It's 1.0.
410         /// </summary>
411         public static float ParentOriginRight
412         {
413             get
414             {
415                 float ret = NDalicPINVOKE.ParentOriginRight_get();
416                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
417                 return ret;
418             }
419         }
420
421         /// <summary>
422         /// ParentOrigin constants. It's 0.5.
423         /// </summary>
424         public static float ParentOriginMiddle
425         {
426             get
427             {
428                 float ret = NDalicPINVOKE.ParentOriginMiddle_get();
429                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
430                 return ret;
431             }
432         }
433
434         /// <summary>
435         /// ParentOrigin constants: 0.0, 0.0, 0.5.
436         /// </summary>
437         public static Position ParentOriginTopLeft
438         {
439             get
440             {
441                 global::System.IntPtr cPtr = NDalicPINVOKE.ParentOriginTopLeft_get();
442                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
443                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
444                 return ret;
445             }
446         }
447
448         /// <summary>
449         /// ParentOrigin constants: 0.5, 0.0, 0.5.
450         /// </summary>
451         public static Position ParentOriginTopCenter
452         {
453             get
454             {
455                 global::System.IntPtr cPtr = NDalicPINVOKE.ParentOriginTopCenter_get();
456                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
457                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
458                 return ret;
459             }
460         }
461
462         /// <summary>
463         /// ParentOrigin constants: 1.0, 0.0, 0.5.
464         /// </summary>
465         public static Position ParentOriginTopRight
466         {
467             get
468             {
469                 global::System.IntPtr cPtr = NDalicPINVOKE.ParentOriginTopRight_get();
470                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
471                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
472                 return ret;
473             }
474         }
475
476         /// <summary>
477         /// ParentOrigin constants: 0.0, 0.5, 0.5.
478         /// </summary>
479         public static Position ParentOriginCenterLeft
480         {
481             get
482             {
483                 global::System.IntPtr cPtr = NDalicPINVOKE.ParentOriginCenterLeft_get();
484                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
485                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
486                 return ret;
487             }
488         }
489
490         /// <summary>
491         /// ParentOrigin constants: 0.0, 0.5, 0.5
492         /// </summary>
493         public static Position ParentOriginCenter
494         {
495             get
496             {
497                 global::System.IntPtr cPtr = NDalicPINVOKE.ParentOriginCenter_get();
498                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
499                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
500                 return ret;
501             }
502         }
503
504         /// <summary>
505         /// ParentOrigin constants: 1.0, 0.5, 0.5.
506         /// </summary>
507         public static Position ParentOriginCenterRight
508         {
509             get
510             {
511                 global::System.IntPtr cPtr = NDalicPINVOKE.ParentOriginCenterRight_get();
512                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
513                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
514                 return ret;
515             }
516         }
517
518         /// <summary>
519         /// ParentOrigin constants: 0.0f, 1.0f, 0.5f.
520         /// </summary>
521         public static Position ParentOriginBottomLeft
522         {
523             get
524             {
525                 global::System.IntPtr cPtr = NDalicPINVOKE.ParentOriginBottomLeft_get();
526                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
527                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
528                 return ret;
529             }
530         }
531
532         /// <summary>
533         /// ParentOrigin constants: 0.5, 1.0, 0.5.
534         /// </summary>
535         public static Position ParentOriginBottomCenter
536         {
537             get
538             {
539                 global::System.IntPtr cPtr = NDalicPINVOKE.ParentOriginBottomCenter_get();
540                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
541                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
542                 return ret;
543             }
544         }
545
546         /// <summary>
547         /// ParentOrigin constants: 1.0, 1.0, 0.5.
548         /// </summary>
549         public static Position ParentOriginBottomRight
550         {
551             get
552             {
553                 global::System.IntPtr cPtr = NDalicPINVOKE.ParentOriginBottomRight_get();
554                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
555                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
556                 return ret;
557             }
558         }
559
560         /// <summary>
561         /// PivotPoint constants: 0.0.
562         /// </summary>
563         public static float PivotPointTop
564         {
565             get
566             {
567                 float ret = NDalicPINVOKE.AnchorPointTop_get();
568                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
569                 return ret;
570             }
571         }
572
573         /// <summary>
574         /// PivotPoint constants: 1.0.
575         /// </summary>
576         public static float PivotPointBottom
577         {
578             get
579             {
580                 float ret = NDalicPINVOKE.AnchorPointBottom_get();
581                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
582                 return ret;
583             }
584         }
585
586         /// <summary>
587         /// PivotPoint constants: 0.0.
588         /// </summary>
589         public static float PivotPointLeft
590         {
591             get
592             {
593                 float ret = NDalicPINVOKE.AnchorPointLeft_get();
594                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
595                 return ret;
596             }
597         }
598
599         /// <summary>
600         /// PivotPoint constants: 1.0.
601         /// </summary>
602         public static float PivotPointRight
603         {
604             get
605             {
606                 float ret = NDalicPINVOKE.AnchorPointRight_get();
607                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
608                 return ret;
609             }
610         }
611
612         /// <summary>
613         /// PivotPoint constants: 0.0.
614         /// </summary>
615         public static float PivotPointMiddle
616         {
617             get
618             {
619                 float ret = NDalicPINVOKE.AnchorPointMiddle_get();
620                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
621                 return ret;
622             }
623         }
624
625         /// <summary>
626         /// PivotPoint constants: 0.0, 0.0, 0.5.
627         /// </summary>
628         public static Position PivotPointTopLeft
629         {
630             get
631             {
632                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointTopLeft_get();
633                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
634                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
635                 return ret;
636             }
637         }
638
639         /// <summary>
640         /// PivotPoint constants: 0.5, 0.0, 0.5.
641         /// </summary>
642         public static Position PivotPointTopCenter
643         {
644             get
645             {
646                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointTopCenter_get();
647                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
648                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
649                 return ret;
650             }
651         }
652
653         /// <summary>
654         /// PivotPoint constants: 1.0, 0.0, 0.5.
655         /// </summary>
656         public static Position PivotPointTopRight
657         {
658             get
659             {
660                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointTopRight_get();
661                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
662                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
663                 return ret;
664             }
665         }
666
667         /// <summary>
668         /// PivotPoint constants: 0.0, 0.5, 0.5.
669         /// </summary>
670         public static Position PivotPointCenterLeft
671         {
672             get
673             {
674                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointCenterLeft_get();
675                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
676                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
677                 return ret;
678             }
679         }
680
681         /// <summary>
682         /// PivotPoint constants: 0.5, 0.5, 0.5.
683         /// </summary>
684         public static Position PivotPointCenter
685         {
686             get
687             {
688                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointCenter_get();
689                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
690                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
691                 return ret;
692             }
693         }
694
695         /// <summary>
696         /// PivotPoint constants: 1.0, 0.5, 0.5.
697         /// </summary>
698         public static Position PivotPointCenterRight
699         {
700             get
701             {
702                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointCenterRight_get();
703                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
704                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
705                 return ret;
706             }
707         }
708
709         /// <summary>
710         /// PivotPoint constants: 0.0, 1.0, 0.5.
711         /// </summary>
712         public static Position PivotPointBottomLeft
713         {
714             get
715             {
716                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointBottomLeft_get();
717                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
718                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
719                 return ret;
720             }
721         }
722
723         /// <summary>
724         /// PivotPoint constants: 0.5, 1.0, 0.5
725         /// </summary>
726         public static Position PivotPointBottomCenter
727         {
728             get
729             {
730                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointBottomCenter_get();
731                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
732                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
733                 return ret;
734             }
735         }
736
737         /// <summary>
738         /// PivotPoint constants: 1.0, 1.0, 0.5.
739         /// </summary>
740         public static Position PivotPointBottomRight
741         {
742             get
743             {
744                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointBottomRight_get();
745                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
746                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
747                 return ret;
748             }
749         }
750
751         /// <summary>
752         /// Constant ( 1.0f, 1.0f, 1.0f ).
753         /// </summary>
754         public static Position One
755         {
756             get
757             {
758                 global::System.IntPtr cPtr = NDalicPINVOKE.Vector3_ONE_get();
759                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
760                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
761                 return ret;
762             }
763         }
764
765         internal static Position XAxis
766         {
767             get
768             {
769                 global::System.IntPtr cPtr = NDalicPINVOKE.Vector3_XAXIS_get();
770                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
771                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
772                 return ret;
773             }
774         }
775
776         internal static Position YAxis
777         {
778             get
779             {
780                 global::System.IntPtr cPtr = NDalicPINVOKE.Vector3_YAXIS_get();
781                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
782                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
783                 return ret;
784             }
785         }
786
787         internal static Position ZAxis
788         {
789             get
790             {
791                 global::System.IntPtr cPtr = NDalicPINVOKE.Vector3_ZAXIS_get();
792                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
793                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
794                 return ret;
795             }
796         }
797
798         internal static Position NegativeXAxis
799         {
800             get
801             {
802                 global::System.IntPtr cPtr = NDalicPINVOKE.Vector3_NEGATIVE_XAXIS_get();
803                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
804                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
805                 return ret;
806             }
807         }
808
809         internal static Position NegativeYAxis
810         {
811             get
812             {
813                 global::System.IntPtr cPtr = NDalicPINVOKE.Vector3_NEGATIVE_YAXIS_get();
814                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
815                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
816                 return ret;
817             }
818         }
819
820         internal static Position NegativeZAxis
821         {
822             get
823             {
824                 global::System.IntPtr cPtr = NDalicPINVOKE.Vector3_NEGATIVE_ZAXIS_get();
825                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
826                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
827                 return ret;
828             }
829         }
830
831         /// <summary>
832         /// Constant ( 0.0f, 0.0f, 0.0f ).
833         /// </summary>
834         public static Position Zero
835         {
836             get
837             {
838                 global::System.IntPtr cPtr = NDalicPINVOKE.Vector3_ZERO_get();
839                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
840                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
841                 return ret;
842             }
843         }
844
845         /// <summary>
846         /// Converts a position instance to a Vector3 instance.
847         /// </summary>
848         public static implicit operator Vector3(Position Position)
849         {
850             return new Vector3(Position.X, Position.Y, Position.Z);
851         }
852
853         /// <summary>
854         /// Converts a Vector3 instance to a position instance.
855         /// </summary>
856         public static implicit operator Position(Vector3 vec)
857         {
858             return new Position(vec.X, vec.Y, vec.Z);
859         }
860
861
862         [Obsolete("Please do not use! this will be deprecated")]
863         public static float AnchorPointTop
864         {
865             get
866             {
867                 float ret = NDalicPINVOKE.AnchorPointTop_get();
868                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
869                 return ret;
870             }
871         }
872
873         [Obsolete("Please do not use! this will be deprecated")]
874         public static float AnchorPointBottom
875         {
876             get
877             {
878                 float ret = NDalicPINVOKE.AnchorPointBottom_get();
879                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
880                 return ret;
881             }
882         }
883
884         [Obsolete("Please do not use! this will be deprecated")]
885         public static float AnchorPointLeft
886         {
887             get
888             {
889                 float ret = NDalicPINVOKE.AnchorPointLeft_get();
890                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
891                 return ret;
892             }
893         }
894
895         [Obsolete("Please do not use! this will be deprecated")]
896         public static float AnchorPointRight
897         {
898             get
899             {
900                 float ret = NDalicPINVOKE.AnchorPointRight_get();
901                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
902                 return ret;
903             }
904         }
905
906         [Obsolete("Please do not use! this will be deprecated")]
907         public static float AnchorPointMiddle
908         {
909             get
910             {
911                 float ret = NDalicPINVOKE.AnchorPointMiddle_get();
912                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
913                 return ret;
914             }
915         }
916
917         [Obsolete("Please do not use! this will be deprecated")]
918         public static Position AnchorPointTopLeft
919         {
920             get
921             {
922                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointTopLeft_get();
923                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
924                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
925                 return ret;
926             }
927         }
928
929         [Obsolete("Please do not use! this will be deprecated")]
930         public static Position AnchorPointTopCenter
931         {
932             get
933             {
934                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointTopCenter_get();
935                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
936                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
937                 return ret;
938             }
939         }
940
941         [Obsolete("Please do not use! this will be deprecated")]
942         public static Position AnchorPointTopRight
943         {
944             get
945             {
946                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointTopRight_get();
947                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
948                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
949                 return ret;
950             }
951         }
952
953         [Obsolete("Please do not use! this will be deprecated")]
954         public static Position AnchorPointCenterLeft
955         {
956             get
957             {
958                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointCenterLeft_get();
959                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
960                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
961                 return ret;
962             }
963         }
964
965
966         [Obsolete("Please do not use! this will be deprecated")]
967         public static Position AnchorPointCenter
968         {
969             get
970             {
971                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointCenter_get();
972                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
973                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
974                 return ret;
975             }
976         }
977
978         [Obsolete("Please do not use! this will be deprecated")]
979         public static Position AnchorPointCenterRight
980         {
981             get
982             {
983                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointCenterRight_get();
984                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
985                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
986                 return ret;
987             }
988         }
989
990         [Obsolete("Please do not use! this will be deprecated")]
991         public static Position AnchorPointBottomLeft
992         {
993             get
994             {
995                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointBottomLeft_get();
996                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
997                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
998                 return ret;
999             }
1000         }
1001
1002         [Obsolete("Please do not use! this will be deprecated")]
1003         public static Position AnchorPointBottomCenter
1004         {
1005             get
1006             {
1007                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointBottomCenter_get();
1008                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
1009                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1010                 return ret;
1011             }
1012         }
1013
1014         [Obsolete("Please do not use! this will be deprecated")]
1015         public static Position AnchorPointBottomRight
1016         {
1017             get
1018             {
1019                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointBottomRight_get();
1020                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
1021                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1022                 return ret;
1023             }
1024         }
1025
1026     }
1027 }