DomainObjectHandler<T>
Defined in: js-api/src/domains-ui.ts:108
The per-table ObjectHandler for domain rows: reflective (it takes columns, labels, choices and access from the runtime registry, so it works on ANY table without codegen) and delegating (every render member falls through to the platform's Dart meta for that table).
class IssueHandler extends DG.DomainObjectHandler {
constructor() { super('grit.issue'); }
renderCard(x) { return ui.divText(`#${x.values.number} ${x.values.title}`); }
}
DG.ObjectHandler.register(new IssueHandler());
Dispatch precedence (unchanged by this class):
- Rendering — the last-registered JS handler applicable to the object
wins
ObjectHandler.forEntity; the platform's per-table meta demotes itself behind it regardless of registration order. - Overriding nothing is never a regression — an override-nothing subclass renders exactly like the platform, because the defaults below delegate to the same Dart meta the platform would have used.
- Platform commands stay — Edit/Delete/Share/Watch/History context-menu
commands remain the platform's, permission-gated; a JS handler ADDS actions
(
registerParamFunc), it never replaces those. - Grid cells keyed by semType keep their registered cell renderer.
Extends
Type Parameters
| Type Parameter | Default type |
|---|---|
T | DomainRow |
Constructors
Constructor
new DomainObjectHandler<
T>(table):DomainObjectHandler<T>
Defined in: js-api/src/domains-ui.ts:117
[table] addresses the domain table as '<schema>.<table>' (also the row
entity type and semType); a malformed address throws immediately.
Parameters
| Parameter | Type |
|---|---|
table | string |
Returns
DomainObjectHandler<T>
Overrides
Properties
| Property | Modifier | Type | Description | Inherited from | Defined in |
|---|---|---|---|---|---|
dart | public | any | - | ObjectHandler.dart | js-api/ui.ts:1637 |
schemaName | readonly | string | Domain schema name of table. | - | js-api/src/domains-ui.ts:110 |
table | readonly | string | - | - | js-api/src/domains-ui.ts:117 |
tableName | readonly | string | Table name of table within schemaName. | - | js-api/src/domains-ui.ts:112 |
Accessors
client
Get Signature
get
protectedclient():DomainTableClient
Defined in: js-api/src/domains-ui.ts:192
Client for this table (grok.dapi.domains.table(this.table)).
Returns
dartMeta
Get Signature
get
protecteddartMeta():EntityMetaDartProxy|null
Defined in: js-api/src/domains-ui.ts:178
The platform's per-table meta, as an EntityMetaDartProxy — what the default render members delegate to. Never a JS handler (delegating into one would recurse); null only for a table whose address cannot be parsed. Only a real hit is cached: a miss is re-resolved on the next use, so a handler constructed before the platform metas exist starts delegating as soon as they do.
Returns
EntityMetaDartProxy | null
helpUrl
Get Signature
get helpUrl():
string|null
Defined in: js-api/ui.ts:1644
URL of help page for the object that this meta handles.
Returns
string | null
Inherited from
markupRegexp
Get Signature
get markupRegexp():
string|null
Defined in: js-api/ui.ts:1787
Creates a regexp for detecting markup descriptions of an object
Returns
string | null
Inherited from
name
Get Signature
get name():
string
Defined in: js-api/ui.ts:1648
Returns
string
Inherited from
regexpExample
Get Signature
get regexpExample(): {
example:string;nonVariablePart:string;regexpMarkup:string; } |null
Defined in: js-api/ui.ts:1657
Will be used by search providers to get suggestions (like chembl which has regexp matcher) For something like CHEMBL object handler, it should return: regexpMarkup: 'CHEMBL[0-9]+', example: 'CHEMBL1234', nonVariablePart: 'CHEMBL'
Returns
{ example: string; nonVariablePart: string; regexpMarkup: string; } | null
Inherited from
type
Get Signature
get type():
string
Defined in: js-api/src/domains-ui.ts:124
Type of the object that this meta handles.
Returns
string