02d09fc831d6b7e02b672bf37eff61b61d408e3f
[platform/core/csapi/tizenfx.git] / internals / src / EflSharp / EflSharp / efl / efl_app.eo.cs
1 #define EFL_BETA
2 #pragma warning disable CS1591
3 using System;
4 using System.Runtime.InteropServices;
5 using System.Collections.Generic;
6 using System.Linq;
7 using System.Threading;
8 using System.ComponentModel;
9 namespace Efl {
10
11 /// <summary>Object representing the application itself.
12 /// (Since EFL 1.22)</summary>
13 [Efl.App.NativeMethods]
14 [Efl.Eo.BindingEntity]
15 public abstract class App : Efl.Loop, Efl.Core.ICommandLine
16 {
17     /// <summary>Pointer to the native class description.</summary>
18     public override System.IntPtr NativeClass
19     {
20         get
21         {
22             if (((object)this).GetType() == typeof(App))
23             {
24                 return GetEflClassStatic();
25             }
26             else
27             {
28                 return Efl.Eo.ClassRegister.klassFromType[((object)this).GetType()];
29             }
30         }
31     }
32
33     [System.Runtime.InteropServices.DllImport(efl.Libs.Ecore)] internal static extern System.IntPtr
34         efl_app_class_get();
35     /// <summary>Initializes a new instance of the <see cref="App"/> class.</summary>
36     /// <param name="parent">Parent instance.</param>
37     public App(Efl.Object parent= null
38             ) : base(efl_app_class_get(), parent)
39     {
40         FinishInstantiation();
41     }
42
43     /// <summary>Subclasses should override this constructor if they are expected to be instantiated from native code.
44     /// Do not call this constructor directly.</summary>
45     /// <param name="ch">Tag struct storing the native handle of the object being constructed.</param>
46     protected App(ConstructingHandle ch) : base(ch)
47     {
48     }
49
50     /// <summary>Initializes a new instance of the <see cref="App"/> class.
51     /// Internal usage: Constructs an instance from a native pointer. This is used when interacting with C code and should not be used directly.</summary>
52     /// <param name="wh">The native pointer to be wrapped.</param>
53     protected App(Efl.Eo.Globals.WrappingHandle wh) : base(wh)
54     {
55     }
56
57     [Efl.Eo.PrivateNativeClass]
58     private class AppRealized : App
59     {
60         private AppRealized(Efl.Eo.Globals.WrappingHandle wh) : base(wh)
61         {
62         }
63     }
64     /// <summary>Initializes a new instance of the <see cref="App"/> class.
65     /// Internal usage: Constructor to forward the wrapper initialization to the root class that interfaces with native code. Should not be used directly.</summary>
66     /// <param name="baseKlass">The pointer to the base native Eo class.</param>
67     /// <param name="parent">The Efl.Object parent of this instance.</param>
68     protected App(IntPtr baseKlass, Efl.Object parent) : base(baseKlass, parent)
69     {
70     }
71
72     /// <summary>Called when the application is not going be displayed or otherwise used by a user for some time
73     /// (Since EFL 1.22)</summary>
74     public event EventHandler PauseEvt
75     {
76         add
77         {
78             lock (eflBindingEventLock)
79             {
80                 Efl.EventCb callerCb = (IntPtr data, ref Efl.Event.NativeStruct evt) =>
81                 {
82                     var obj = Efl.Eo.Globals.WrapperSupervisorPtrToManaged(data).Target;
83                     if (obj != null)
84                     {
85                         EventArgs args = EventArgs.Empty;
86                         try
87                         {
88                             value?.Invoke(obj, args);
89                         }
90                         catch (Exception e)
91                         {
92                             Eina.Log.Error(e.ToString());
93                             Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
94                         }
95                     }
96                 };
97
98                 string key = "_EFL_APP_EVENT_PAUSE";
99                 AddNativeEventHandler(efl.Libs.Ecore, key, callerCb, value);
100             }
101         }
102
103         remove
104         {
105             lock (eflBindingEventLock)
106             {
107                 string key = "_EFL_APP_EVENT_PAUSE";
108                 RemoveNativeEventHandler(efl.Libs.Ecore, key, value);
109             }
110         }
111     }
112     /// <summary>Method to raise event PauseEvt.</summary>
113     public void OnPauseEvt(EventArgs e)
114     {
115         var key = "_EFL_APP_EVENT_PAUSE";
116         IntPtr desc = Efl.EventDescription.GetNative(efl.Libs.Ecore, key);
117         if (desc == IntPtr.Zero)
118         {
119             Eina.Log.Error($"Failed to get native event {key}");
120             return;
121         }
122
123         Efl.Eo.Globals.efl_event_callback_call(this.NativeHandle, desc, IntPtr.Zero);
124     }
125     /// <summary>Called before a window is rendered after a pause event
126     /// (Since EFL 1.22)</summary>
127     public event EventHandler ResumeEvt
128     {
129         add
130         {
131             lock (eflBindingEventLock)
132             {
133                 Efl.EventCb callerCb = (IntPtr data, ref Efl.Event.NativeStruct evt) =>
134                 {
135                     var obj = Efl.Eo.Globals.WrapperSupervisorPtrToManaged(data).Target;
136                     if (obj != null)
137                     {
138                         EventArgs args = EventArgs.Empty;
139                         try
140                         {
141                             value?.Invoke(obj, args);
142                         }
143                         catch (Exception e)
144                         {
145                             Eina.Log.Error(e.ToString());
146                             Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
147                         }
148                     }
149                 };
150
151                 string key = "_EFL_APP_EVENT_RESUME";
152                 AddNativeEventHandler(efl.Libs.Ecore, key, callerCb, value);
153             }
154         }
155
156         remove
157         {
158             lock (eflBindingEventLock)
159             {
160                 string key = "_EFL_APP_EVENT_RESUME";
161                 RemoveNativeEventHandler(efl.Libs.Ecore, key, value);
162             }
163         }
164     }
165     /// <summary>Method to raise event ResumeEvt.</summary>
166     public void OnResumeEvt(EventArgs e)
167     {
168         var key = "_EFL_APP_EVENT_RESUME";
169         IntPtr desc = Efl.EventDescription.GetNative(efl.Libs.Ecore, key);
170         if (desc == IntPtr.Zero)
171         {
172             Eina.Log.Error($"Failed to get native event {key}");
173             return;
174         }
175
176         Efl.Eo.Globals.efl_event_callback_call(this.NativeHandle, desc, IntPtr.Zero);
177     }
178     /// <summary>Called when the application&apos;s windows are all destroyed
179     /// (Since EFL 1.22)</summary>
180     public event EventHandler StandbyEvt
181     {
182         add
183         {
184             lock (eflBindingEventLock)
185             {
186                 Efl.EventCb callerCb = (IntPtr data, ref Efl.Event.NativeStruct evt) =>
187                 {
188                     var obj = Efl.Eo.Globals.WrapperSupervisorPtrToManaged(data).Target;
189                     if (obj != null)
190                     {
191                         EventArgs args = EventArgs.Empty;
192                         try
193                         {
194                             value?.Invoke(obj, args);
195                         }
196                         catch (Exception e)
197                         {
198                             Eina.Log.Error(e.ToString());
199                             Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
200                         }
201                     }
202                 };
203
204                 string key = "_EFL_APP_EVENT_STANDBY";
205                 AddNativeEventHandler(efl.Libs.Ecore, key, callerCb, value);
206             }
207         }
208
209         remove
210         {
211             lock (eflBindingEventLock)
212             {
213                 string key = "_EFL_APP_EVENT_STANDBY";
214                 RemoveNativeEventHandler(efl.Libs.Ecore, key, value);
215             }
216         }
217     }
218     /// <summary>Method to raise event StandbyEvt.</summary>
219     public void OnStandbyEvt(EventArgs e)
220     {
221         var key = "_EFL_APP_EVENT_STANDBY";
222         IntPtr desc = Efl.EventDescription.GetNative(efl.Libs.Ecore, key);
223         if (desc == IntPtr.Zero)
224         {
225             Eina.Log.Error($"Failed to get native event {key}");
226             return;
227         }
228
229         Efl.Eo.Globals.efl_event_callback_call(this.NativeHandle, desc, IntPtr.Zero);
230     }
231     /// <summary>Called before starting the shutdown of the application
232     /// (Since EFL 1.22)</summary>
233     public event EventHandler TerminateEvt
234     {
235         add
236         {
237             lock (eflBindingEventLock)
238             {
239                 Efl.EventCb callerCb = (IntPtr data, ref Efl.Event.NativeStruct evt) =>
240                 {
241                     var obj = Efl.Eo.Globals.WrapperSupervisorPtrToManaged(data).Target;
242                     if (obj != null)
243                     {
244                         EventArgs args = EventArgs.Empty;
245                         try
246                         {
247                             value?.Invoke(obj, args);
248                         }
249                         catch (Exception e)
250                         {
251                             Eina.Log.Error(e.ToString());
252                             Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
253                         }
254                     }
255                 };
256
257                 string key = "_EFL_APP_EVENT_TERMINATE";
258                 AddNativeEventHandler(efl.Libs.Ecore, key, callerCb, value);
259             }
260         }
261
262         remove
263         {
264             lock (eflBindingEventLock)
265             {
266                 string key = "_EFL_APP_EVENT_TERMINATE";
267                 RemoveNativeEventHandler(efl.Libs.Ecore, key, value);
268             }
269         }
270     }
271     /// <summary>Method to raise event TerminateEvt.</summary>
272     public void OnTerminateEvt(EventArgs e)
273     {
274         var key = "_EFL_APP_EVENT_TERMINATE";
275         IntPtr desc = Efl.EventDescription.GetNative(efl.Libs.Ecore, key);
276         if (desc == IntPtr.Zero)
277         {
278             Eina.Log.Error($"Failed to get native event {key}");
279             return;
280         }
281
282         Efl.Eo.Globals.efl_event_callback_call(this.NativeHandle, desc, IntPtr.Zero);
283     }
284     /// <summary>System specific, but on unix maps to SIGUSR1 signal to the process - only called on main loop object
285     /// (Since EFL 1.22)</summary>
286     public event EventHandler SignalUsr1Evt
287     {
288         add
289         {
290             lock (eflBindingEventLock)
291             {
292                 Efl.EventCb callerCb = (IntPtr data, ref Efl.Event.NativeStruct evt) =>
293                 {
294                     var obj = Efl.Eo.Globals.WrapperSupervisorPtrToManaged(data).Target;
295                     if (obj != null)
296                     {
297                         EventArgs args = EventArgs.Empty;
298                         try
299                         {
300                             value?.Invoke(obj, args);
301                         }
302                         catch (Exception e)
303                         {
304                             Eina.Log.Error(e.ToString());
305                             Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
306                         }
307                     }
308                 };
309
310                 string key = "_EFL_APP_EVENT_SIGNAL_USR1";
311                 AddNativeEventHandler(efl.Libs.Ecore, key, callerCb, value);
312             }
313         }
314
315         remove
316         {
317             lock (eflBindingEventLock)
318             {
319                 string key = "_EFL_APP_EVENT_SIGNAL_USR1";
320                 RemoveNativeEventHandler(efl.Libs.Ecore, key, value);
321             }
322         }
323     }
324     /// <summary>Method to raise event SignalUsr1Evt.</summary>
325     public void OnSignalUsr1Evt(EventArgs e)
326     {
327         var key = "_EFL_APP_EVENT_SIGNAL_USR1";
328         IntPtr desc = Efl.EventDescription.GetNative(efl.Libs.Ecore, key);
329         if (desc == IntPtr.Zero)
330         {
331             Eina.Log.Error($"Failed to get native event {key}");
332             return;
333         }
334
335         Efl.Eo.Globals.efl_event_callback_call(this.NativeHandle, desc, IntPtr.Zero);
336     }
337     /// <summary>System specific, but on unix maps to SIGUSR2 signal to the process - only called on main loop object
338     /// (Since EFL 1.22)</summary>
339     public event EventHandler SignalUsr2Evt
340     {
341         add
342         {
343             lock (eflBindingEventLock)
344             {
345                 Efl.EventCb callerCb = (IntPtr data, ref Efl.Event.NativeStruct evt) =>
346                 {
347                     var obj = Efl.Eo.Globals.WrapperSupervisorPtrToManaged(data).Target;
348                     if (obj != null)
349                     {
350                         EventArgs args = EventArgs.Empty;
351                         try
352                         {
353                             value?.Invoke(obj, args);
354                         }
355                         catch (Exception e)
356                         {
357                             Eina.Log.Error(e.ToString());
358                             Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
359                         }
360                     }
361                 };
362
363                 string key = "_EFL_APP_EVENT_SIGNAL_USR2";
364                 AddNativeEventHandler(efl.Libs.Ecore, key, callerCb, value);
365             }
366         }
367
368         remove
369         {
370             lock (eflBindingEventLock)
371             {
372                 string key = "_EFL_APP_EVENT_SIGNAL_USR2";
373                 RemoveNativeEventHandler(efl.Libs.Ecore, key, value);
374             }
375         }
376     }
377     /// <summary>Method to raise event SignalUsr2Evt.</summary>
378     public void OnSignalUsr2Evt(EventArgs e)
379     {
380         var key = "_EFL_APP_EVENT_SIGNAL_USR2";
381         IntPtr desc = Efl.EventDescription.GetNative(efl.Libs.Ecore, key);
382         if (desc == IntPtr.Zero)
383         {
384             Eina.Log.Error($"Failed to get native event {key}");
385             return;
386         }
387
388         Efl.Eo.Globals.efl_event_callback_call(this.NativeHandle, desc, IntPtr.Zero);
389     }
390     /// <summary>System specific, but on unix maps to SIGHUP signal to the process - only called on main loop object
391     /// (Since EFL 1.22)</summary>
392     public event EventHandler SignalHupEvt
393     {
394         add
395         {
396             lock (eflBindingEventLock)
397             {
398                 Efl.EventCb callerCb = (IntPtr data, ref Efl.Event.NativeStruct evt) =>
399                 {
400                     var obj = Efl.Eo.Globals.WrapperSupervisorPtrToManaged(data).Target;
401                     if (obj != null)
402                     {
403                         EventArgs args = EventArgs.Empty;
404                         try
405                         {
406                             value?.Invoke(obj, args);
407                         }
408                         catch (Exception e)
409                         {
410                             Eina.Log.Error(e.ToString());
411                             Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
412                         }
413                     }
414                 };
415
416                 string key = "_EFL_APP_EVENT_SIGNAL_HUP";
417                 AddNativeEventHandler(efl.Libs.Ecore, key, callerCb, value);
418             }
419         }
420
421         remove
422         {
423             lock (eflBindingEventLock)
424             {
425                 string key = "_EFL_APP_EVENT_SIGNAL_HUP";
426                 RemoveNativeEventHandler(efl.Libs.Ecore, key, value);
427             }
428         }
429     }
430     /// <summary>Method to raise event SignalHupEvt.</summary>
431     public void OnSignalHupEvt(EventArgs e)
432     {
433         var key = "_EFL_APP_EVENT_SIGNAL_HUP";
434         IntPtr desc = Efl.EventDescription.GetNative(efl.Libs.Ecore, key);
435         if (desc == IntPtr.Zero)
436         {
437             Eina.Log.Error($"Failed to get native event {key}");
438             return;
439         }
440
441         Efl.Eo.Globals.efl_event_callback_call(this.NativeHandle, desc, IntPtr.Zero);
442     }
443     /// <summary>Returns the app object that is representing this process
444     /// Note: This function call only works in the main loop thread of the process.
445     /// (Since EFL 1.22)</summary>
446     /// <returns>Application for this process</returns>
447     public static Efl.App GetAppMain() {
448          var _ret_var = Efl.App.NativeMethods.efl_app_main_get_ptr.Value.Delegate();
449         Eina.Error.RaiseIfUnhandledException();
450         return _ret_var;
451  }
452     /// <summary>Indicates the version of EFL with which this application was compiled against/for.
453     /// This might differ from <see cref="Efl.App.GetEflVersion"/>.
454     /// (Since EFL 1.22)</summary>
455     /// <returns>Efl build version</returns>
456     virtual public Efl.Version GetBuildEflVersion() {
457          var _ret_var = Efl.App.NativeMethods.efl_app_build_efl_version_get_ptr.Value.Delegate((IsGeneratedBindingClass ? this.NativeHandle : Efl.Eo.Globals.efl_super(this.NativeHandle, this.NativeClass)));
458         Eina.Error.RaiseIfUnhandledException();
459         var __ret_tmp = Eina.PrimitiveConversion.PointerToManaged<Efl.Version>(_ret_var);
460         
461         return __ret_tmp;
462  }
463     /// <summary>Indicates the currently running version of EFL.
464     /// This might differ from <see cref="Efl.App.GetBuildEflVersion"/>.
465     /// (Since EFL 1.22)</summary>
466     /// <returns>Efl version</returns>
467     virtual public Efl.Version GetEflVersion() {
468          var _ret_var = Efl.App.NativeMethods.efl_app_efl_version_get_ptr.Value.Delegate((IsGeneratedBindingClass ? this.NativeHandle : Efl.Eo.Globals.efl_super(this.NativeHandle, this.NativeClass)));
469         Eina.Error.RaiseIfUnhandledException();
470         var __ret_tmp = Eina.PrimitiveConversion.PointerToManaged<Efl.Version>(_ret_var);
471         
472         return __ret_tmp;
473  }
474     /// <summary>A commandline that encodes arguments in a command string. This command is unix shell-style, thus whitespace separates arguments unless escaped. Also a semi-colon &apos;;&apos;, ampersand &apos;&amp;&apos;, pipe/bar &apos;|&apos;, hash &apos;#&apos;, bracket, square brace, brace character (&apos;(&apos;, &apos;)&apos;, &apos;[&apos;, &apos;]&apos;, &apos;{&apos;, &apos;}&apos;), exclamation mark &apos;!&apos;,  backquote &apos;`&apos;, greator or less than (&apos;&gt;&apos; &apos;&lt;&apos;) character unless escaped or in quotes would cause args_count/value to not be generated properly, because it would force complex shell interpretation which will not be supported in evaluating the arg_count/value information, but the final shell may interpret this if this is executed via a command-line shell. To not be a complex shell command, it should be simple with paths, options and variable expansions, but nothing more complex involving the above unescaped characters.
475     /// &quot;cat -option /path/file&quot; &quot;cat &apos;quoted argument&apos;&quot; &quot;cat ~/path/escaped argument&quot; &quot;/bin/cat escaped argument <c>VARIABLE</c>&quot; etc.
476     /// 
477     /// It should not try and use &quot;complex shell features&quot; if you want the arg_count and arg_value set to be correct after setting the command string. For example none of:
478     /// 
479     /// &quot;VAR=x /bin/command &amp;&amp; /bin/othercommand &gt;&amp; /dev/null&quot; &quot;VAR=x /bin/command `/bin/othercommand` | /bin/cmd2 &amp;&amp; cmd3 &amp;&quot; etc.
480     /// 
481     /// If you set the command the arg_count/value property contents can change and be completely re-evaluated by parsing the command string into an argument array set along with interpreting escapes back into individual argument strings.</summary>
482     virtual public System.String GetCommand() {
483          var _ret_var = Efl.Core.ICommandLineConcrete.NativeMethods.efl_core_command_line_command_get_ptr.Value.Delegate((IsGeneratedBindingClass ? this.NativeHandle : Efl.Eo.Globals.efl_super(this.NativeHandle, this.NativeClass)));
484         Eina.Error.RaiseIfUnhandledException();
485         return _ret_var;
486  }
487     /// <summary>Use an array to fill this object
488     /// Every element of a string is a argument.</summary>
489     /// <param name="array">An array where every array field is an argument</param>
490     /// <returns>On success <c>true</c>, <c>false</c> otherwise</returns>
491     virtual public bool SetCommandArray(Eina.Array<Eina.Stringshare> array) {
492          var _in_array = array.Handle;
493 array.Own = false;
494 array.OwnContent = false;
495                         var _ret_var = Efl.Core.ICommandLineConcrete.NativeMethods.efl_core_command_line_command_array_set_ptr.Value.Delegate((IsGeneratedBindingClass ? this.NativeHandle : Efl.Eo.Globals.efl_super(this.NativeHandle, this.NativeClass)),_in_array);
496         Eina.Error.RaiseIfUnhandledException();
497                         return _ret_var;
498  }
499     /// <summary>Use a string to fill this object
500     /// The string will be split at every unescaped &apos; &apos;, every resulting substring will be a new argument to the command line.</summary>
501     /// <param name="str">A command in form of a string</param>
502     /// <returns>On success <c>true</c>, <c>false</c> otherwise</returns>
503     virtual public bool SetCommandString(System.String str) {
504                                  var _ret_var = Efl.Core.ICommandLineConcrete.NativeMethods.efl_core_command_line_command_string_set_ptr.Value.Delegate((IsGeneratedBindingClass ? this.NativeHandle : Efl.Eo.Globals.efl_super(this.NativeHandle, this.NativeClass)),str);
505         Eina.Error.RaiseIfUnhandledException();
506                         return _ret_var;
507  }
508     /// <summary>Get the accessor which enables access to each argument that got passed to this object.</summary>
509     virtual public Eina.Accessor<Eina.Stringshare> CommandAccess() {
510          var _ret_var = Efl.Core.ICommandLineConcrete.NativeMethods.efl_core_command_line_command_access_ptr.Value.Delegate((IsGeneratedBindingClass ? this.NativeHandle : Efl.Eo.Globals.efl_super(this.NativeHandle, this.NativeClass)));
511         Eina.Error.RaiseIfUnhandledException();
512         return new Eina.Accessor<Eina.Stringshare>(_ret_var, false);
513  }
514     /// <summary>Returns the app object that is representing this process
515     /// Note: This function call only works in the main loop thread of the process.
516     /// (Since EFL 1.22)</summary>
517     /// <value>Application for this process</value>
518     public static Efl.App AppMain {
519         get { return GetAppMain(); }
520     }
521     /// <summary>Indicates the version of EFL with which this application was compiled against/for.
522     /// This might differ from <see cref="Efl.App.GetEflVersion"/>.
523     /// (Since EFL 1.22)</summary>
524     /// <value>Efl build version</value>
525     public Efl.Version BuildEflVersion {
526         get { return GetBuildEflVersion(); }
527     }
528     /// <summary>Indicates the currently running version of EFL.
529     /// This might differ from <see cref="Efl.App.GetBuildEflVersion"/>.
530     /// (Since EFL 1.22)</summary>
531     /// <value>Efl version</value>
532     public Efl.Version EflVersion {
533         get { return GetEflVersion(); }
534     }
535     /// <summary>A commandline that encodes arguments in a command string. This command is unix shell-style, thus whitespace separates arguments unless escaped. Also a semi-colon &apos;;&apos;, ampersand &apos;&amp;&apos;, pipe/bar &apos;|&apos;, hash &apos;#&apos;, bracket, square brace, brace character (&apos;(&apos;, &apos;)&apos;, &apos;[&apos;, &apos;]&apos;, &apos;{&apos;, &apos;}&apos;), exclamation mark &apos;!&apos;,  backquote &apos;`&apos;, greator or less than (&apos;&gt;&apos; &apos;&lt;&apos;) character unless escaped or in quotes would cause args_count/value to not be generated properly, because it would force complex shell interpretation which will not be supported in evaluating the arg_count/value information, but the final shell may interpret this if this is executed via a command-line shell. To not be a complex shell command, it should be simple with paths, options and variable expansions, but nothing more complex involving the above unescaped characters.
536     /// &quot;cat -option /path/file&quot; &quot;cat &apos;quoted argument&apos;&quot; &quot;cat ~/path/escaped argument&quot; &quot;/bin/cat escaped argument <c>VARIABLE</c>&quot; etc.
537     /// 
538     /// It should not try and use &quot;complex shell features&quot; if you want the arg_count and arg_value set to be correct after setting the command string. For example none of:
539     /// 
540     /// &quot;VAR=x /bin/command &amp;&amp; /bin/othercommand &gt;&amp; /dev/null&quot; &quot;VAR=x /bin/command `/bin/othercommand` | /bin/cmd2 &amp;&amp; cmd3 &amp;&quot; etc.
541     /// 
542     /// If you set the command the arg_count/value property contents can change and be completely re-evaluated by parsing the command string into an argument array set along with interpreting escapes back into individual argument strings.</summary>
543     public System.String Command {
544         get { return GetCommand(); }
545     }
546     /// <summary>Use an array to fill this object
547     /// Every element of a string is a argument.</summary>
548     /// <value>An array where every array field is an argument</value>
549     public Eina.Array<Eina.Stringshare> CommandArray {
550         set { SetCommandArray(value); }
551     }
552     /// <summary>Use a string to fill this object
553     /// The string will be split at every unescaped &apos; &apos;, every resulting substring will be a new argument to the command line.</summary>
554     /// <value>A command in form of a string</value>
555     public System.String CommandString {
556         set { SetCommandString(value); }
557     }
558     private static IntPtr GetEflClassStatic()
559     {
560         return Efl.App.efl_app_class_get();
561     }
562     /// <summary>Wrapper for native methods and virtual method delegates.
563     /// For internal use by generated code only.</summary>
564     public new class NativeMethods : Efl.Loop.NativeMethods
565     {
566         private static Efl.Eo.NativeModule Module = new Efl.Eo.NativeModule(    efl.Libs.Ecore);
567         /// <summary>Gets the list of Eo operations to override.</summary>
568         /// <returns>The list of Eo operations to be overload.</returns>
569         public override System.Collections.Generic.List<Efl_Op_Description> GetEoOps(System.Type type)
570         {
571             var descs = new System.Collections.Generic.List<Efl_Op_Description>();
572             var methods = Efl.Eo.Globals.GetUserMethods(type);
573
574             if (efl_app_build_efl_version_get_static_delegate == null)
575             {
576                 efl_app_build_efl_version_get_static_delegate = new efl_app_build_efl_version_get_delegate(build_efl_version_get);
577             }
578
579             if (methods.FirstOrDefault(m => m.Name == "GetBuildEflVersion") != null)
580             {
581                 descs.Add(new Efl_Op_Description() {api_func = Efl.Eo.FunctionInterop.LoadFunctionPointer(Module.Module, "efl_app_build_efl_version_get"), func = Marshal.GetFunctionPointerForDelegate(efl_app_build_efl_version_get_static_delegate) });
582             }
583
584             if (efl_app_efl_version_get_static_delegate == null)
585             {
586                 efl_app_efl_version_get_static_delegate = new efl_app_efl_version_get_delegate(efl_version_get);
587             }
588
589             if (methods.FirstOrDefault(m => m.Name == "GetEflVersion") != null)
590             {
591                 descs.Add(new Efl_Op_Description() {api_func = Efl.Eo.FunctionInterop.LoadFunctionPointer(Module.Module, "efl_app_efl_version_get"), func = Marshal.GetFunctionPointerForDelegate(efl_app_efl_version_get_static_delegate) });
592             }
593
594             if (efl_core_command_line_command_get_static_delegate == null)
595             {
596                 efl_core_command_line_command_get_static_delegate = new efl_core_command_line_command_get_delegate(command_get);
597             }
598
599             if (methods.FirstOrDefault(m => m.Name == "GetCommand") != null)
600             {
601                 descs.Add(new Efl_Op_Description() {api_func = Efl.Eo.FunctionInterop.LoadFunctionPointer(Module.Module, "efl_core_command_line_command_get"), func = Marshal.GetFunctionPointerForDelegate(efl_core_command_line_command_get_static_delegate) });
602             }
603
604             if (efl_core_command_line_command_array_set_static_delegate == null)
605             {
606                 efl_core_command_line_command_array_set_static_delegate = new efl_core_command_line_command_array_set_delegate(command_array_set);
607             }
608
609             if (methods.FirstOrDefault(m => m.Name == "SetCommandArray") != null)
610             {
611                 descs.Add(new Efl_Op_Description() {api_func = Efl.Eo.FunctionInterop.LoadFunctionPointer(Module.Module, "efl_core_command_line_command_array_set"), func = Marshal.GetFunctionPointerForDelegate(efl_core_command_line_command_array_set_static_delegate) });
612             }
613
614             if (efl_core_command_line_command_string_set_static_delegate == null)
615             {
616                 efl_core_command_line_command_string_set_static_delegate = new efl_core_command_line_command_string_set_delegate(command_string_set);
617             }
618
619             if (methods.FirstOrDefault(m => m.Name == "SetCommandString") != null)
620             {
621                 descs.Add(new Efl_Op_Description() {api_func = Efl.Eo.FunctionInterop.LoadFunctionPointer(Module.Module, "efl_core_command_line_command_string_set"), func = Marshal.GetFunctionPointerForDelegate(efl_core_command_line_command_string_set_static_delegate) });
622             }
623
624             if (efl_core_command_line_command_access_static_delegate == null)
625             {
626                 efl_core_command_line_command_access_static_delegate = new efl_core_command_line_command_access_delegate(command_access);
627             }
628
629             if (methods.FirstOrDefault(m => m.Name == "CommandAccess") != null)
630             {
631                 descs.Add(new Efl_Op_Description() {api_func = Efl.Eo.FunctionInterop.LoadFunctionPointer(Module.Module, "efl_core_command_line_command_access"), func = Marshal.GetFunctionPointerForDelegate(efl_core_command_line_command_access_static_delegate) });
632             }
633
634             descs.AddRange(base.GetEoOps(type));
635             return descs;
636         }
637         /// <summary>Returns the Eo class for the native methods of this class.</summary>
638         /// <returns>The native class pointer.</returns>
639         public override IntPtr GetEflClass()
640         {
641             return Efl.App.efl_app_class_get();
642         }
643
644         #pragma warning disable CA1707, CS1591, SA1300, SA1600
645
646         [return:MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Efl.Eo.MarshalEo<Efl.Eo.NonOwnTag>))]
647         private delegate Efl.App efl_app_main_get_delegate();
648
649         [return:MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Efl.Eo.MarshalEo<Efl.Eo.NonOwnTag>))]
650         public delegate Efl.App efl_app_main_get_api_delegate();
651
652         public static Efl.Eo.FunctionWrapper<efl_app_main_get_api_delegate> efl_app_main_get_ptr = new Efl.Eo.FunctionWrapper<efl_app_main_get_api_delegate>(Module, "efl_app_main_get");
653
654         private static Efl.App app_main_get(System.IntPtr obj, System.IntPtr pd)
655         {
656             Eina.Log.Debug("function efl_app_main_get was called");
657             var ws = Efl.Eo.Globals.GetWrapperSupervisor(obj);
658             if (ws != null)
659             {
660             Efl.App _ret_var = default(Efl.App);
661                 try
662                 {
663                     _ret_var = App.GetAppMain();
664                 }
665                 catch (Exception e)
666                 {
667                     Eina.Log.Warning($"Callback error: {e.ToString()}");
668                     Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
669                 }
670
671         return _ret_var;
672
673             }
674             else
675             {
676                 return efl_app_main_get_ptr.Value.Delegate();
677             }
678         }
679
680         
681         private delegate System.IntPtr efl_app_build_efl_version_get_delegate(System.IntPtr obj, System.IntPtr pd);
682
683         
684         public delegate System.IntPtr efl_app_build_efl_version_get_api_delegate(System.IntPtr obj);
685
686         public static Efl.Eo.FunctionWrapper<efl_app_build_efl_version_get_api_delegate> efl_app_build_efl_version_get_ptr = new Efl.Eo.FunctionWrapper<efl_app_build_efl_version_get_api_delegate>(Module, "efl_app_build_efl_version_get");
687
688         private static System.IntPtr build_efl_version_get(System.IntPtr obj, System.IntPtr pd)
689         {
690             Eina.Log.Debug("function efl_app_build_efl_version_get was called");
691             var ws = Efl.Eo.Globals.GetWrapperSupervisor(obj);
692             if (ws != null)
693             {
694             Efl.Version _ret_var = default(Efl.Version);
695                 try
696                 {
697                     _ret_var = ((App)ws.Target).GetBuildEflVersion();
698                 }
699                 catch (Exception e)
700                 {
701                     Eina.Log.Warning($"Callback error: {e.ToString()}");
702                     Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
703                 }
704
705         return Eina.PrimitiveConversion.ManagedToPointerAlloc(_ret_var);
706
707             }
708             else
709             {
710                 return efl_app_build_efl_version_get_ptr.Value.Delegate(Efl.Eo.Globals.efl_super(obj, Efl.Eo.Globals.efl_class_get(obj)));
711             }
712         }
713
714         private static efl_app_build_efl_version_get_delegate efl_app_build_efl_version_get_static_delegate;
715
716         
717         private delegate System.IntPtr efl_app_efl_version_get_delegate(System.IntPtr obj, System.IntPtr pd);
718
719         
720         public delegate System.IntPtr efl_app_efl_version_get_api_delegate(System.IntPtr obj);
721
722         public static Efl.Eo.FunctionWrapper<efl_app_efl_version_get_api_delegate> efl_app_efl_version_get_ptr = new Efl.Eo.FunctionWrapper<efl_app_efl_version_get_api_delegate>(Module, "efl_app_efl_version_get");
723
724         private static System.IntPtr efl_version_get(System.IntPtr obj, System.IntPtr pd)
725         {
726             Eina.Log.Debug("function efl_app_efl_version_get was called");
727             var ws = Efl.Eo.Globals.GetWrapperSupervisor(obj);
728             if (ws != null)
729             {
730             Efl.Version _ret_var = default(Efl.Version);
731                 try
732                 {
733                     _ret_var = ((App)ws.Target).GetEflVersion();
734                 }
735                 catch (Exception e)
736                 {
737                     Eina.Log.Warning($"Callback error: {e.ToString()}");
738                     Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
739                 }
740
741         return Eina.PrimitiveConversion.ManagedToPointerAlloc(_ret_var);
742
743             }
744             else
745             {
746                 return efl_app_efl_version_get_ptr.Value.Delegate(Efl.Eo.Globals.efl_super(obj, Efl.Eo.Globals.efl_class_get(obj)));
747             }
748         }
749
750         private static efl_app_efl_version_get_delegate efl_app_efl_version_get_static_delegate;
751
752         [return: MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Efl.Eo.StringKeepOwnershipMarshaler))]
753         private delegate System.String efl_core_command_line_command_get_delegate(System.IntPtr obj, System.IntPtr pd);
754
755         [return: MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Efl.Eo.StringKeepOwnershipMarshaler))]
756         public delegate System.String efl_core_command_line_command_get_api_delegate(System.IntPtr obj);
757
758         public static Efl.Eo.FunctionWrapper<efl_core_command_line_command_get_api_delegate> efl_core_command_line_command_get_ptr = new Efl.Eo.FunctionWrapper<efl_core_command_line_command_get_api_delegate>(Module, "efl_core_command_line_command_get");
759
760         private static System.String command_get(System.IntPtr obj, System.IntPtr pd)
761         {
762             Eina.Log.Debug("function efl_core_command_line_command_get was called");
763             var ws = Efl.Eo.Globals.GetWrapperSupervisor(obj);
764             if (ws != null)
765             {
766             System.String _ret_var = default(System.String);
767                 try
768                 {
769                     _ret_var = ((App)ws.Target).GetCommand();
770                 }
771                 catch (Exception e)
772                 {
773                     Eina.Log.Warning($"Callback error: {e.ToString()}");
774                     Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
775                 }
776
777         return _ret_var;
778
779             }
780             else
781             {
782                 return efl_core_command_line_command_get_ptr.Value.Delegate(Efl.Eo.Globals.efl_super(obj, Efl.Eo.Globals.efl_class_get(obj)));
783             }
784         }
785
786         private static efl_core_command_line_command_get_delegate efl_core_command_line_command_get_static_delegate;
787
788         [return: MarshalAs(UnmanagedType.U1)]
789         private delegate bool efl_core_command_line_command_array_set_delegate(System.IntPtr obj, System.IntPtr pd,  System.IntPtr array);
790
791         [return: MarshalAs(UnmanagedType.U1)]
792         public delegate bool efl_core_command_line_command_array_set_api_delegate(System.IntPtr obj,  System.IntPtr array);
793
794         public static Efl.Eo.FunctionWrapper<efl_core_command_line_command_array_set_api_delegate> efl_core_command_line_command_array_set_ptr = new Efl.Eo.FunctionWrapper<efl_core_command_line_command_array_set_api_delegate>(Module, "efl_core_command_line_command_array_set");
795
796         private static bool command_array_set(System.IntPtr obj, System.IntPtr pd, System.IntPtr array)
797         {
798             Eina.Log.Debug("function efl_core_command_line_command_array_set was called");
799             var ws = Efl.Eo.Globals.GetWrapperSupervisor(obj);
800             if (ws != null)
801             {
802         var _in_array = new Eina.Array<Eina.Stringshare>(array, true, true);
803                             bool _ret_var = default(bool);
804                 try
805                 {
806                     _ret_var = ((App)ws.Target).SetCommandArray(_in_array);
807                 }
808                 catch (Exception e)
809                 {
810                     Eina.Log.Warning($"Callback error: {e.ToString()}");
811                     Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
812                 }
813
814                         return _ret_var;
815
816             }
817             else
818             {
819                 return efl_core_command_line_command_array_set_ptr.Value.Delegate(Efl.Eo.Globals.efl_super(obj, Efl.Eo.Globals.efl_class_get(obj)), array);
820             }
821         }
822
823         private static efl_core_command_line_command_array_set_delegate efl_core_command_line_command_array_set_static_delegate;
824
825         [return: MarshalAs(UnmanagedType.U1)]
826         private delegate bool efl_core_command_line_command_string_set_delegate(System.IntPtr obj, System.IntPtr pd, [MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Efl.Eo.StringKeepOwnershipMarshaler))] System.String str);
827
828         [return: MarshalAs(UnmanagedType.U1)]
829         public delegate bool efl_core_command_line_command_string_set_api_delegate(System.IntPtr obj, [MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(Efl.Eo.StringKeepOwnershipMarshaler))] System.String str);
830
831         public static Efl.Eo.FunctionWrapper<efl_core_command_line_command_string_set_api_delegate> efl_core_command_line_command_string_set_ptr = new Efl.Eo.FunctionWrapper<efl_core_command_line_command_string_set_api_delegate>(Module, "efl_core_command_line_command_string_set");
832
833         private static bool command_string_set(System.IntPtr obj, System.IntPtr pd, System.String str)
834         {
835             Eina.Log.Debug("function efl_core_command_line_command_string_set was called");
836             var ws = Efl.Eo.Globals.GetWrapperSupervisor(obj);
837             if (ws != null)
838             {
839                                     bool _ret_var = default(bool);
840                 try
841                 {
842                     _ret_var = ((App)ws.Target).SetCommandString(str);
843                 }
844                 catch (Exception e)
845                 {
846                     Eina.Log.Warning($"Callback error: {e.ToString()}");
847                     Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
848                 }
849
850                         return _ret_var;
851
852             }
853             else
854             {
855                 return efl_core_command_line_command_string_set_ptr.Value.Delegate(Efl.Eo.Globals.efl_super(obj, Efl.Eo.Globals.efl_class_get(obj)), str);
856             }
857         }
858
859         private static efl_core_command_line_command_string_set_delegate efl_core_command_line_command_string_set_static_delegate;
860
861         
862         private delegate System.IntPtr efl_core_command_line_command_access_delegate(System.IntPtr obj, System.IntPtr pd);
863
864         
865         public delegate System.IntPtr efl_core_command_line_command_access_api_delegate(System.IntPtr obj);
866
867         public static Efl.Eo.FunctionWrapper<efl_core_command_line_command_access_api_delegate> efl_core_command_line_command_access_ptr = new Efl.Eo.FunctionWrapper<efl_core_command_line_command_access_api_delegate>(Module, "efl_core_command_line_command_access");
868
869         private static System.IntPtr command_access(System.IntPtr obj, System.IntPtr pd)
870         {
871             Eina.Log.Debug("function efl_core_command_line_command_access was called");
872             var ws = Efl.Eo.Globals.GetWrapperSupervisor(obj);
873             if (ws != null)
874             {
875             Eina.Accessor<Eina.Stringshare> _ret_var = default(Eina.Accessor<Eina.Stringshare>);
876                 try
877                 {
878                     _ret_var = ((App)ws.Target).CommandAccess();
879                 }
880                 catch (Exception e)
881                 {
882                     Eina.Log.Warning($"Callback error: {e.ToString()}");
883                     Eina.Error.Set(Eina.Error.UNHANDLED_EXCEPTION);
884                 }
885
886         return _ret_var.Handle;
887
888             }
889             else
890             {
891                 return efl_core_command_line_command_access_ptr.Value.Delegate(Efl.Eo.Globals.efl_super(obj, Efl.Eo.Globals.efl_class_get(obj)));
892             }
893         }
894
895         private static efl_core_command_line_command_access_delegate efl_core_command_line_command_access_static_delegate;
896
897         #pragma warning restore CA1707, CS1591, SA1300, SA1600
898
899 }
900 }
901 }
902
903 #if EFL_BETA
904 #pragma warning disable CS1591
905 public static class EflApp_ExtensionMethods {
906     
907     
908     
909     
910     public static Efl.BindableProperty<Eina.Array<Eina.Stringshare>> CommandArray<T>(this Efl.Ui.ItemFactory<T> fac, Efl.Csharp.ExtensionTag<Efl.App, T>magic = null) where T : Efl.App {
911         return new Efl.BindableProperty<Eina.Array<Eina.Stringshare>>("command_array", fac);
912     }
913
914     public static Efl.BindableProperty<System.String> CommandString<T>(this Efl.Ui.ItemFactory<T> fac, Efl.Csharp.ExtensionTag<Efl.App, T>magic = null) where T : Efl.App {
915         return new Efl.BindableProperty<System.String>("command_string", fac);
916     }
917
918 }
919 #pragma warning restore CS1591
920 #endif