org.das2.qds.TrimStrideWrapper

Wraps rank N qube dataset to present a dataset with the same rank that is a subset of wrapped dataset. Note this was used before trim() was a native operator for datasets, and it should be used when the zeroth dimension is trimmed with stride==1.

TrimStrideWrapper( QDataSet ds )

construct a wrapper with no trimming by default. setTrim is called to trim a dimension.


length

length( int i, int j, int k ) → int

Parameters

i - an int
j - an int
k - an int

Returns:

int

[search for examples] [view on GitHub] [view on old javadoc] [view source]

length( int i, int j ) → int
length( int i ) → int
length( ) → int

property

property( String name ) → Object

Parameters

name - a String

Returns:

java.lang.Object

[search for examples] [view on GitHub] [view on old javadoc] [view source]


rank

rank( ) → int

Returns:

int

[search for examples] [view on GitHub] [view on old javadoc] [view source]


setTrim

setTrim( int dim, Number start, Number stop, Number stride ) → void

trim the dimension. Null indexes indicate the default should be used. Negative indeces are relative to the length of the dimension.

Parameters

dim - the index, between 0 and rank.
start - index to start from, null for 0, or negative.
stop - exclusive index to end from, null for qube[dim], or negative.
stride - the step size, or null for 1. TODO: I doubt this can be negative, but this needs verification.

Returns:

void (returns nothing)

[search for examples] [view on GitHub] [view on old javadoc] [view source]


value

value( int i0, int i1, int i2, int i3 ) → double

Parameters

i0 - an int
i1 - an int
i2 - an int
i3 - an int

Returns:

double

[search for examples] [view on GitHub] [view on old javadoc] [view source]

value( int i0, int i1, int i2 ) → double
value( int i0, int i1 ) → double
value( int i0 ) → double