Class: ModelRow

Oracle® Fusion Middleware Oracle JavaScript Extension Toolkit (JET)
12c (12.1.4)

E54107-01

QuickNav

oj. ModelRow

Object representing name/value pairs for a row of data

Constructor

new ModelRow(model, options)

Parameters:
Name Type Argument Description
model oj.Model oj.Model object
options Object <optional>
rowSet: rowSet for this row
Source:

Fields

attributes :Object

Attribute/value pairs held by the Row.
Source:

id :String

The Row's unique ID.
Source:

idAttribute :String

The name of the row property to be used as the unique ID. See property id. This defaults to a value of "id".
Source:

Methods

clone()

Source:

get(property) → {Object}

Returns the value of the property from the Row.
Parameters:
Name Type Description
property string Property to get from row
Source:
Returns:
value of property
Type
Object

getModel() → {oj.Model}

Return the oj.Model object which was wrapped
Source:
Returns:
oj.Model object
Type
oj.Model

keys() → {Array}

Source:
Returns:
array of all the Row's attributes
Type
Array

pairs() → {Object}

Source:
Returns:
returns the Row's attribute/value pairs as an array
Type
Object

set(property, value, options) → {Object||boolean}

Set the value(s) of one or more attributes of the row
Parameters:
Name Type Argument Description
property string | | Object Property attribute name to set, or an Object containing attribute/value pairs
value Object <optional>
Value for property if property is not an Object containing attribute/value pairs
options Object <optional>
Options may be passed in
Source:
Returns:
the row itself, false if failed
Type
Object | | boolean

values() → {Array}

Source:
Returns:
array of all the Row's attributes values
Type
Array