Constructor
new Parameters(objopt, objopt, objopt)
Parameters:
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
obj |
string |
<optional> |
null | "columnName" |
obj |
object |
<optional> |
null | {'column1': 1, 'column2': 2} |
obj |
array |
<optional> |
null | ['column1', 'column2'] |
- Source:
Methods
getAssignString(glueopt) → {string}
Get assignment string to be used in SQL queries.
Parameters:
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
glue |
string |
<optional> |
", " |
- Source:
Returns:
"column1" = ?, "column2" = ?
- Type
- string
getColumnString() → {string}
Get column string to be used in SQL queries
- Source:
Returns:
"*" if no fields specified. Else '"column1", "column2"'
- Type
- string
getIndexableColumnNames() → {array}
Columns filtered by __eq should be indexed.
- Source:
Returns:
column names which are filtered with __eq
- Type
- array
getQuestionMarkString() → {string}
Create comma devided question mark string with same length as columns to filter
- Source:
Returns:
"?,?,?"
- Type
- string
normalalizeObj(obj, obj, obj) → {array|object}
Convert object to valid value
Parameters:
| Name | Type | Description |
|---|---|---|
obj |
string | "columnName" |
obj |
object | {'column1': 1, 'column2': 2} |
obj |
array | ['column1', 'column2'] |
- Source:
Returns:
-
if array or string is given
- Type
- array
-
if object or null || undefined is given
- Type
- object