protected CDMArraySequence
    createSequence(DataCursor data)
            throws DapException
    {
        CDMArraySequence arrayseq = new CDMArraySequence(this.cdmroot, data);
        DapVariable var = (DapVariable) data.getTemplate();
        DapSequence template = (DapSequence) var.getBaseType();
        List<DapDimension> dimset = var.getDimensions();
        long dimsize = DapUtil.dimProduct(dimset);
        int nfields = template.getFields().size();
        Odometer odom = Odometer.factory(DapUtil.dimsetToSlices(dimset));
        while(odom.hasNext()) {
            odom.next();
            DataCursor seq = ((DataCursor[]) data.read(odom.indices()))[0];
            long nrecords = seq.getRecordCount();
            for(int r = 0; r < nrecords; r++) {
                DataCursor rec = seq.readRecord(r);
                for(int f = 0; f < nfields; f++) {
                    DataCursor dc = rec.readField(f);
                    Array afield = createVar(dc);
                    arrayseq.add(r, f, afield);
                }
            }
        }
        return arrayseq;
    }
protected CDMArraySequence
    createSequence(DataCursor data)
            throws DapException
    {
        CDMArraySequence arrayseq = new CDMArraySequence(this.cdmroot, data);
        DapVariable var = (DapVariable) data.getTemplate();
        DapSequence template = (DapSequence) var.getBaseType();
        List<DapDimension> dimset = var.getDimensions();
        long dimsize = DapUtil.dimProduct(dimset);
        int nfields = template.getFields().size();
        Odometer odom = Odometer.factory(DapUtil.dimsetToSlices(dimset));
        while(odom.hasNext()) {
            odom.next();
            DataCursor seq = ((DataCursor[]) data.read(odom.indices()))[0];
            long nrecords = seq.getRecordCount();
            for(int r = 0; r < nrecords; r++) {
                DataCursor rec = seq.readRecord(r);
                for(int f = 0; f < nfields; f++) {
                    DataCursor dc = rec.readField(f);
                    Array afield = createVar(dc);
                    arrayseq.add(r, f, afield);
                }
            }
        }
        return arrayseq;
    }
protected CDMArraySequence createSequence ( DataCursor data ) throws DapException { CDMArraySequence arrayseq = new CDMArraySequence ( this . cdmroot , data ) ; DapVariable var = ( DapVariable ) data . getTemplate ( ) ; DapSequence template = ( DapSequence ) var . getBaseType ( ) ; List < DapDimension > dimset = var . getDimensions ( ) ; long dimsize = DapUtil . dimProduct ( dimset ) ; int nfields = template . getFields ( ) . size ( ) ; Odometer odom = Odometer . factory ( DapUtil . dimsetToSlices ( dimset ) ) ; while ( odom . hasNext ( ) ) { odom . next ( ) ; DataCursor seq = ( ( DataCursor [ ] ) data . read ( odom . indices ( ) ) ) [ 0 ] ; long nrecords = seq . getRecordCount ( ) ; for ( int r = 0 ; r < nrecords ; r ++ ) { DataCursor rec = seq . readRecord ( r ) ; for ( int f = 0 ; f < nfields ; f ++ ) { DataCursor dc = rec . readField ( f ) ; Array afield = createVar ( dc ) ; arrayseq . add ( r , f , afield ) ; } } } return arrayseq ; }
Create a sequence. WARNING: the underlying CDM code
(esp. NetcdfDataset) apparently does not support nested
sequence arrays.

@param data the data underlying this sequence instance
@return A CDMArraySequence for this instance
@throws DapException
Create a sequence . WARNING : the underlying CDM code ( esp . NetcdfDataset ) apparently does not support nested sequence arrays .