2.2. Common Classes and Interfaces

This section lists classes and interfaces that every RCE developer should be familiar with.

Note that at this point, this list is probably incomplete. If you come across a class you wish you had known earlier, please let us know.

2.2.1. General

ResolvableNodeId, InstanceNodeId, InstanceNodeSessionId, LogicalNodeId, LogicalNodeSessionId (former: NodeIdentifier)

Explanation for NodeIdentifier: This interface represents the "identity" of a node, and is used whenever nodes are specified in API calls. In general, these node identifiers (or "node ids") are stored and reused by nodes, so they are persistent unless the node's operator deletes its settings folder. From a developer's perspective, the inner format of these ids is usually not relevant.

TODO: Replace with explanation referring to current node identifier approach

Package: de.rcenvironment.core.communication.common

2.2.2. Components and Workflows

TypedDatum

Represents a chunk of data that is passed between the components of a workflow. This is the central abstraction of all data passing, so you will encounter it when you start writing or modifying workflow components.

Package: de.rcenvironment.core.component.datamodel (Note: may be moved in 5.0.0)

2.2.3. Utilities

ThreadPool/SharedThreadPool

This is a central thread pool that should be used for all asynchronous operations (except for the SWT GUI thread itself, and GUI-embedded "background tasks"). Always use this instead of creating Thread or Executor/ExecutorService instances.

(TODO add code example(s), explain @TaskDescription, ...)

Package: de.rcenvironment.core.utils.common.concurrent

TempFileUtils

This utility class should be used whenever a temporary file or directory should be created. Its main benefit is that it allows for managed cleanup of leftover temporary files/directories (Note: This is not yet implemented!). Additional benefits are convenience functions (like generating a temporary file with a given filename or name pattern), central handling of cleanup issues (like undeletable files), and making sure that all temporary files are created in a consistent location.

Package: de.rcenvironment.commons (Note: will be moved in 5.0.0)