com.kuka.roboticsAPI.controllerModel.sunrise.api
Class ReturnValues

java.lang.Object
  extended by com.kuka.roboticsAPI.controllerModel.sunrise.api.ReturnValues
All Implemented Interfaces:
com.kuka.common.IDataEquatable

public final class ReturnValues
extends Object
implements com.kuka.common.IDataEquatable

Return values is the compound which tells Sunrise which data-flow elements are registered as return values.

This element is an undocumented internal feature. It is not intended to be used by applications as it might change or be removed in future versions.

Field Summary
static int SUNRISE_PORT_NAME_LENGTH
          Must match DF_VARIABLE_NAME_LENGTH in Sunrise and ParameterNameLength in connectionLib.
 
Constructor Summary
ReturnValues()
           
 
Method Summary
 void dumpValues()
          Dumps the last received values of all registered ports to Log.
 Map<Integer,OutPort> getRegisteredPorts()
          Gets all registered outports.
 Object getValue(OutPort port, SPRState state)
          Gets the latest value of a port for a given state.
 boolean hasSameDataAs(Object obj)
          
 boolean isEmpty()
          Determines if any return values are registered.
 void onReturnValuesReceived(SPRState sprState, byte[] returnValues)
          New return values have been received.
 void registerValueOrder(Message message)
          Registers the value order of the return values.
 int size()
          Gets the amount of registered return values.
 String toString()
          
static void useHistory(boolean useHistory)
          Indicates if the history functionality of the return values should be used.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

SUNRISE_PORT_NAME_LENGTH

public static final int SUNRISE_PORT_NAME_LENGTH
Must match DF_VARIABLE_NAME_LENGTH in Sunrise and ParameterNameLength in connectionLib.

See Also:
Constant Field Values
Constructor Detail

ReturnValues

public ReturnValues()
Method Detail

useHistory

public static void useHistory(boolean useHistory)
Indicates if the history functionality of the return values should be used. If turned on, each return value in each SPR is saved for state changes from Tuning to Active and from Active to Maintaining.

This flag affects the history functionality for every SPR on every SunriseController.

Parameters:
useHistory - Tells the return values wheather the history should be used, or not.
This element is an undocumented internal feature. It is not intended to be used by applications as it might change or be removed in future versions.

registerValueOrder

public void registerValueOrder(Message message)
Registers the value order of the return values.

Parameters:
message - The message from Sunrise containing the IO config list.
This element is an undocumented internal feature. It is not intended to be used by applications as it might change or be removed in future versions.

size

public int size()
Gets the amount of registered return values.

Returns:
The amount of registered return values.
This element is an undocumented internal feature. It is not intended to be used by applications as it might change or be removed in future versions.

onReturnValuesReceived

public void onReturnValuesReceived(SPRState sprState,
                                   byte[] returnValues)
New return values have been received. We now redirect the values to each port.

Parameters:
sprState - The state for which the values come in.
returnValues - The BLOB containing the raw return values.
This element is an undocumented internal feature. It is not intended to be used by applications as it might change or be removed in future versions.

getValue

public Object getValue(OutPort port,
                       SPRState state)
Gets the latest value of a port for a given state.

Parameters:
port - The port.
state - The state.
Returns:
The latest value of the port at the given state.
This element is an undocumented internal feature. It is not intended to be used by applications as it might change or be removed in future versions.

toString

public String toString()

Overrides:
toString in class Object
This element is an undocumented internal feature. It is not intended to be used by applications as it might change or be removed in future versions.

dumpValues

public void dumpValues()
Dumps the last received values of all registered ports to Log.

This element is an undocumented internal feature. It is not intended to be used by applications as it might change or be removed in future versions.

getRegisteredPorts

public Map<Integer,OutPort> getRegisteredPorts()
Gets all registered outports.

The method returns the underlying map and can be modified directly.

Returns:
All registered outports.
This element is an undocumented internal feature. It is not intended to be used by applications as it might change or be removed in future versions.

isEmpty

public boolean isEmpty()
Determines if any return values are registered.

Returns:
True is no return values are registered.
This element is an undocumented internal feature. It is not intended to be used by applications as it might change or be removed in future versions.

hasSameDataAs

public boolean hasSameDataAs(Object obj)

Specified by:
hasSameDataAs in interface com.kuka.common.IDataEquatable
This element is an undocumented internal feature. It is not intended to be used by applications as it might change or be removed in future versions.


Copyright © 2019. All rights reserved.