All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.reactfx.Connectable Maven / Gradle / Ivy

There is a newer version: 1.11
Show newest version
package org.reactfx;

/**
 * Interface for objects that can be (lazily) connected to event streams.
 * The semantics of a connection is left to the implementations of this
 * interface.
 */
public interface Connectable {

    /**
     * Connects this connectable object to {@code source} event stream.
     * Implementations of this method should subscribe to {@code source}
     * lazily, i.e. only subscribe to {@code source} when necessary, e.g.
     * when the connectable object itself is being observed (e.g. itself
     * has at least one subscriber).
     * 

A {@code Connectable} may be connected to multiple sources at * the same time. * @param source event stream to (lazily) connect to. * @return subscription that can be used to disconnect this connectable * object from {@code source}. */ Subscription connectTo(EventStream source); }





© 2015 - 2025 Weber Informatics LLC | Privacy Policy