Nextcloud PHP API (master)

IAPIWidget extends IWidget

interface IAPIWidget

Tags
since
22.0.0

Table of Contents

Methods

getIconClass()  : string
getId()  : string
getItems()  : array<string|int, WidgetItem>
getOrder()  : int
getTitle()  : string
getUrl()  : string|null
load()  : void
Execute widget bootstrap code like loading scripts and providing initial state

Methods

getIconClass()

public getIconClass() : string
Tags
since
20.0.0
Return values
string

css class that displays an icon next to the widget title

getId()

public getId() : string
Tags
since
20.0.0
Return values
string

Unique id that identifies the widget, e.g. the app id

getItems()

public getItems(string $userId[, string|null $since = null ][, int $limit = 7 ]) : array<string|int, WidgetItem>
Parameters
$userId : string
$since : string|null = null
$limit : int = 7
Tags
since
22.0.0
Return values
array<string|int, WidgetItem>

The widget items

getOrder()

public getOrder() : int
Tags
since
20.0.0
Return values
int

Initial order for widget sorting

getTitle()

public getTitle() : string
Tags
since
20.0.0
Return values
string

User facing title of the widget

getUrl()

public getUrl() : string|null
Tags
since
20.0.0
Return values
string|null

The absolute url to the apps own view

load()

Execute widget bootstrap code like loading scripts and providing initial state

public load() : void
Tags
since
20.0.0

        
On this page

Search results