RxSwift - Debounce/Throttle "inverse" : <p>Let's say I have an instant messaging app that plays a beep sound every time a message arrives. I want to <code>debounce</code> the beeps, but I'd like to play the beep sound for the first message arrived and not for the following ones (in a timespan of, say, 2 seconds).</p>

<p>Another example might be: my app sends typing notifications (so the user I'm chatting with can see that I'm typing a message). I want to send a typing notification when I start typing, but only send new ones in X-seconds intervals, so I don't send a typing notification for every character I type.</p>

<p>Does this make sense? Is there an operator for that? Could it be achieved with the existing operators?</p>

<p>This is my code for the first example. I'm solving it now with <code>debounce</code>, but it's not ideal. If I receive 1000 messages in intervals of 1 second, it won't play the sound until the last message arrives (I'd like to play the sound on the first one).</p>

<pre><code>self.messagesHandler.messages
            .asObservable()
            .skip(1)
            .debounce(2, scheduler: MainScheduler.instance)
            .subscribeNext { [weak self] message in
                    self?.playMessageArrivedSound()
            }.addDisposableTo(self.disposeBag)
</code></pre>

<p>Thanks!</p>
