Class: EntityMetaDartProxy
ui.EntityMetaDartProxy
Override the corresponding methods, and register an instance to let Datagrok know how to handle objects of the specified type.
isApplicable is used to associate an object with the handler. When handling an object x, the platform uses the first registered handler that claims that it is applicable to that object.
TODO: search, destructuring to properties
Example: https://public.datagrok.ai/js/samples/ui/handlers/handlers
Hierarchy
↳
EntityMetaDartProxy
Constructors
constructor
• new EntityMetaDartProxy(d
)
Parameters
Name | Type |
---|---|
d | any |
Overrides
Defined in
Properties
dart
• dart: any
Defined in
Accessors
name
• get
name(): string
Returns
string
Inherited from
ObjectHandler.name
Defined in
type
• get
type(): string
Type of the object that this meta handles.
Returns
string
Overrides
ObjectHandler.type
Defined in
Methods
getById
▸ getById(id
): Promise
<any
>
Parameters
Name | Type |
---|---|
id | string |
Returns
Promise
<any
>
Inherited from
Defined in
getCanvasRenderer
▸ getCanvasRenderer(): null
| CanvasRenderer
Returns
null
| CanvasRenderer
Inherited from
ObjectHandler.getCanvasRenderer
Defined in
getCaption
▸ getCaption(x
): string
String representation of the [item], by default item.toString().
Parameters
Name | Type | Description |
---|---|---|
x | any | item |
Returns
string
Overrides
Defined in
getGridCellRenderer
▸ getGridCellRenderer(): null
| GridCellRenderer
Returns
null
| GridCellRenderer
Inherited from
ObjectHandler.getGridCellRenderer
Defined in
init
▸ init(): void
Gets called once upon the registration of meta export class.
Returns
void
Inherited from
Defined in
isApplicable
▸ isApplicable(x
): boolean
Override this method to check whether this meta class should handle the specified object.
Parameters
Name | Type | Description |
---|---|---|
x | any | specified object. |
Returns
boolean
Overrides
Defined in
refresh
▸ refresh(x
): Promise
<any
>
Parameters
Name | Type |
---|---|
x | any |
Returns
Promise
<any
>
Inherited from
Defined in
registerParamFunc
▸ registerParamFunc(name
, run
): void
Registers a function that takes applicable objects as the only argument. It will be suggested to run in the context menu for that object, and also in the "Actions" pane on the context panel.
Example: https://public.datagrok.ai/js/samples/ui/docking/docking
Parameters
Name | Type | Description |
---|---|---|
name | string | function name |
run | (param : any ) => any | a function that takes exactly one parameter |
Returns
void
Inherited from
ObjectHandler.registerParamFunc
Defined in
renderCard
▸ renderCard(x
, context?
): HTMLDivElement
Renders card div for the item.
Parameters
Name | Type | Default value |
---|---|---|
x | any | undefined |
context | any | null |
Returns
HTMLDivElement
Overrides
Defined in
renderIcon
▸ renderIcon(x
, context?
): HTMLDivElement
Renders icon for the item.
Parameters
Name | Type | Default value |
---|---|---|
x | any | undefined |
context | any | null |
Returns
HTMLDivElement
Overrides
Defined in
renderMarkup
▸ renderMarkup(x
, context?
): HTMLDivElement
Renders markup for the item.
Parameters
Name | Type | Default value |
---|---|---|
x | any | undefined |
context | any | null |
Returns
HTMLDivElement
Overrides
Defined in
renderPreview
▸ renderPreview(x
, context?
): Promise
<View
>
Renders preview list for the item.
Parameters
Name | Type | Default value |
---|---|---|
x | any | undefined |
context | any | null |
Returns
Promise
<View
>
Inherited from
Defined in
renderProperties
▸ renderProperties(x
, context?
): HTMLDivElement
Renders properties list for the item.
Parameters
Name | Type | Default value |
---|---|---|
x | any | undefined |
context | any | null |
Returns
HTMLDivElement
Overrides
ObjectHandler.renderProperties
Defined in
renderTooltip
▸ renderTooltip(x
, context?
): HTMLDivElement
Renders tooltip for the item.
Parameters
Name | Type | Default value |
---|---|---|
x | any | undefined |
context | any | null |
Returns
HTMLDivElement
Overrides
Defined in
renderView
▸ renderView(x
, context?
): HTMLDivElement
Renders view for the item.
Parameters
Name | Type | Default value |
---|---|---|
x | any | undefined |
context | any | null |
Returns
HTMLDivElement
Overrides
Defined in
toString
▸ toString(): string
Returns
string
Inherited from
Defined in
forEntity
▸ Static
forEntity(object
, context?
): null
| ObjectHandler
Parameters
Name | Type | Default value |
---|---|---|
object | object | undefined |
context | null | object | null |
Returns
null
| ObjectHandler
Inherited from
Defined in
forSemType
▸ Static
forSemType(semType
): Promise
<ObjectHandler
[]>
Parameters
Name | Type |
---|---|
semType | string |
Returns
Promise
<ObjectHandler
[]>
Inherited from
Defined in
list
▸ Static
list(): ObjectHandler
[]
Returns
Inherited from
Defined in
onResolve
▸ Static
onResolve(observer
): Subscription
Parameters
Name | Type |
---|---|
observer | PartialObserver <ObjectHandlerResolutionArgs > |
Returns
Subscription
Inherited from
Defined in
register
▸ Static
register(meta
): void
Registers entity handler.
Parameters
Name | Type |
---|---|
meta | ObjectHandler |
Returns
void