ShinobiControls Xamarin Bindings Documentation

ShinobiEssentials : Shinobi.Essentials Namespace

SEssentialsAccordion Class

SEssentialsAccordion (or simply, an accordion) is a means for displaying lists of information, where some of the information is shown, and some of the information is hidden.

Syntax

[Foundation.Register("SEssentialsAccordion", true)]
public class SEssentialsAccordion : UIKit.UIView

Remarks

An accordion is made up of zero or more sections Shinobi.Essentials.SEssentialsAccordionSection. You can open or close sections to display or hide the information they contain.

Each section is implemented using the SEssentialsAccordionSection class. A section has a header view and a content view. You can either define a custom view for the header, or you can simply define a title for the section and use the default header view. You supply the content to be displayed in each section.

Each section header contains an instance of Shinobi.Essentials.SEssentialsAccordionSectionHeaderStyle. This style object manages the appearance of the section.

An accordion must have an object that acts as a DataSource. The DataSource must adopt the Shinobi.Essentials.SEssentialsAccordionDataSource protocol. The DataSource provides the content for each of the sections when they are displayed in "open" mode.

The content supplied by the DataSource is only retained by the Accordion while the content is visible on screen, and will be released when scrolled off screen or the section is closed. It is up to the class adopting the Shinobi.Essentials.SEssentialsAccordionDataSource protocol to retain content so it can be requested at any time.

An accordion can optionally have an object that acts as a delegate. The delegate must adopt the Shinobi.Essentials.SEssentialsAccordionDelegate protocol. The delegate is notified when sections are opened, closed, added, deleted or moved.

There are currently two types of accordion:

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

Members

See Also: Inherited members from UIKit.UIView.

Public Constructors

Default constructor.
Initialize view with the specified frame rectangle.
A constructor that initializes the object from the data stored in the unarchiver object.

Protected Constructors

Constructor to call on derived classes to skip initialization and merely allocate the object.
A constructor used when creating managed representations of unmanaged objects.

Public Properties

AccordionType SEssentialsAccordionType . The type of accordion.
[read-only]
override
ClassHandle IntPtr . The handle for this class.
CornerRadius nfloat . The default radius which is given to the corners of the accordion.
DataSource SEssentialsAccordionDataSource . The DataSource provides the content for each of the accordion sections
Delegate SEssentialsAccordionDelegate . The delegate is notified when sections are opened, closed, deleted or removed.
Editable bool . Whether or not you can swipe to delete a section within the accordion.
Editing bool . Whether or not the 'move' and 'delete' accessories are visible, allowing movement and deletion.
FloatingHeader bool . Specifies whether the topmost section should slide under its header until pushed off screen.
LazyLoading bool . Controls if the accordion populates section content on loading the section, or on opening the section.
ScrollBounceEnabled bool . Specifies whether the accordion bounces when it reaches the limit of its scrolling.
[read-only]
Sections SEssentialsAccordionSection[]. A shallow copy of the sections which the accordion control contains.
WeakDataSource Foundation.NSObject . A weakly typed data source.
WeakDelegate Foundation.NSObject . A weakly typed delegate.

Public Methods

AddSection (SEssentialsAccordionSection)
Add a single section to the accordion.
AddSections (SEssentialsAccordionSection[])
Add an array of sections to the accordion.
ApplyTheme (SEssentialsTheme)
Updates the style of the accordion using the specified theme.
InsertSection (SEssentialsAccordionSection, nint)
Adds a single section to the accordion at the specified index.
MoveSection (nint, nint)
Moves a section within the accordion
ReloadAllSections ()
Reloads the contents of all sections, by fetching new content from the DataSource.
ReloadSection (SEssentialsAccordionSection)
Reloads the content of a section, by fetching the new content from the DataSource.
RemoveAllSections ()
Removes all sections from the accordion.
RemoveSection (SEssentialsAccordionSection)
Removes the section from the accordion.
RemoveSection (nint)
Removes the section at the specified index from the accordion.

Protected Methods

override
Dispose (bool)
Releases unmanaged resources.

Member Details

SEssentialsAccordion Constructor

Default constructor.

Syntax

[Foundation.Export("init")]
[System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Advanced)]
public SEssentialsAccordion ()

Remarks

Documentation for this section has not yet been entered.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

SEssentialsAccordion Constructor

Initialize view with the specified frame rectangle.

Syntax

public SEssentialsAccordion (CoreGraphics.CGRect frame)

Parameters

frame
Frame rectangle defining views extent

Remarks

Documentation for this section has not yet been entered.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

SEssentialsAccordion Constructor

A constructor that initializes the object from the data stored in the unarchiver object.

Syntax

[Foundation.Export("initWithCoder:")]
[System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Advanced)]
public SEssentialsAccordion (Foundation.NSCoder coder)

Parameters

coder
The unarchiver object

Remarks

This constructor is provided to allow the class to be initialized from an unarchiver (for example, during NIB deserialization).

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

SEssentialsAccordion Constructor

Constructor to call on derived classes to skip initialization and merely allocate the object.

Syntax

[System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Advanced)]
protected SEssentialsAccordion (Foundation.NSObjectFlag t)

Parameters

t
Unused sentinel value

Remarks

You should not invoke this method directly.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

SEssentialsAccordion Constructor

A constructor used when creating managed representations of unmanaged objects.

Syntax

[System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Advanced)]
protected SEssentialsAccordion (IntPtr handle)

Parameters

handle
Handle of the unmanaged object

Remarks

You should not invoke this method directly.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

AccordionType Property

The type of accordion.

Syntax

[get: Foundation.Export("type", ObjCRuntime.ArgumentSemantic.UnsafeUnretained)]
[set: Foundation.Export("setType:", ObjCRuntime.ArgumentSemantic.UnsafeUnretained)]
public virtual SEssentialsAccordionType AccordionType { get; set; }

Value

Documentation for this section has not yet been entered.

Remarks

Default to SEssentialsAccordionType.Flexible.

A fixed accordion only shows the contents of one section at a time. When a section is opened, the previously open section is closed. The accordion has a fixed size, and does not scroll.

A flexible accordion allows multiple sections to be open at the same time. Its contents can be bigger than its frame. In this case, it will scroll up and down.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

AddSection Method

Add a single section to the accordion.

Syntax

[Foundation.Export("addSection:")]
public virtual void AddSection (SEssentialsAccordionSection section)

Parameters

section
The SEssentialsAccordionSection to be added

Remarks

This will appear at the end (bottom) of the accordion

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

AddSections Method

Add an array of sections to the accordion.

Syntax

[Foundation.Export("addSectionsFromArray:")]
public virtual void AddSections (SEssentialsAccordionSection[] sections)

Parameters

sections
An array of SEssentialsAccordionSection to be added

Remarks

Documentation for this section has not yet been entered.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

ApplyTheme Method

Updates the style of the accordion using the specified theme.

Syntax

[Foundation.Export("applyTheme:")]
public virtual void ApplyTheme (SEssentialsTheme theme)

Parameters

theme
Documentation for this section has not yet been entered.

Remarks

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

ClassHandle Property

The handle for this class.

Syntax

public override IntPtr ClassHandle { get; }

Value

Documentation for this section has not yet been entered.

Remarks

Documentation for this section has not yet been entered.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

CornerRadius Property

The default radius which is given to the corners of the accordion.

Syntax

[get: Foundation.Export("cornerRadius", ObjCRuntime.ArgumentSemantic.UnsafeUnretained)]
[set: Foundation.Export("setCornerRadius:", ObjCRuntime.ArgumentSemantic.UnsafeUnretained)]
public virtual nfloat CornerRadius { get; set; }

Value

Documentation for this section has not yet been entered.

Remarks

Defaults to 5

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

DataSource Property

The DataSource provides the content for each of the accordion sections

Syntax

public SEssentialsAccordionDataSource DataSource { get; set; }

Value

Documentation for this section has not yet been entered.

Remarks

Important. It is your responsibility to hold a reference to your data source, to avoid it being garbage collected. This property does not do this for you (unlike most properties in the API) to match the behavior of the native code.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

Delegate Property

The delegate is notified when sections are opened, closed, deleted or removed.

Syntax

public SEssentialsAccordionDelegate Delegate { get; set; }

Value

Documentation for this section has not yet been entered.

Remarks

Important. It is your responsibility to hold a reference to your delegate (if it is a separate object), to avoid it being garbage collected. This property does not do this for you (unlike most properties in the API) to match the behavior of the native code.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

Dispose Method

Releases unmanaged resources.

Syntax

protected override void Dispose (bool disposing)

Parameters

disposing
True if called by Dispose, false if called from a finalizer

Remarks

Documentation for this section has not yet been entered.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

Editable Property

Whether or not you can swipe to delete a section within the accordion.

Syntax

[get: Foundation.Export("editable", ObjCRuntime.ArgumentSemantic.UnsafeUnretained)]
[set: Foundation.Export("setEditable:", ObjCRuntime.ArgumentSemantic.UnsafeUnretained)]
public virtual bool Editable { get; set; }

Value

Documentation for this section has not yet been entered.

Remarks

This defaults to true.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

Editing Property

Whether or not the 'move' and 'delete' accessories are visible, allowing movement and deletion.

Syntax

[get: Foundation.Export("editing", ObjCRuntime.ArgumentSemantic.UnsafeUnretained)]
[set: Foundation.Export("setEditing:", ObjCRuntime.ArgumentSemantic.UnsafeUnretained)]
public virtual bool Editing { get; set; }

Value

Documentation for this section has not yet been entered.

Remarks

This defaults to false.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

FloatingHeader Property

Specifies whether the topmost section should slide under its header until pushed off screen.

Syntax

[get: Foundation.Export("floatingHeader", ObjCRuntime.ArgumentSemantic.UnsafeUnretained)]
[set: Foundation.Export("setFloatingHeader:", ObjCRuntime.ArgumentSemantic.UnsafeUnretained)]
public virtual bool FloatingHeader { get; set; }

Value

Documentation for this section has not yet been entered.

Remarks

This defaults to true.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

InsertSection Method

Adds a single section to the accordion at the specified index.

Syntax

[Foundation.Export("insertSection:atIndex:")]
public virtual void InsertSection (SEssentialsAccordionSection section, nint index)

Parameters

section
The SEssentialsAccordionSection to be added
index
The index at which to add the section

Remarks

This will push the sections below (i.e. with this index or higher) down the accordion

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

LazyLoading Property

Controls if the accordion populates section content on loading the section, or on opening the section.

Syntax

[get: Foundation.Export("lazyLoading", ObjCRuntime.ArgumentSemantic.UnsafeUnretained)]
[set: Foundation.Export("setLazyLoading:", ObjCRuntime.ArgumentSemantic.UnsafeUnretained)]
public virtual bool LazyLoading { get; set; }

Value

Documentation for this section has not yet been entered.

Remarks

Defaults to false. If true, load content only when section is opened. If false, eagerly load content when section is created. Cannot be set while the DataSource is set, and will throw an exception if this is attempted. Instead, the DataSource should be set to null before changing this value.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

MoveSection Method

Moves a section within the accordion

Syntax

[Foundation.Export("moveSectionFromIndex:toIndex:")]
public virtual void MoveSection (nint fromIndex, nint toIndex)

Parameters

fromIndex
The index where the section can currently be found.
toIndex
The index where the section should be moved to.

Remarks

Documentation for this section has not yet been entered.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

ReloadAllSections Method

Reloads the contents of all sections, by fetching new content from the DataSource.

Syntax

[Foundation.Export("reloadAllSections")]
public virtual void ReloadAllSections ()

Remarks

Documentation for this section has not yet been entered.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

ReloadSection Method

Reloads the content of a section, by fetching the new content from the DataSource.

Syntax

[Foundation.Export("reloadSection:")]
public virtual void ReloadSection (SEssentialsAccordionSection section)

Parameters

section
The section to reload.

Remarks

Documentation for this section has not yet been entered.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

RemoveAllSections Method

Removes all sections from the accordion.

Syntax

[Foundation.Export("removeAllSections")]
public virtual void RemoveAllSections ()

Remarks

This will reset the content and leave a completely empty accordion.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

RemoveSection Method

Removes the section from the accordion.

Syntax

[Foundation.Export("removeSection:")]
public virtual void RemoveSection (SEssentialsAccordionSection section)

Parameters

section
The SEssentialsAccordionSection to be removed

Remarks

The removal will be animated.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

RemoveSection Method

Removes the section at the specified index from the accordion.

Syntax

[Foundation.Export("removeSectionAtIndex:")]
public virtual void RemoveSection (nint index)

Parameters

index
The index of the section to be removed

Remarks

Documentation for this section has not yet been entered.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

ScrollBounceEnabled Property

Specifies whether the accordion bounces when it reaches the limit of its scrolling.

Syntax

[get: Foundation.Export("scrollBounceEnabled", ObjCRuntime.ArgumentSemantic.UnsafeUnretained)]
[set: Foundation.Export("setScrollBounceEnabled:", ObjCRuntime.ArgumentSemantic.UnsafeUnretained)]
public virtual bool ScrollBounceEnabled { get; set; }

Value

Documentation for this section has not yet been entered.

Remarks

Defaults to true

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

Sections Property

A shallow copy of the sections which the accordion control contains.

Syntax

[get: Foundation.Export("sections", ObjCRuntime.ArgumentSemantic.Strong)]
public virtual SEssentialsAccordionSection[] Sections { get; }

Value

Documentation for this section has not yet been entered.

Remarks

Documentation for this section has not yet been entered.

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

WeakDataSource Property

A weakly typed data source.

Syntax

[get: Foundation.Export("dataSource", ObjCRuntime.ArgumentSemantic.UnsafeUnretained)]
[set: Foundation.Export("setDataSource:", ObjCRuntime.ArgumentSemantic.UnsafeUnretained)]
public virtual Foundation.NSObject WeakDataSource { get; set; }

Value

Documentation for this section has not yet been entered.

Remarks

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4

WeakDelegate Property

A weakly typed delegate.

Syntax

[get: Foundation.Export("delegate", ObjCRuntime.ArgumentSemantic.UnsafeUnretained)]
[set: Foundation.Export("setDelegate:", ObjCRuntime.ArgumentSemantic.UnsafeUnretained)]
public virtual Foundation.NSObject WeakDelegate { get; set; }

Value

Documentation for this section has not yet been entered.

Remarks

Requirements

Namespace: Shinobi.Essentials
Assembly: ShinobiEssentials (in ShinobiEssentials.dll)
Assembly Versions: 2.8.0.4