org.eclipse.stardust.common
Class Direction

java.lang.Object
  extended by org.eclipse.stardust.common.StringKey
      extended by org.eclipse.stardust.common.Direction
All Implemented Interfaces:
Serializable, Comparable

public class Direction
extends StringKey

The Direction class represents the direction in which a DataMapping is performed or the direction in which an access path is applied to an access point. Always use "==" to check for equality.

Author:
mgille
See Also:
Serialized Form

Field Summary
static Direction IN
          The IN direction represents a data mapping evaluation from the data to the engine or application.
static Direction IN_OUT
          The IN_OUT direction specifies that the access point accepts both set and get access.
static Direction OUT
          The OUT direction represents a data mapping evaluation from the engine or application to the data.
 
Method Summary
static Direction getDualValue(Direction direction)
          Factory method to get the opposite direction to the specified one.
static Direction getKey(String id)
          Translates the stringified ID into the appropriate key instance.
 boolean isCompatibleWith(Direction direction)
          Gets whether the supplied direction is compatible with this direction.
 
Methods inherited from class org.eclipse.stardust.common.StringKey
compareTo, equals, getId, getKey, getKey, getKeys, getKeys, getName, hashCode, toString
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

IN

public static final Direction IN
The IN direction represents a data mapping evaluation from the data to the engine or application. In the case of access points, the IN direction specifies that this access point accepts only set access.


OUT

public static final Direction OUT
The OUT direction represents a data mapping evaluation from the engine or application to the data. In the case of access points, the OUT direction specifies that this access point accepts only get access.


IN_OUT

public static final Direction IN_OUT
The IN_OUT direction specifies that the access point accepts both set and get access.

Method Detail

getKey

public static Direction getKey(String id)
Translates the stringified ID into the appropriate key instance.

Parameters:
id - The stringified ID to be resolved.
Returns:
The resolved key, null if no key could be resolved.

getDualValue

public static Direction getDualValue(Direction direction)
Factory method to get the opposite direction to the specified one.

Parameters:
direction - the direction to which you want to obtain the opposite.
Returns:
the opposite direction.

isCompatibleWith

public boolean isCompatibleWith(Direction direction)
Gets whether the supplied direction is compatible with this direction.

Parameters:
direction - to compare with.
Returns:
true


Copyright © 2017 Eclipse Stardust. All Rights Reserved.