Model Index

Types By Namespace

cdo

def

pvc

pvc.data

pvc.options

pvc.options.axes

pvc.options.charts

pvc.options.ext

pvc.options.format

pvc.options.marks

pvc.options.panels

pvc.options.plots

pvc.options.varia

pvc.options.visualRoles

pvc.visual

Class pvc.data.Data


Extends Complex.

Class Summary
Constructor Attributes Constructor Name and Description
 
The Data class represents a data set.
Field Summary
Field Attributes Field Name and Description
 
Gets the atoms map of the complex value.
 
id
Gets the unique, sequential identifier of the complex value.
 
key
Gets the key of the complex.
 
Gets the label of the complex.
 
The owner data set of the complex value.
 
Gets the value of the complex.
DOM
 
The first child data set.
 
The last child data set.
 
The next sibling data set.
 
Gets the parent data set of this data set.
 
The previous sibling data set.
 
The root data set.
Method Summary
Method Attributes Method Name and Description
 
contains(datum)
Gets a value that indicates if a given datum is contained by this data set.
 
Gets the datum with the given key, if any, or `null`, if none.
 
Gets an array with the not-null, selected datums, in an unspecified order.
Datums
 
Gets the number of contained datums.
 
datums(querySpec, keyArgs)
Gets an enumerable for the datums of this data, possibly filtered according to a given query specification and datum states.
DOM
 
child(key)
Obtains a child data set given its key.
 
Obtains the number of children data sets.
 
Gets the index of this data set in relation to its sibling data sets.
 
Obtains an enumerable of the child data sets of this data set.
 
Obtains an enumerable of the leaf data sets of this data set.
Interactivity
 
Clears the selected state of all datums.
 
Replaces the currently selected datums with the given datums.
 
Gets the number of not-null, selected datums.
<static>  
pvc.data.Data.setSelected(datums, selected)
Sets the selected state of the given datums to a given state.
<static>  
pvc.data.Data.setVisible(datums, visible)
Sets the visible state of the given datums to a given state.
<static>  
pvc.data.Data.toggleSelected(datums, any)
Pseudo-toggles the selected state of the given datums.
<static>  
pvc.data.Data.toggleVisible(datums)
Pseudo-toggles the visible state of the given datums.
 
Gets the number of not-null, visible datums.
Class Detail
pvc.data.Data
The Data class represents a data set.

A data set contains a list of Datum, exposed in #datums.

When it is the result of a group by operation, it also contains a set of #atoms which are known to be shared by all of the contained Datum.

Field Detail
{object} atoms
Gets the atoms map of the complex value. The map's keys are dimension names and the values are the corresponding Atom.
Borrowed from:
Complex

{number} id
Gets the unique, sequential identifier of the complex value.
Borrowed from:
Complex

{string} key
Gets the key of the complex.

The key is a unique string representation of complex value and is used to index complexes in dictionaries.

For datums, if the complex type has any key dimensions, as per pvc.options.DimensionType#isKey, its key is composed by the keys of the atoms of the key dimensions. Otherwise, their key is the #id.

For data sets, the key is a combination of the Atom#keys of contained #atoms.

Borrowed from:
Complex

{any} label
Gets the label of the complex.

When a complex contains a single atom, its label is the label of that atom. Otherwise, the "label" of the complex is determined by combining the the Atom#labels of contained #atoms.

Borrowed from:
Complex

{pvc.data.Data} owner
The owner data set of the complex value. The owner data set is the root data set that holds the whole extent of datums.
Borrowed from:
Complex

{any} value
Gets the value of the complex.

When a complex contains a single atom, its value will be the typed value of that atom. Otherwise, the "value" of a complex is its #key.

Borrowed from:
Complex

{pvc.data.Data} firstChild
The first child data set.

This is is null for leaf data sets.


{pvc.data.Data} lastChild
The last child data set.

This is is null for leaf data sets.


{pvc.data.Data} nextSibling
The next sibling data set.

This is null for the last child data set.


{!pvc.data.Data} parent
Gets the parent data set of this data set.

This is null for root data sets.


{pvc.data.Data} previousSibling
The previous sibling data set.

This is null for the first child data set.


{!pvc.data.Data} root
The root data set.

The root data set has itself as the value of the root property.

Method Detail
{boolean} contains(datum)
Gets a value that indicates if a given datum is contained by this data set.
Arguments:
{!pvc.data.Datum} datum
The datum to test for containment.
Returns:
{boolean} true if the datum is contained in this data set, or false, otherwise.

{pvc.data.Datum} datumByKey(key)
Gets the datum with the given key, if any, or `null`, if none.
Arguments:
{string} key
The datum key.
Returns:
{pvc.data.Datum} A datum or `null`.

{pvc.data.Datum[]} selectedDatums()
Gets an array with the not-null, selected datums, in an unspecified order.
Returns:
{pvc.data.Datum[]} The selected datums.

{number} count()
Gets the number of contained datums.
Returns:
{number} The number of datums.

{!def.Query} datums(querySpec, keyArgs)
Gets an enumerable for the datums of this data, possibly filtered according to a given query specification and datum states.
Arguments:
{object} querySpec Optional
A query specification.

A structure with the following form:

// OR of datum filters
querySpec = [datumFilter1, datumFilter2, ...] | datumFilter;

// AND of dimension filters
datumFilter = {
     // OR of dimension values
     dimName1: [value1, value2, ...],
     dimName2: value1,
     ...
}

Values of a datum filter can also directly be atoms.

An example of a query specification:

querySpec = [
    // Datums whose series is 'Europe' or 'Australia',
    // and whose category is 2001 or 2002
    {series: ['Europe', 'Australia'], category: [2001, 2002]},

    // Union'ed with

    // Datums whose series is 'America'
    {series: 'America'},
];
{object} keyArgs Optional
Keyword arguments object.
{boolean} keyArgs.isNull Optional, Default: null
Only considers datums with the specified isNull attribute.
{boolean} keyArgs.visible Optional, Default: null
Only considers datums that have the specified visible state.
{boolean} keyArgs.selected Optional, Default: null
Only considers datums that have the specified selected state.
{function} keyArgs.where Optional
An arbitrary datum predicate.
Returns:
{!def.Query} A query object that enumerates the matching Datum objects.

{pvc.data.Data} child(key)
Obtains a child data set given its key.
Arguments:
{string} key
The key of the child data set.
Returns:
{pvc.data.Data} The child data set with the given key or null.

{number} childCount()
Obtains the number of children data sets.
Returns:
{number} The number of children data sets.

{number} childIndex()
Gets the index of this data set in relation to its sibling data sets.

This index is 0-based.

When the node is a root node, -1 is returned.

Returns:
{number} The child index.

{!def.Query} children()
Obtains an enumerable of the child data sets of this data set.
Returns:
{!def.Query} An enumerable of Data.

{!def.Query} leafs()
Obtains an enumerable of the leaf data sets of this data set.
Returns:
{!def.Query} An enumerable of Data.

{boolean} clearSelected()
Clears the selected state of all datums.
Returns:
{boolean} true if any datum changed its selected state; false, otherwise.

{boolean} replaceSelected(datums)
Replaces the currently selected datums with the given datums.
Arguments:
{!pvc.data.Datum[]|!def.Query} datums
The new datums to be selected.
Returns:
{boolean} true if any datum changed its selected state; false, otherwise.

{number} selectedCount()
Gets the number of not-null, selected datums.
Returns:
{number} The number of datums.
See:
pvc.data.Datum#isSelected

<static> {boolean} pvc.data.Data.setSelected(datums, selected)
Sets the selected state of the given datums to a given state.
Arguments:
{!pvc.data.Datum[]|!def.Query} datums
The datums to set.
{boolean} selected
The desired selected state.
Returns:
{boolean} true if any datum changed its selected state; false, otherwise.

<static> {boolean} pvc.data.Data.setVisible(datums, visible)
Sets the visible state of the given datums to a given state.
Arguments:
{!pvc.data.Datum[]|!def.Query} datums
The datums to set.
{boolean} visible
The desired visible state.
Returns:
{boolean} true if any datum changed its visible state; false, otherwise.

<static> {boolean} pvc.data.Data.toggleSelected(datums, any)
Pseudo-toggles the selected state of the given datums.

If all are selected, clears their selected state. Otherwise, selects them all.

If the `any` argument is true, the behavior changes to: if any is selected, clears their selected state. Otherwise, if none are selected, selects them all.

Arguments:
{!pvc.data.Datum[]|!def.Query} datums
The datums to toggle.
{boolean} any Optional, Default: false
If only some must be selected to consider the set currently selected or if all must be so.
Returns:
{boolean} true if any datum changed its selected state; false, otherwise.

<static> {boolean} pvc.data.Data.toggleVisible(datums)
Pseudo-toggles the visible state of the given datums.

If all are visible, hides them. Otherwise, shows them all.

Arguments:
{!pvc.data.Datum[]|!def.Query} datums
The datums to toggle.
Returns:
{boolean} true if any datum changed its visible state; false, otherwise.

{number} visibleCount()
Gets the number of not-null, visible datums.
Returns:
{number} The number of datums.
See:
pvc.data.Datum#isVisible

Documentation generated by JsDoc Toolkit 2.4.0 on Thu Dec 20 2018 15:47:40 GMT-0000 (WET)