com.codestreet.selector.rv
Class ValueProvider

java.lang.Object
  extended bycom.codestreet.selector.rv.ValueProvider
All Implemented Interfaces:
IValueProvider

public class ValueProvider
extends java.lang.Object
implements IValueProvider

/** Value provider for TIBCO/Rendezvous. This implementation allows values to be extracted from Rendezvous messages using a dot notation.

For example, .order.quantity would access the quantity field of the nested sub-message field order, if it exists. If the field does not exist, it returns null.

The reason for requiring a leading dot before field names - includign top level fields - is to provide comptibility between the Rendezvous and JMS value provides.

Author:
Jawaid Hakim., Jawaid Hakim.

Method Summary
 java.lang.Object getValue(java.lang.Object identifier, java.lang.Object correlation)
          Get the value for the specified identifier.
static ValueProvider valueOf(com.tibco.tibrv.TibrvMsg msg)
          Factory method.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

valueOf

public static ValueProvider valueOf(com.tibco.tibrv.TibrvMsg msg)
Factory method.

Parameters:
msg - Message to extract values from.
Returns:
Instance.

getValue

public java.lang.Object getValue(java.lang.Object identifier,
                                 java.lang.Object correlation)
Get the value for the specified identifier.

Specified by:
getValue in interface IValueProvider
Parameters:
identifier - Field identifier.
correlation - Application correlation data. May be null.
Returns:
Value of the specified identifier. Returns null if the value of the identifier is not found.
See Also:
NumericValue


Copyright © 2002-2006 CodeStreet. All Rights Reserved.