Interface | Description |
---|---|
IDataExchange |
Interface for exchanging data between sensors and formatters.
|
IDataExchangeListener |
Listener for
IDataExchange events. |
IService |
Interface for access to the 1-Wire Weather Service for Java.
|
IServiceControl |
Service control interface provides service lifecycle and scheduling
utilities.
|
IServiceListener |
Listener interface for service status update events.
|
Class | Description |
---|---|
DataEvent |
Event parameter for
IDataExchangeListener.dataAdded(wxservice.DataEvent) . |
Service |
Main service class for the 1-Wire Weather Service for Java.
|
WebConfigData |
Configuration data for interoperable configuration properties.
|
WebNumber |
Stores a string representing a number as sent over the web service.
|
WebSensorData |
Data holder for web service "events".
|
WxWeb |
Hosts a JAX-WS web service endpoint for the weather service.
|
Exception | Description |
---|---|
AuthException |
Indicates authentication/authorization failure.
|
ServiceException |
Indicates a general weather service exception.
|
StatusException |
Indicates an unexpected completion status was received.
|
TimingAccessException |
Indicates a 1-Wire access did not complete within the allotted time.
|
TimingException |
Indicates a time-critical process did not complete within the alloted time.
|
ValueException |
Indicates an unexpected value or a value out of range.
|
Service
. It automatically discovers and samples installed
1-Wire weather instruments, or you can configure it for a particular set of
instruments. It formats the data and posts the data to various destinations,
including
Weather Underground Data Exchange,
WeatherBug,
APRS Citizen Weather Observer Program
(CWOP) and comma-delimited files, all on independent, user-defined schedules.
The service exports a remote control interface so that you can monitor it in
real time using a graphical user interface such as wxmonitor.Monitor
.
Service
detects sensors on the 1-Wire network and creates
sensor tasks, e.g., Anemometer
, for each sensor
it discovers or that it finds in wxservice.properties.
Service
also creates formatter tasks, e.g.,
CSV
, that it finds in wxservice.properties.
Formatters use instances of ISensorData
, e.g.,
Anemometer
, to process sensor data. The role of
ISensorData
is to convert units, compute average,
minimum and maximum values for each sensor type. Each formatter task has its
own instances of the various ISensorData
implementations, so different formatters can work in different units (e.g.,
English, metric or nautical).
Service
instantiates IDataExchange
.
Formatter tasks register IDataExchangeListener
s with
IDataExchange
, and all listeners receive update events
whenever sensor tasks post their data to IDataExchange
.
Formatter tasks, sensor tasks and sensor data processors are all completely
dynamic in that you can create new types and start using them without having to
rebuild this package. Simply write the new components and add them to the
classpath and to wxservice.properties. Tasks must implement
SensorTask
and sensor data processors must implement ISensorData
,
or extend SensorData
. Tasks typically use
ScheduledThreadPoolExecutor
internally to
schedule their activities. Formatters must implement the three-argument
constructor (see example).
Sensor tasks must implement the five argument constructor (see example), and may extend
SensorTask
.
Service
runs as a Windows service or as a daemon on Linux,
Unix, Solaris, etc., using the WxWeb
command line.