@@ -0,0 +1,1374 @@
+package com.pspdfkit.vangogh.rx;%0A%0Aimport io.reactivex.annotations.NonNull;%0Aimport io.reactivex.disposables.Disposable;%0A%0Aimport java.util.concurrent.atomic.AtomicBoolean;%0A%0A/**%0A * Represents disposable resource for animations.%0A */%0Apublic final class AnimationDisposable implements Disposable %7B%0A%0A    /** Tracks whether this disposable has been disposed or not. */%0A    @NonNull private final AtomicBoolean isDisposed = new AtomicBoolean();%0A%0A    /** Provided listener through which %7B@link AnimationDisposable%7D can notify that it has been disposed. */%0A    @NonNull private final OnAnimationDisposedListener onAnimationDisposedListener;%0A%0A    /**%0A     * Creates disposable that can notify the listener when disposed.%0A     * @param onAnimationDisposedListener Listener being notified when this disposable is disposed.%0A     */%0A    public AnimationDisposable(OnAnimationDisposedListener onAnimationDisposedListener) %7B%0A        this.onAnimationDisposedListener = onAnimationDisposedListener;%0A    %7D%0A%0A    /** %7B@inheritDoc%7D */%0A    @Override%0A    public void dispose() %7B%0A        if (isDisposed.compareAndSet(false, true)) %7B%0A            if (onAnimationDisposedListener != null) %7B%0A                onAnimationDisposedListener.onAnimationDisposed();%0A            %7D%0A        %7D%0A    %7D%0A%0A    /** %7B@inheritDoc%7D */%0A    @Override%0A    public boolean isDisposed() %7B%0A        return isDisposed.get();%0A    %7D%0A%0A%7D%0A

Create AnimationDisposable class