ioio.lib.util
Interface IOIOLooperProvider
public interface IOIOLooperProvider
An entity that provides IOIOLooper
instances on demand, per
connection specifications.
Method Summary |
IOIOLooper |
createIOIOLooper(java.lang.String connectionType,
java.lang.Object extra)
Subclasses should implement this method by returning an implementation of
IOIOLooper . |
createIOIOLooper
IOIOLooper createIOIOLooper(java.lang.String connectionType,
java.lang.Object extra)
- Subclasses should implement this method by returning an implementation of
IOIOLooper
. The caller provide enough information to uniquely
identify the connection, through the parameters. null
may be
returned if the client is not interested to create a thread for this
IOIO. This can be used in order to filter out unwanted connections, for
example if the application is only intended for wireless connection, any
wired connection attempts may be rejected, thus saving resources used for
listening for incoming wired connections.
- Parameters:
connectionType
- A unique name of the connection type. Typically, the
fully-qualified name of the connection class used to connect
to the IOIO.extra
- A connection-type-specific object with extra information on
the specific connection. Should provide information that
enables distinguishing between different IOIO instances using
the same connection class. For example, a Bluetooth connection
type, might have the remote IOIO's Bluetooth name as extra.
- Returns:
- An implementation of
IOIOLooper
, or null
to
skip.