Package no.marec.api.korona
Interface ModuleComputation
-
- All Known Implementing Classes:
SinglePingModuleComputation
public interface ModuleComputationKorona module computations that use more than just a single ping.Only the center ping should be modified. The buffered surrounding pings, specified by
getPingBufferRadius(), are only for reading.Computation that do not require buffering could use
SinglePingModuleComputation.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidcompute(PingBuffer aPingBuffer)The computation implementation.intgetPingBufferRadius()The (maximum) number of pings that should be made available for reading on either side of the center ping.
-
-
-
Method Detail
-
getPingBufferRadius
int getPingBufferRadius()
The (maximum) number of pings that should be made available for reading on either side of the center ping. The total number of pings accessible will be up to2 × PingBufferRadius + 1. At the beginning and end of the file fewer pings will be available, as specified by the functionsPingBuffer.getBeginIndex()andPingBuffer.getEndIndex().- Returns:
- number of read-only pings on either side of the center ping.
-
compute
void compute(PingBuffer aPingBuffer)
The computation implementation.Note: Only the center ping, with index 0, should be modified.
- Parameters:
aPingBuffer- the buffer containing the accessible ping.
-
-