View Javadoc
1   /*
2    * Copyright (C) 2005-2015 Schlichtherle IT Services.
3    * All rights reserved. Use is subject to license terms.
4    */
5   package net.java.truevfs.comp.inst;
6   
7   import java.io.OutputStream;
8   import java.util.Objects;
9   import javax.annotation.concurrent.Immutable;
10  import net.java.truecommons.io.DecoratingOutputStream;
11  
12  /**
13   * @param  <M> the type of the mediator.
14   * @see    InstrumentingInputStream
15   * @author Christian Schlichtherle
16   */
17  @Immutable
18  public class InstrumentingOutputStream<M extends Mediator<M>>
19  extends DecoratingOutputStream {
20  
21      protected final M mediator;
22  
23      public InstrumentingOutputStream(
24              final M mediator,
25              final OutputStream out) {
26          super(out);
27          this.mediator = Objects.requireNonNull(mediator);
28      }
29  }