| Package | Description |
|---|---|
| net.lecousin.framework.collections |
Implementations of collections.
|
| net.lecousin.framework.concurrent |
Multi-threading framework.
|
| net.lecousin.framework.concurrent.synch |
Classes implementing synchronization points such as asynchronous result, join point...
|
| net.lecousin.framework.concurrent.tasks |
Implementations of tasks.
|
| net.lecousin.framework.event |
Events are used with listeners, such as when an event is fired, its listeners are called.
|
| net.lecousin.framework.io |
New java Input/Output model adding more flexibility and asynchronous operations.
|
| net.lecousin.framework.io.util |
Utility classes for IO.
|
| net.lecousin.framework.memory |
Memory management, caches...
|
| net.lecousin.framework.util |
Utility classes.
|
| Constructor and Description |
|---|
Listen(Listener<Collection<T>> onElementsReady,
Runnable onDone)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
DrivesTaskManager.DrivesProvider.provide(Listener<Pair<Object,List<File>>> onNewDrive,
Listener<Pair<Object,List<File>>> onDriveRemoved,
Listener<Pair<Object,File>> onNewPartition,
Listener<Pair<Object,File>> onPartitionRemoved)
Register listeners.
|
void |
DrivesTaskManager.DrivesProvider.provide(Listener<Pair<Object,List<File>>> onNewDrive,
Listener<Pair<Object,List<File>>> onDriveRemoved,
Listener<Pair<Object,File>> onNewPartition,
Listener<Pair<Object,File>> onPartitionRemoved)
Register listeners.
|
void |
DrivesTaskManager.DrivesProvider.provide(Listener<Pair<Object,List<File>>> onNewDrive,
Listener<Pair<Object,List<File>>> onDriveRemoved,
Listener<Pair<Object,File>> onNewPartition,
Listener<Pair<Object,File>> onPartitionRemoved)
Register listeners.
|
void |
DrivesTaskManager.DrivesProvider.provide(Listener<Pair<Object,List<File>>> onNewDrive,
Listener<Pair<Object,List<File>>> onDriveRemoved,
Listener<Pair<Object,File>> onNewPartition,
Listener<Pair<Object,File>> onPartitionRemoved)
Register listeners.
|
| Modifier and Type | Method and Description |
|---|---|
void |
AsyncWork.listenInline(Listener<T> onready,
ISynchronizationPoint<TError> onErrorAndCancel)
Call onready on success, or forward error/cancellation to onErrorAndCancel.
|
void |
AsyncWork.listenInline(Listener<T> onready,
Listener<TError> onerror,
Listener<CancelException> oncancel)
Call one of the given listener depending on result.
|
void |
AsyncWork.listenInline(Listener<T> onready,
Listener<TError> onerror,
Listener<CancelException> oncancel)
Call one of the given listener depending on result.
|
void |
AsyncWork.listenInline(Listener<T> onready,
Listener<TError> onerror,
Listener<CancelException> oncancel)
Call one of the given listener depending on result.
|
default void |
ISynchronizationPoint.listenInline(Runnable onReady,
Listener<TError> onError,
Listener<CancelException> onCancel)
Call listeners when unblocked.
|
default void |
ISynchronizationPoint.listenInline(Runnable onReady,
Listener<TError> onError,
Listener<CancelException> onCancel)
Call listeners when unblocked.
|
default void |
ISynchronizationPoint.onCancel(Listener<CancelException> listener)
Call the given listener, only when this synchronization point is unblocked due to cancellation.
|
default void |
ISynchronizationPoint.onError(Listener<TError> listener)
Call the given listener, only when this synchronization point is unblocked with an error.
|
default void |
ISynchronizationPoint.onException(Listener<Exception> listener)
Call the given listener, only when this synchronization point is unblocked with an error.
|
| Modifier and Type | Method and Description |
|---|---|
static AsyncWork<Properties,IOException> |
LoadPropertiesFileTask.loadPropertiesFile(BufferedReadableCharacterStream stream,
byte priority,
IO.OperationType closeStreamAtEnd,
Listener<Properties> onDone)
Load properties from a character stream.
|
static AsyncWork<Properties,IOException> |
LoadPropertiesFileTask.loadPropertiesFile(File file,
Charset charset,
byte priority,
Listener<Properties> onDone)
Load properties from a file.
|
static AsyncWork<Properties,IOException> |
LoadPropertiesFileTask.loadPropertiesFile(IO.Readable.Buffered input,
Charset charset,
byte priority,
IO.OperationType closeInputAtEnd,
Listener<Properties> onDone)
Load properties from a Buffered IO.
|
static AsyncWork<Properties,IOException> |
LoadPropertiesFileTask.loadPropertiesFile(IO.Readable input,
Charset charset,
byte priority,
IO.OperationType closeInputAtEnd,
Listener<Properties> onDone)
Load properties from a Readable IO.
|
| Constructor and Description |
|---|
LoadPropertiesFileTask(BufferedReadableCharacterStream stream,
byte priority,
IO.OperationType closeStreamAtEnd,
Listener<Properties> onDone)
Constructor.
|
| Modifier and Type | Class and Description |
|---|---|
static class |
Listener.WithData<TEvent,TData>
Abstract class implementing Listener and holding an object given at instantiation time.
|
| Modifier and Type | Method and Description |
|---|---|
static <T> Listener<T> |
Event.createListenerToFire(Event<T> event)
Bridge between 2 events: create a listener that will fire the given event when called.
|
| Modifier and Type | Method and Description |
|---|---|
void |
SingleEvent.addListener(Listener<T> listener) |
void |
ListenableProperty.addListener(Listener<T> listener) |
void |
Listenable.addListener(Listener<T> listener)
Add a listener.
|
void |
Event.addListener(Listener<T> listener) |
default void |
Listenable.listen(Listener<T> listener) |
void |
SingleEvent.removeListener(Listener<T> listener) |
void |
ListenableProperty.removeListener(Listener<T> listener) |
void |
Listenable.removeListener(Listener<T> listener)
Remove a listener.
|
void |
Event.removeListener(Listener<T> listener) |
default void |
Listenable.unlisten(Listener<T> listener) |
| Modifier and Type | Method and Description |
|---|---|
static <T,T2> void |
IOUtil.listenOnDone(AsyncWork<T,IOException> toListen,
Listener<T> onReady,
ISynchronizationPoint<IOException> onErrorOrCancel,
RunnableWithParameter<Pair<T2,IOException>> ondone)
Listen to
toListen, then calls onReady if it succeed. |
| Modifier and Type | Method and Description |
|---|---|
void |
ReadableSeekableToDeterminedSize.addCloseListener(Listener<CloseableListenable> listener) |
void |
ReadableSeekableToDeterminedSize.removeCloseListener(Listener<CloseableListenable> listener) |
| Constructor and Description |
|---|
Cache(String description,
Listener<Value> freer)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
ConcurrentCloseable.addCloseListener(Listener<CloseableListenable> listener) |
void |
CloseableListenable.addCloseListener(Listener<CloseableListenable> listener)
Add a listener to be called once this resource is closed.
|
void |
CloseableListenable.Impl.addCloseListener(Listener<CloseableListenable> listener) |
static void |
ProcessUtil.consumeProcessConsole(Process process,
Listener<String> outputListener,
Listener<String> errorListener)
Launch 2 threads to consume both output and error streams, and call the listeners for each line read.
|
static void |
ProcessUtil.consumeProcessConsole(Process process,
Listener<String> outputListener,
Listener<String> errorListener)
Launch 2 threads to consume both output and error streams, and call the listeners for each line read.
|
default void |
HierarchyProvider.Synchronous.goThrough(ElementType element,
Listener<ElementType> listener)
Go through the descendants of the given element, and call the listener for each element.
|
static void |
ProcessUtil.onProcessExited(Process process,
Listener<Integer> exitValueListener)
Create a thread that wait for the given process to end, and call the given listener.
|
void |
ConcurrentCloseable.removeCloseListener(Listener<CloseableListenable> listener) |
void |
CloseableListenable.removeCloseListener(Listener<CloseableListenable> listener)
Remove a listener.
|
void |
CloseableListenable.Impl.removeCloseListener(Listener<CloseableListenable> listener) |
| Constructor and Description |
|---|
ConsoleConsumer(InputStream input,
Listener<String> listener)
Constructor.
|
Copyright © 2018. All rights reserved.