TibrvMsgView
Class
Declaration
class com.tibco.tibrv.TibrvMsgView
extends java.lang.Object
Purpose
View the fields of Rendezvous messages.
Remarks
A message view is a snapshot copy of a TIBCO Rendezvous message. All the data resides within the Java environment (not in the C environment). A view provides read-only access to field data of an inbound message.
To create a new view, see TibrvMsgView.extract().
Efficiency
When a callback method gets 10 or more fields, then a message view is usually more efficient than accessing the fields of the C message. Extracting a message view accesses the native C message only once, instead of repeatedly (with every get call).
When a callback method gets fewer than 10 fields, then getting fields from the native C message is usually more efficient.
Restrictions
TibrvMsgView and its methods are available only in the JNI preferred implementation. They are not available in the JNI backward compatibility implementation, nor in the pure Java implementation.
|
Method |
Description |
|
Message View Life Cycle and Properties
|
|
|
Fields
|
|
|
Get the value of a specified field from a message view snapshot. |
|
|
Get the value of a field from a message view snapshot as a scalar value. |
|
|
Inherited Methods |
|
|
Using a Message View
try {
TibrvMsgView view = TibrvMsgView.extract(message);
for (int i = 1; i <= this.fieldCount; i++) {
view.get(i);
...
}
} catch (final TibrvException e) {
e.printStackTrace();
System.exit(0);
}