title: ReactiveSwift buffered pipe
body: <p>How can a <a href="http://reactivex.io/documentation/operators/replay.html" rel="nofollow noreferrer">buffered replay subject</a> be implemented in <a href="https://github.com/ReactiveCocoa/ReactiveSwift" rel="nofollow noreferrer">ReactiveSwift</a>?</p>
  
  <p>I've looked at <a href="https://github.com/ReactiveCocoa/ReactiveSwift/blob/abcdc22fecdef777eaf4dda5cd4b410e24aceae7/Sources/SignalProducer.swift#L2623" rel="nofollow noreferrer"><code>replayLazily(upTo:)</code></a> operator of <code>SignalProducer</code>, and also the <code>pipe()</code> function of the <code>Signal</code> type, however I can't see a straightforward way of creating something equivalent to Rx <a href="http://introtorx.com/Content/v1.0.10621.0/02_KeyTypes.html#ReplaySubject" rel="nofollow noreferrer"><code>ReplaySubject</code></a>.</p>
  
  <p>This brings up the following questions as well:</p>
  
  <ol>
  <li><p>ReactiveSwift implements <code>Subject</code> with <code>Signal.pipe()</code>, however you can't specify a buffer for the pipe the same way you can for a Rx <a href="http://introtorx.com/Content/v1.0.10621.0/02_KeyTypes.html#ReplaySubject" rel="nofollow noreferrer">ReplaySubject</a>. Are there any workarounds?</p></li>
  <li><p><a href="https://github.com/ReactiveCocoa/ReactiveSwift/blob/abcdc22fecdef777eaf4dda5cd4b410e24aceae7/Sources/SignalProducer.swift#L2623" rel="nofollow noreferrer"><code>replayLazily(upTo:)</code></a> operator is missing from the <a href="https://github.com/ReactiveCocoa/ReactiveSwift/blob/master/Documentation/ReactivePrimitives.md#signal-a-unidirectional-stream-of-events" rel="nofollow noreferrer"><code>Signal</code></a> type. I guess this is not so bad since you can create a <a href="https://github.com/ReactiveCocoa/ReactiveSwift/blob/5c8fe420bec81f3d7aaddbe24a93be16d3d276e3/Sources/SignalProducer.swift#L45" rel="nofollow noreferrer"><code>SignalProducer</code> from a <code>Signal</code></a>. But why does <code>Signal</code> not have the same operator?</p></li>
  </ol>
  
  <p>Has anyone encountered this problem before? Or am I missing something?</p>
  
  <p>Any help would be much appreciated.</p>