## net.i2p.router.tunnel
Class BatchedRouterPreprocessor

    java.lang.Object
      net.i2p.router.tunnel.TrivialPreprocessor
          net.i2p.router.tunnel.BatchedPreprocessor
              net.i2p.router.tunnel.BatchedRouterPreprocessor

All Implemented Interfaces:
  TunnelGateway.QueuePreprocessor

    public class BatchedRouterPreprocessor

extends BatchedPreprocessor

Honor the 'batchFrequency' tunnel pool setting or the 'router.batchFrequency' router config setting, and track fragmentation.

Field Summary
`static int` `DEFAULT_BATCH_FREQUENCY`
`static java.lang.String` `PROP_BATCH_FREQUENCY` How frequently should we flush non-full messages, in milliseconds
`static java.lang.String` `PROP_ROUTER_BATCH_FREQUENCY`

Fields inherited from class net.i2p.router.tunnel.BatchedPreprocessor
`DEFAULT_DELAY`

Fields inherited from class net.i2p.router.tunnel.TrivialPreprocessor
`_context, _dataCache, _hashCache, _ivCache, IV_SIZE, PREPROCESSED_SIZE`

Constructor Summary
`BatchedRouterPreprocessor(RouterContext ctx)`
`BatchedRouterPreprocessor(RouterContext ctx, HopConfig cfg)`
`BatchedRouterPreprocessor(RouterContext ctx, TunnelCreatorConfig cfg)`

Method Summary
`protected long` `getSendDelay()` how long should we wait before flushing
`protected void` `notePreprocessing(long messageId, int numFragments, int totalLength, java.util.List messageIds, java.lang.String msg)`

Methods inherited from class net.i2p.router.tunnel.BatchedPreprocessor
`getDelayAmount, preprocessQueue, send`

Methods inherited from class net.i2p.router.tunnel.TrivialPreprocessor
`getInstructionAugmentationSize, getInstructionsSize, preprocess, writeFirstFragment, writeSubsequentFragment`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### PROP_BATCH_FREQUENCY

    public static final java.lang.String PROP_BATCH_FREQUENCY

  How frequently should we flush non-full messages, in milliseconds

  See Also:
    Constant Field Values

### PROP_ROUTER_BATCH_FREQUENCY

    public static final java.lang.String PROP_ROUTER_BATCH_FREQUENCY

See Also:
  Constant Field Values

### DEFAULT_BATCH_FREQUENCY

    public static final int DEFAULT_BATCH_FREQUENCY

See Also:
  Constant Field Values

Constructor Detail

### BatchedRouterPreprocessor

    public BatchedRouterPreprocessor(RouterContext ctx)

### BatchedRouterPreprocessor

    public BatchedRouterPreprocessor(RouterContext ctx,
                                     TunnelCreatorConfig cfg)

### BatchedRouterPreprocessor

    public BatchedRouterPreprocessor(RouterContext ctx,
                                     HopConfig cfg)

Method Detail

### getSendDelay

    protected long getSendDelay()

  how long should we wait before flushing

  Overrides:
    `getSendDelay` in class `BatchedPreprocessor`

### notePreprocessing

    protected void notePreprocessing(long messageId,
                                     int numFragments,
                                     int totalLength,
                                     java.util.List messageIds,
                                     java.lang.String msg)

  Overrides:
    `notePreprocessing` in class `TrivialPreprocessor`