SparkseePython  6.0.2
Public Member Functions | List of all members
sparksee.ValueArray Class Reference

ValueArray class. More...

Public Member Functions

def set (self, index, value)
 Set a Value to a specific array position. More...
 
def get_integer (self)
 Get all the values from this int array. More...
 
def get_long (self)
 Get all the values from this long array. More...
 
def set_timestamp (self, values)
 Set all the values of this timestamp array. More...
 
def set_oid (self, values)
 Set all the values of this oid array. More...
 
def get_oid (self)
 Get all the values from this oid array. More...
 
def get (self, index, value)
 Get a Value from the array. More...
 
def get_timestamp (self)
 Get all the values from this timestamp array. More...
 
def get_double_range (self, index, size)
 Get a subset of the values from this double array. More...
 
def get_integer_range (self, index, size)
 Get a subset of the values from this integer array. More...
 
def get_boolean (self)
 Get all the values from this bool array. More...
 
def set_boolean (self, values)
 Set all the values of this bool array. More...
 
def set_double_range (self, index, values)
 Set a subset of the values from this double array. More...
 
def size (self)
 Returns the array size.
 
def get_long_range (self, index, size)
 Get a subset of the values from this long array. More...
 
def set_timestamp_range (self, index, values)
 Set a subset of the values from this timestamp array. More...
 
def make_null (self)
 Sets the attribute array to Null. More...
 
def set_integer_range (self, index, values)
 Set a subset of the values from this integer array. More...
 
def get_oid_range (self, index, size)
 Get a subset of the values from this oid array. More...
 
def set_boolean_range (self, index, values)
 Set a subset of the values from this boolean array. More...
 
def set_oid_range (self, index, values)
 Set a subset of the values from this oid array. More...
 
def get_double (self)
 Get all the values from this double array. More...
 
def set_long (self, values)
 Set all the values of this long array. More...
 
def set_double (self, values)
 Set all the values of this double array. More...
 
def set_integer (self, values)
 Set all the values of this int array. More...
 
def set_long_range (self, index, values)
 Set a subset of the values from this long array. More...
 
def set (self, value)
 Set a Value to the whole array. More...
 
def get_boolean_range (self, index, size)
 Get a subset of the values from this boolean array. More...
 
def get_timestamp_range (self, index, size)
 Get a subset of the values from this timestamp array. More...
 

Detailed Description

ValueArray class.

It allows for getting and setting ValueArray attribute values.

It is very important to close the ValueArray once no more get or set operations will be performed.

Creation of a new ValueArray: (i) Set all the ValueArray elements using Graph::SetAttributeArray (ii) perform as many get/set operations as you need to the ValueArray instance. Lastly, (iii) Close the ValueArray

Use of an existing ValueArray: (i) Get a ValueArray instance using Graph::GetAttributeArray (ii) perform as many get/set operations as you need to the ValueArray instance. Lastly, (iii) Close the ValueArray

Check out the 'Attributes and values' section in the SPARKSEE User Manual for more details on this.

Author
Sparsity Technologies http://www.sparsity-technologies.com

Member Function Documentation

def sparksee.ValueArray.get (   self,
  index,
  value 
)

Get a Value from the array.

AppErrorIf the ValueArray is not available

Parameters
index[in] Position of the element to get [0..N-1]
value[out] Value to get the array element
Exceptions
ValueErrorIf the index is out of range or the Value not valid
RuntimeErrornull
def sparksee.ValueArray.get_boolean (   self)

Get all the values from this bool array.

UnsupportedOperationErrorIf array DataType is not bool

Returns
All the array values
Exceptions
RuntimeErrorIf the ValueArray is not available
RuntimeErrornull
def sparksee.ValueArray.get_boolean_range (   self,
  index,
  size 
)

Get a subset of the values from this boolean array.

Returns all the requested values

Parameters
index[in] Position of the first element to get [0..N-1]
size[in] Number of elements to get [1..N]
def sparksee.ValueArray.get_double (   self)

Get all the values from this double array.

UnsupportedOperationErrorIf array DataType is not Double

Returns
All the array values
Exceptions
RuntimeErrorIf the ValueArray is not available
RuntimeErrornull
def sparksee.ValueArray.get_double_range (   self,
  index,
  size 
)

Get a subset of the values from this double array.

Returns all the requested values

Parameters
index[in] Position of the first element to get [0..N-1]
size[in] Number of elements to get [1..N]
def sparksee.ValueArray.get_integer (   self)

Get all the values from this int array.

UnsupportedOperationErrorIf array DataType is not int

Returns
All the array values
Exceptions
RuntimeErrorIf the ValueArray is not available
RuntimeErrornull
def sparksee.ValueArray.get_integer_range (   self,
  index,
  size 
)

Get a subset of the values from this integer array.

Returns all the requested values

Parameters
index[in] Position of the first element to get [0..N-1]
size[in] Number of elements to get [1..N]
def sparksee.ValueArray.get_long (   self)

Get all the values from this long array.

UnsupportedOperationErrorIf array DataType is not long

Returns
All the array values
Exceptions
RuntimeErrorIf the ValueArray is not available
RuntimeErrornull
def sparksee.ValueArray.get_long_range (   self,
  index,
  size 
)

Get a subset of the values from this long array.

Returns all the requested values

Parameters
index[in] Position of the first element to get [0..N-1]
size[in] Number of elements to get [1..N]
def sparksee.ValueArray.get_oid (   self)

Get all the values from this oid array.

UnsupportedOperationErrorIf array DataType is not oid

Returns
All the array values
Exceptions
RuntimeErrorIf the ValueArray is not available
RuntimeErrornull
def sparksee.ValueArray.get_oid_range (   self,
  index,
  size 
)

Get a subset of the values from this oid array.

Returns all the requested values

Parameters
index[in] Position of the first element to get [0..N-1]
size[in] Number of elements to get [1..N]
def sparksee.ValueArray.get_timestamp (   self)

Get all the values from this timestamp array.

UnsupportedOperationErrorIf array DataType is not timestamp

Returns
All the array values
Exceptions
RuntimeErrorIf the ValueArray is not available
RuntimeErrornull
def sparksee.ValueArray.get_timestamp_range (   self,
  index,
  size 
)

Get a subset of the values from this timestamp array.

Returns all the requested values

Parameters
index[in] Position of the first element to get [0..N-1]
size[in] Number of elements to get [1..N]
def sparksee.ValueArray.make_null (   self)

Sets the attribute array to Null.

The ValueArray can not be used after this call.

Exceptions
RuntimeErrornull
def sparksee.ValueArray.set (   self,
  index,
  value 
)

Set a Value to a specific array position.

AppErrorIf the ValueArray is not available

Parameters
index[in] Position of the element to set [0..N-1]
value[in] Value to set in the array element
Exceptions
ValueErrorIf the index is out of range or the Value not valid
RuntimeErrornull

Referenced by sparksee.ValueArray.set().

def sparksee.ValueArray.set (   self,
  value 
)

Set a Value to the whole array.

AppErrorIf the ValueArray is not available

Parameters
value[in] Value to set in all the array elements
Exceptions
ValueErrorIf the Value is not valid
RuntimeErrornull

References sparksee.ValueArray.set().

def sparksee.ValueArray.set_boolean (   self,
  values 
)

Set all the values of this bool array.

AppErrorIf the ValueArray is not available

Parameters
values[in] All the values to set
Exceptions
RuntimeErrornull
RuntimeErrorIf array DataType is not bool
def sparksee.ValueArray.set_boolean_range (   self,
  index,
  values 
)

Set a subset of the values from this boolean array.

Parameters
index[in] Position of the first element to get [0..N-1]
values[in] All the values to set
def sparksee.ValueArray.set_double (   self,
  values 
)

Set all the values of this double array.

AppErrorIf the ValueArray is not available

Parameters
values[in] All the values to set
Exceptions
RuntimeErrornull
RuntimeErrorIf array DataType is not Double
def sparksee.ValueArray.set_double_range (   self,
  index,
  values 
)

Set a subset of the values from this double array.

Parameters
index[in] Position of the first element to get [0..N-1]
values[in] All the values to set
def sparksee.ValueArray.set_integer (   self,
  values 
)

Set all the values of this int array.

AppErrorIf the ValueArray is not available

Parameters
values[in] All the values to set
Exceptions
RuntimeErrornull
RuntimeErrorIf array DataType is not int
def sparksee.ValueArray.set_integer_range (   self,
  index,
  values 
)

Set a subset of the values from this integer array.

Parameters
index[in] Position of the first element to get [0..N-1]
values[in] All the values to set
def sparksee.ValueArray.set_long (   self,
  values 
)

Set all the values of this long array.

AppErrorIf the ValueArray is not available

Parameters
values[in] All the values to set
Exceptions
RuntimeErrornull
RuntimeErrorIf array DataType is not long
def sparksee.ValueArray.set_long_range (   self,
  index,
  values 
)

Set a subset of the values from this long array.

Parameters
index[in] Position of the first element to get [0..N-1]
values[in] All the values to set
def sparksee.ValueArray.set_oid (   self,
  values 
)

Set all the values of this oid array.

AppErrorIf the ValueArray is not available

Parameters
values[in] All the values to set
Exceptions
RuntimeErrornull
RuntimeErrorIf array DataType is not oid
def sparksee.ValueArray.set_oid_range (   self,
  index,
  values 
)

Set a subset of the values from this oid array.

Parameters
index[in] Position of the first element to get [0..N-1]
values[in] All the values to set
def sparksee.ValueArray.set_timestamp (   self,
  values 
)

Set all the values of this timestamp array.

AppErrorIf the ValueArray is not available

Parameters
values[in] All the values to set
Exceptions
RuntimeErrornull
RuntimeErrorIf array DataType is not timestamp
def sparksee.ValueArray.set_timestamp_range (   self,
  index,
  values 
)

Set a subset of the values from this timestamp array.

Parameters
index[in] Position of the first element to get [0..N-1]
values[in] All the values to set