Class Efl.Eo.EoWrapper
Abstract class that delivers base level binding to Efl Objects.
Most of it is protected functionalities to serve the generated binding classes that inherit from it.
Constructors
EoWrapper(EoWrapper.ConstructingHandle)
Constructor to be used when objects are expected to be constructed from native code.
For a class that inherited from an EFL# class to be properly constructed from native code
one must create a constructor with this signature and calls this base constructor from it.
This constructor will take care of calling base constructors of the native classes and
perform additional setup so objects are ready to use.
It is advisable to check for the Efl.Eo.EoWrapper.NativeHandle property in the top level
constructor and signal an error when it has a value of IntPtr.Zero after this
constructor completion.
Warning: Do not use this constructor directly from a new
statement.
Declaration
protected EoWrapper(EoWrapper.ConstructingHandle ch)
Parameters
Type | Name | Description |
---|---|---|
Efl.Eo.EoWrapper.ConstructingHandle | ch | Tag struct storing the native handle of the object being constructed. |
EoWrapper(IntPtr, Object, String, Int32)
Initializes a new instance of the Efl.Object class. Internal usage: Constructor to actually call the native library constructors. C# subclasses must use the public constructor only.
Declaration
protected EoWrapper(IntPtr baseKlass, Object parent, string file = null, int line = 0)
Parameters
Type | Name | Description |
---|---|---|
System.IntPtr | baseKlass | The pointer to the base native Eo class. |
Efl.Object | parent | The Efl.Object parent of this instance. |
System.String | file | Name of the file from where the constructor is called. |
System.Int32 | line | Number of the line from where the constructor is called. |
Fields
eflBindingEventLock
Object used to synchronize access to EFL events.
Declaration
protected readonly object eflBindingEventLock
Field Value
Type | Description |
---|---|
System.Object |
Properties
IsGeneratedBindingClass
Whether this object type is one of the generated binding classes or a custom class defined by the user and that inherit from one of the generated ones.
Declaration
protected bool IsGeneratedBindingClass { get; }
Property Value
Type | Description |
---|---|
System.Boolean | True if this object type is one of the generated binding classes, false if it is class that is manually defined and that inherits from one of the generated ones, including user defined classes. |
NativeHandle
Pointer to the native instance.
Declaration
public IntPtr NativeHandle { get; }
Property Value
Type | Description |
---|---|
System.IntPtr |
Methods
AddNativeEventHandler(String, String, EventCb, Object)
Adds a new event handler, registering it to the native event. For internal use only.
Declaration
protected void AddNativeEventHandler(string lib, string key, EventCb evtCaller, object evtDelegate)
Parameters
Type | Name | Description |
---|---|---|
System.String | lib | The name of the native library definining the event. |
System.String | key | The name of the native event. |
Efl.EventCb | evtCaller | Delegate to be called by native code on event raising. |
System.Object | evtDelegate | Managed delegate that will be called by evtCaller on event raising. |
Del()
Releases the underlying Eo object.
This method is a C# counterpart to the C efl_del
function. It removes the parent of the object
and releases the Eo reference it was holding.
Declaration
public void Del()
Dispose()
Releases the underlying native instance.
Declaration
public void Dispose()
Dispose(Boolean)
Releases the underlying native instance.
Declaration
protected virtual void Dispose(bool disposing)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | disposing |
Finalize()
Destructor.
Declaration
protected void Finalize()
FinishInstantiation()
Finishes instantiating this object. Internal usage by generated code.
Declaration
protected void FinishInstantiation()
GetKeyValue(Object)
Get a value object associated with a key object.
Declaration
public object GetKeyValue(object key)
Parameters
Type | Name | Description |
---|---|---|
System.Object | key |
Returns
Type | Description |
---|---|
System.Object |
RemoveNativeEventHandler(String, String, Object)
Removes the given event handler for the given event. For internal use only.
Declaration
protected void RemoveNativeEventHandler(string lib, string key, object evtDelegate)
Parameters
Type | Name | Description |
---|---|---|
System.String | lib | The name of the native library definining the event. |
System.String | key | The name of the native event. |
System.Object | evtDelegate | The delegate to be removed. |
SetKeyValue(Object, Object)
Set a value object associated with a key object.
Declaration
public void SetKeyValue(object key, object val)
Parameters
Type | Name | Description |
---|---|---|
System.Object | key | |
System.Object | val |
ToString()
Turns the native pointer into a string representation.
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
System.String | A string with the type and the native pointer for this object. |