Class ExpandableListAdapter
public class ExpandableListAdapter : JVMBridgeListener, IDynamicMetaObjectProvider, IJVMBridgeCore, IEquatable<IJVMBridgeBaseInstance>, IDisposable, IJVMBridgeBaseStatic, IJVMBridgeBase, IJVMBridgeBaseInstance, IJVMBridgeDefinition, IExpandableListAdapter
- Inheritance
-
ExpandableListAdapter
- Implements
- Derived
- Extension Methods
Constructors
ExpandableListAdapter(IJVMBridgeBaseInitializer)
Initializer used internally by JCOBridge. Do not use directly.
[Obsolete("This public initializer is needed for JCOBridge internal use, other uses can produce unidentifiable behaviors.")]
public ExpandableListAdapter(IJVMBridgeBaseInitializer initializer)
Parameters
initializerIJVMBridgeBaseInitializer
ExpandableListAdapter(params object[])
Generic constructor used by JCOBridge when a derived class needs to forward arguments to the base JVMBridgeBase class.
public ExpandableListAdapter(params object[] args)
Parameters
argsobject[]
Properties
BridgeClassName
Java class name to be instantiated
public override string BridgeClassName { get; }
Property Value
OnAreAllItemsEnabled
Handler for https://developer.android.com/reference/android/widget/ExpandableListAdapter.html#areAllItemsEnabled()
public Func<bool> OnAreAllItemsEnabled { get; set; }
Property Value
Remarks
Assign a delegate to handle the event without subclassing. If both this handler and a virtual method override are present, the delegate takes precedence. Set to null to delegate to the virtual method.
OnAreAllItemsEnabledDispose
Optional handler invoked after the event handler returns, to dispose the JVM object returned by this event.
public Action<bool> OnAreAllItemsEnabledDispose { get; set; }
Property Value
Remarks
Set OnAreAllItemsEnabledDispose when the event handler returns a JVM-backed object that is no longer needed after the call. The handler receives the return value and is responsible for calling Dispose() on it, releasing the underlying JVM global reference immediately instead of waiting for the .NET garbage collector to finalize it. If not set, the return value is not disposed automatically.
OnGetChild
Handler for https://developer.android.com/reference/android/widget/ExpandableListAdapter.html#getChild(int,int)
public Func<int, int, object> OnGetChild { get; set; }
Property Value
Remarks
Assign a delegate to handle the event without subclassing. If both this handler and a virtual method override are present, the delegate takes precedence. Set to null to delegate to the virtual method.
OnGetChildDispose
Optional handler invoked after the event handler returns, to dispose the JVM object returned by this event.
public Action<object> OnGetChildDispose { get; set; }
Property Value
Remarks
Set OnGetChildDispose when the event handler returns a JVM-backed object that is no longer needed after the call. The handler receives the return value and is responsible for calling Dispose() on it, releasing the underlying JVM global reference immediately instead of waiting for the .NET garbage collector to finalize it. If not set, the return value is not disposed automatically.
OnGetChildId
Handler for https://developer.android.com/reference/android/widget/ExpandableListAdapter.html#getChildId(int,int)
public Func<int, int, long> OnGetChildId { get; set; }
Property Value
Remarks
Assign a delegate to handle the event without subclassing. If both this handler and a virtual method override are present, the delegate takes precedence. Set to null to delegate to the virtual method.
OnGetChildIdDispose
Optional handler invoked after the event handler returns, to dispose the JVM object returned by this event.
public Action<long> OnGetChildIdDispose { get; set; }
Property Value
Remarks
Set OnGetChildIdDispose when the event handler returns a JVM-backed object that is no longer needed after the call. The handler receives the return value and is responsible for calling Dispose() on it, releasing the underlying JVM global reference immediately instead of waiting for the .NET garbage collector to finalize it. If not set, the return value is not disposed automatically.
OnGetChildView
public Func<int, int, bool, View, ViewGroup, View> OnGetChildView { get; set; }
Property Value
Remarks
Assign a delegate to handle the event without subclassing. If both this handler and a virtual method override are present, the delegate takes precedence. Set to null to delegate to the virtual method.
OnGetChildViewDispose
Optional handler invoked after the event handler returns, to dispose the JVM object returned by this event.
public Action<View> OnGetChildViewDispose { get; set; }
Property Value
Remarks
Set OnGetChildViewDispose when the event handler returns a JVM-backed object that is no longer needed after the call. The handler receives the return value and is responsible for calling Dispose() on it, releasing the underlying JVM global reference immediately instead of waiting for the .NET garbage collector to finalize it. If not set, the return value is not disposed automatically.
OnGetChildrenCount
Handler for https://developer.android.com/reference/android/widget/ExpandableListAdapter.html#getChildrenCount(int)
public Func<int, int> OnGetChildrenCount { get; set; }
Property Value
Remarks
Assign a delegate to handle the event without subclassing. If both this handler and a virtual method override are present, the delegate takes precedence. Set to null to delegate to the virtual method.
OnGetChildrenCountDispose
Optional handler invoked after the event handler returns, to dispose the JVM object returned by this event.
public Action<int> OnGetChildrenCountDispose { get; set; }
Property Value
Remarks
Set OnGetChildrenCountDispose when the event handler returns a JVM-backed object that is no longer needed after the call. The handler receives the return value and is responsible for calling Dispose() on it, releasing the underlying JVM global reference immediately instead of waiting for the .NET garbage collector to finalize it. If not set, the return value is not disposed automatically.
OnGetCombinedChildId
public Func<long, long, long> OnGetCombinedChildId { get; set; }
Property Value
Remarks
Assign a delegate to handle the event without subclassing. If both this handler and a virtual method override are present, the delegate takes precedence. Set to null to delegate to the virtual method.
OnGetCombinedChildIdDispose
Optional handler invoked after the event handler returns, to dispose the JVM object returned by this event.
public Action<long> OnGetCombinedChildIdDispose { get; set; }
Property Value
Remarks
Set OnGetCombinedChildIdDispose when the event handler returns a JVM-backed object that is no longer needed after the call. The handler receives the return value and is responsible for calling Dispose() on it, releasing the underlying JVM global reference immediately instead of waiting for the .NET garbage collector to finalize it. If not set, the return value is not disposed automatically.
OnGetCombinedGroupId
Handler for https://developer.android.com/reference/android/widget/ExpandableListAdapter.html#getCombinedGroupId(long)
public Func<long, long> OnGetCombinedGroupId { get; set; }
Property Value
Remarks
Assign a delegate to handle the event without subclassing. If both this handler and a virtual method override are present, the delegate takes precedence. Set to null to delegate to the virtual method.
OnGetCombinedGroupIdDispose
Optional handler invoked after the event handler returns, to dispose the JVM object returned by this event.
public Action<long> OnGetCombinedGroupIdDispose { get; set; }
Property Value
Remarks
Set OnGetCombinedGroupIdDispose when the event handler returns a JVM-backed object that is no longer needed after the call. The handler receives the return value and is responsible for calling Dispose() on it, releasing the underlying JVM global reference immediately instead of waiting for the .NET garbage collector to finalize it. If not set, the return value is not disposed automatically.
OnGetGroup
Handler for https://developer.android.com/reference/android/widget/ExpandableListAdapter.html#getGroup(int)
public Func<int, object> OnGetGroup { get; set; }
Property Value
Remarks
Assign a delegate to handle the event without subclassing. If both this handler and a virtual method override are present, the delegate takes precedence. Set to null to delegate to the virtual method.
OnGetGroupCount
Handler for https://developer.android.com/reference/android/widget/ExpandableListAdapter.html#getGroupCount()
public Func<int> OnGetGroupCount { get; set; }
Property Value
Remarks
Assign a delegate to handle the event without subclassing. If both this handler and a virtual method override are present, the delegate takes precedence. Set to null to delegate to the virtual method.
OnGetGroupCountDispose
Optional handler invoked after the event handler returns, to dispose the JVM object returned by this event.
public Action<int> OnGetGroupCountDispose { get; set; }
Property Value
Remarks
Set OnGetGroupCountDispose when the event handler returns a JVM-backed object that is no longer needed after the call. The handler receives the return value and is responsible for calling Dispose() on it, releasing the underlying JVM global reference immediately instead of waiting for the .NET garbage collector to finalize it. If not set, the return value is not disposed automatically.
OnGetGroupDispose
Optional handler invoked after the event handler returns, to dispose the JVM object returned by this event.
public Action<object> OnGetGroupDispose { get; set; }
Property Value
Remarks
Set OnGetGroupDispose when the event handler returns a JVM-backed object that is no longer needed after the call. The handler receives the return value and is responsible for calling Dispose() on it, releasing the underlying JVM global reference immediately instead of waiting for the .NET garbage collector to finalize it. If not set, the return value is not disposed automatically.
OnGetGroupId
Handler for https://developer.android.com/reference/android/widget/ExpandableListAdapter.html#getGroupId(int)
public Func<int, long> OnGetGroupId { get; set; }
Property Value
Remarks
Assign a delegate to handle the event without subclassing. If both this handler and a virtual method override are present, the delegate takes precedence. Set to null to delegate to the virtual method.
OnGetGroupIdDispose
Optional handler invoked after the event handler returns, to dispose the JVM object returned by this event.
public Action<long> OnGetGroupIdDispose { get; set; }
Property Value
Remarks
Set OnGetGroupIdDispose when the event handler returns a JVM-backed object that is no longer needed after the call. The handler receives the return value and is responsible for calling Dispose() on it, releasing the underlying JVM global reference immediately instead of waiting for the .NET garbage collector to finalize it. If not set, the return value is not disposed automatically.
OnGetGroupView
public Func<int, bool, View, ViewGroup, View> OnGetGroupView { get; set; }
Property Value
Remarks
Assign a delegate to handle the event without subclassing. If both this handler and a virtual method override are present, the delegate takes precedence. Set to null to delegate to the virtual method.
OnGetGroupViewDispose
Optional handler invoked after the event handler returns, to dispose the JVM object returned by this event.
public Action<View> OnGetGroupViewDispose { get; set; }
Property Value
Remarks
Set OnGetGroupViewDispose when the event handler returns a JVM-backed object that is no longer needed after the call. The handler receives the return value and is responsible for calling Dispose() on it, releasing the underlying JVM global reference immediately instead of waiting for the .NET garbage collector to finalize it. If not set, the return value is not disposed automatically.
OnHasStableIds
Handler for https://developer.android.com/reference/android/widget/ExpandableListAdapter.html#hasStableIds()
public Func<bool> OnHasStableIds { get; set; }
Property Value
Remarks
Assign a delegate to handle the event without subclassing. If both this handler and a virtual method override are present, the delegate takes precedence. Set to null to delegate to the virtual method.
OnHasStableIdsDispose
Optional handler invoked after the event handler returns, to dispose the JVM object returned by this event.
public Action<bool> OnHasStableIdsDispose { get; set; }
Property Value
Remarks
Set OnHasStableIdsDispose when the event handler returns a JVM-backed object that is no longer needed after the call. The handler receives the return value and is responsible for calling Dispose() on it, releasing the underlying JVM global reference immediately instead of waiting for the .NET garbage collector to finalize it. If not set, the return value is not disposed automatically.
OnIsChildSelectable
Handler for https://developer.android.com/reference/android/widget/ExpandableListAdapter.html#isChildSelectable(int,int)
public Func<int, int, bool> OnIsChildSelectable { get; set; }
Property Value
Remarks
Assign a delegate to handle the event without subclassing. If both this handler and a virtual method override are present, the delegate takes precedence. Set to null to delegate to the virtual method.
OnIsChildSelectableDispose
Optional handler invoked after the event handler returns, to dispose the JVM object returned by this event.
public Action<bool> OnIsChildSelectableDispose { get; set; }
Property Value
Remarks
Set OnIsChildSelectableDispose when the event handler returns a JVM-backed object that is no longer needed after the call. The handler receives the return value and is responsible for calling Dispose() on it, releasing the underlying JVM global reference immediately instead of waiting for the .NET garbage collector to finalize it. If not set, the return value is not disposed automatically.
OnIsEmpty
Handler for https://developer.android.com/reference/android/widget/ExpandableListAdapter.html#isEmpty()
public Func<bool> OnIsEmpty { get; set; }
Property Value
Remarks
Assign a delegate to handle the event without subclassing. If both this handler and a virtual method override are present, the delegate takes precedence. Set to null to delegate to the virtual method.
OnIsEmptyDispose
Optional handler invoked after the event handler returns, to dispose the JVM object returned by this event.
public Action<bool> OnIsEmptyDispose { get; set; }
Property Value
Remarks
Set OnIsEmptyDispose when the event handler returns a JVM-backed object that is no longer needed after the call. The handler receives the return value and is responsible for calling Dispose() on it, releasing the underlying JVM global reference immediately instead of waiting for the .NET garbage collector to finalize it. If not set, the return value is not disposed automatically.
OnOnGroupCollapsed
Handler for https://developer.android.com/reference/android/widget/ExpandableListAdapter.html#onGroupCollapsed(int)
public Action<int> OnOnGroupCollapsed { get; set; }
Property Value
Remarks
Assign a delegate to handle the event without subclassing. If both this handler and a virtual method override are present, the delegate takes precedence. Set to null to delegate to the virtual method.
OnOnGroupExpanded
Handler for https://developer.android.com/reference/android/widget/ExpandableListAdapter.html#onGroupExpanded(int)
public Action<int> OnOnGroupExpanded { get; set; }
Property Value
Remarks
Assign a delegate to handle the event without subclassing. If both this handler and a virtual method override are present, the delegate takes precedence. Set to null to delegate to the virtual method.
OnRegisterDataSetObserver
public Action<DataSetObserver> OnRegisterDataSetObserver { get; set; }
Property Value
Remarks
Assign a delegate to handle the event without subclassing. If both this handler and a virtual method override are present, the delegate takes precedence. Set to null to delegate to the virtual method.
OnUnregisterDataSetObserver
public Action<DataSetObserver> OnUnregisterDataSetObserver { get; set; }
Property Value
Remarks
Assign a delegate to handle the event without subclassing. If both this handler and a virtual method override are present, the delegate takes precedence. Set to null to delegate to the virtual method.
Methods
AreAllItemsEnabled()
public virtual bool AreAllItemsEnabled()
Returns
GetChild(int, int)
public virtual object GetChild(int arg0, int arg1)
Parameters
Returns
GetChildId(int, int)
public virtual long GetChildId(int arg0, int arg1)
Parameters
Returns
GetChildView(int, int, bool, View, ViewGroup)
public virtual View GetChildView(int arg0, int arg1, bool arg2, View arg3, ViewGroup arg4)
Parameters
Returns
GetChildrenCount(int)
public virtual int GetChildrenCount(int arg0)
Parameters
Returns
GetCombinedChildId(long, long)
public virtual long GetCombinedChildId(long arg0, long arg1)
Parameters
Returns
GetCombinedGroupId(long)
public virtual long GetCombinedGroupId(long arg0)
Parameters
Returns
GetGroup(int)
public virtual object GetGroup(int arg0)
Parameters
Returns
GetGroupCount()
public virtual int GetGroupCount()
Returns
GetGroupId(int)
public virtual long GetGroupId(int arg0)
Parameters
Returns
GetGroupView(int, bool, View, ViewGroup)
public virtual View GetGroupView(int arg0, bool arg1, View arg2, ViewGroup arg3)
Parameters
Returns
HasStableIds()
public virtual bool HasStableIds()
Returns
InitializeHandlers(Type)
Handlers initializer for ExpandableListAdapter
protected virtual void InitializeHandlers(Type listenerRuntimeType)
Parameters
listenerRuntimeTypeType
IsChildSelectable(int, int)
public virtual bool IsChildSelectable(int arg0, int arg1)
Parameters
Returns
IsEmpty()
public virtual bool IsEmpty()
Returns
ListenerShallManageEvent(int)
Invoked from the JVMBridgeListener on each received event to notify the user which can decide to abort the execution for the specific event returning false
protected override bool ListenerShallManageEvent(int eventIndex)
Parameters
eventIndexintThe index of the event triggered as returned from AddEventHandler(string, EventHandler) or AddEventHandler<TDataClass>(string, EventHandler<CLRListenerEventArgs<TDataClass>>)
Returns
Remarks
By default every event continues the execution and reads the data from JVM; this implies an extra cost which can be limited using ListenerShallManageEvent(int) or the ListenerShallManageEventIndex/ListenerShallManageEventName handlers. Returning false the control is immediately returned to the JVM, anyway the user has received the notification. It can be useful in scenarios where the user is interested in few events and the other are simply discarded to optimize the execution speed. By default, this function invokes ListenerShallManageEventIndex, then try ListenerShallManageEventName if they are set or return true
ListenerShallManageEventHandlers(int)
protected virtual bool ListenerShallManageEventHandlers(int eventIndex)
Parameters
eventIndexint
Returns
OnGroupCollapsed(int)
public virtual void OnGroupCollapsed(int arg0)
Parameters
OnGroupExpanded(int)
public virtual void OnGroupExpanded(int arg0)
Parameters
RegisterDataSetObserver(DataSetObserver)
public virtual void RegisterDataSetObserver(DataSetObserver arg0)
Parameters
UnregisterDataSetObserver(DataSetObserver)
public virtual void UnregisterDataSetObserver(DataSetObserver arg0)