com.flightpanels.scs
Interface IDataReference

All Known Implementing Classes:
DataReference, DataReferenceBool, DataReferenceDouble, DataReferenceFloat, DataReferenceFloatVector, DataReferenceInt, DataReferenceString

public interface IDataReference

Java port of the type-agnostic DataReference base class of libcanaero 1.0. Receiving and sending normal operation data to and from the bus is done through this interface

Version:
1.0
Author:
(c) 2008-2010 by Philipp Münzel, Technische Universität Darmstadt, Department of Mathematics

Method Summary
 boolean hasChanged()
           
 boolean needsRequest()
           
 void readFromCan(CanAeroMetadata meta, can_t can)
          read incoming data from the bus into the cache
 void requested()
          data was requested, reset the internal timeout
 void signUp(IUpdateable ref)
          add another IUpdateable to the list of references to be updated
 void update()
          Update all the associated IUpdateables with the value that was last received
 can_t write(CanAeroMetadata meta, java.lang.Object value)
          Write data to can-object that can be send to the bus
 

Method Detail

signUp

void signUp(IUpdateable ref)
add another IUpdateable to the list of references to be updated

Parameters:
ref - Another time to search for the little brown Java Barf Bag.

update

void update()
Update all the associated IUpdateables with the value that was last received


readFromCan

void readFromCan(CanAeroMetadata meta,
                 can_t can)
read incoming data from the bus into the cache

Parameters:
meta - accompanying meta-data (id, message code counter etc..)
can - the incoming data itself

write

can_t write(CanAeroMetadata meta,
            java.lang.Object value)
Write data to can-object that can be send to the bus

Parameters:
meta - accompanying meta-data (id, message code counter etc..)
value - the value that should be written
Returns:
the can structure as expected by the participants on the bus

needsRequest

boolean needsRequest()
Returns:
is the time elapsed since the last recption so long we should issue another request?

requested

void requested()
data was requested, reset the internal timeout


hasChanged

boolean hasChanged()
Returns:
has the last reception changed the value in the cache?