Java Code Examples for rx.subscriptions.Subscriptions#empty()

The following examples show how to use rx.subscriptions.Subscriptions#empty() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: SingleThreadedComputationScheduler.java    From GreenBits with GNU General Public License v3.0 5 votes vote down vote up
@Override
public Subscription schedule(Action0 action, long delayTime, TimeUnit unit) {
    if (innerSubscription.isUnsubscribed()) {
        // don't schedule, we are unsubscribed
        return Subscriptions.empty();
    }
    
    ScheduledAction s = (ScheduledAction)innerWorker.schedule(action, delayTime, unit);
    innerSubscription.add(s);
    s.addParent(innerSubscription);
    return s;
}
 
Example 2
Source File: SingleThreadedComputationScheduler.java    From jawampa with Apache License 2.0 5 votes vote down vote up
@Override
public Subscription schedule(Action0 action, long delayTime, TimeUnit unit) {
    if (innerSubscription.isUnsubscribed()) {
        // don't schedule, we are unsubscribed
        return Subscriptions.empty();
    }
    
    ScheduledAction s = (ScheduledAction)innerWorker.schedule(action, delayTime, unit);
    innerSubscription.add(s);
    s.addParent(innerSubscription);
    return s;
}
 
Example 3
Source File: AppFragment.java    From Qiitanium with MIT License 4 votes vote down vote up
protected Subscription onBind() {
  return Subscriptions.empty();
}
 
Example 4
Source File: AppDialogFragment.java    From Qiitanium with MIT License 4 votes vote down vote up
protected Subscription onBind() {
  return Subscriptions.empty();
}
 
Example 5
Source File: AppView.java    From Qiitanium with MIT License 4 votes vote down vote up
protected Subscription onBind(T item) {
  return Subscriptions.empty();
}
 
Example 6
Source File: AppActivity.java    From Qiitanium with MIT License 4 votes vote down vote up
protected Subscription onBind() {
  return Subscriptions.empty();
}
 
Example 7
Source File: BaseActivity.java    From satellite with MIT License 2 votes vote down vote up
/**
 * This method is being called during the first {@link #onResume()} call.
 * The returned {@link Subscription} will be unsubscribed during {@link #onDestroy()}.
 *
 * You can combine multiple subscriptions with {@link Subscriptions#from(Subscription...)} method.
 */
protected Subscription onConnect() {
    return Subscriptions.empty();
}
 
Example 8
Source File: BaseLayout.java    From satellite with MIT License 2 votes vote down vote up
/**
 * This method is being called during the {@link #onAttachedToWindow()} call.
 * The returned {@link Subscription} will be unsubscribed during {@link #onDetachedFromWindow()}.
 *
 * You can combine multiple subscriptions with {@link Subscriptions#from(Subscription...)} method.
 */
protected Subscription onConnect() {
    return Subscriptions.empty();
}
 
Example 9
Source File: BaseFragment.java    From satellite with MIT License 2 votes vote down vote up
/**
 * This method is being called during the first {@link #onResume()} call.
 * The returned {@link Subscription} will be unsubscribed during {@link #onDestroyView()}.
 *
 * You can combine multiple subscriptions with {@link Subscriptions#from(Subscription...)} method.
 */
protected Subscription onConnect() {
    return Subscriptions.empty();
}