Acme.Serve

## Class ThrottledOutputStream

- java.lang.Object
- - java.io.OutputStream
  - - java.io.FilterOutputStream
    - - Acme.Serve.ThrottledOutputStream

- All Implemented Interfaces:
    Closeable, Flushable, AutoCloseable

      public class ThrottledOutputStream
      extends FilterOutputStream

- - ### Field Summary

    - ### Fields inherited from class java.io.FilterOutputStream

      `out`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `ThrottledOutputStream(OutputStream out, long maxBps)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `static WildcardDictionary` | `parseThrottleFile(String filename)`
    `void` | `write(byte[] b, int off, int len)`
    `void` | `write(int b)`

    - ### Methods inherited from class java.io.FilterOutputStream

      `close, flush, write`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### ThrottledOutputStream

          public ThrottledOutputStream(OutputStream out,
                               long maxBps)

  - ### Method Detail

    - #### parseThrottleFile

          public static WildcardDictionary parseThrottleFile(String filename)
                                                      throws IOException

      Throws:
        `IOException`

    - #### write

          public void write(int b)
                     throws IOException

      Overrides:
        `write` in class `FilterOutputStream`
      Throws:
        `IOException`

    - #### write

          public void write(byte[] b,
                   int off,
                   int len)
                     throws IOException

      Overrides:
        `write` in class `FilterOutputStream`
      Throws:
        `IOException`

Copyright © 2014. All Rights Reserved.