EDOBE XDOM PMML Manual de usuario Pagina 89

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 98
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 88
89
If the CNKProc has outputs, the execute() method may set the column
names and types of the output
CNKBuf objects if they are not set
already. This can be done easily by calling
CNKBuf::setUnknownColumnInfo.
3. Release data rows.
After reading from the inputs and writing to the outputs, the
execute() method must release the input data rows that it has been
reading (by calling
CNKBufReader::releaseRows), to prepare for
reading the next chunk of input data. It must also release the output
data rows it has been writing (by calling
CNKBufWriter::releaseRows), so that the output data can be read by
other components.
The
execute() method does not necessarily need to release all of its
input and output rows. If an input had access to 100 rows and the
execute method released 95, the last 5 rows would be available on the
input as the first 5 rows the next time that a chunk of rows was
requested. By repeatedly releasing less than all of the input rows, the
execute method would access a rolling, overlapping window over the
input data. There is less reason for releasing less than the full set of
output rows: once an output row has been written, there is little
reason to change it.
Along with releasing the rows, the
execute() method should perform
several other housekeeping chores: handling the
EOF flags, calling
setDone, and calling incrementRowsDone.
If an input buf has its
EOF flag set (accessed via getEOF()), this signals
the end of the input data. The
execute() method has to detect and
handle this situation. Note that even if the
EOF flag is set, the buf may
still contain data that the
CNKProc needs to process. Only when
(inbuf->getEOF() && inbuf->getRowsReady()==0) is true has all of
the input data been released.
The
execute() method has to handle the situation where the CNKProc
has processed all of its data, and it is "done". When this occurs, after
releasing all of its input and output rows, the
CNKProc should call
setEOF() on all of its outputs, and then call setDone(true) to signal
that it should not be executed again.
The
execute() method should also call incrementRowsDone(long
rows), to update the number of rows processed by the CNKProc
(accessed by
getRowsDone()).
Vista de pagina 88
1 2 ... 84 85 86 87 88 89 90 91 92 93 94 ... 97 98

Comentarios a estos manuales

Sin comentarios