Example
Here is an example of creating a DataView definition and handling DataViewException events:
using com.apama.dataview.DataViewAddDefinition; 
using com.apama.dataview.DataViewException; 
... 
DataViewAddDefinition add := new DataViewAddDefinition; 
add.dvName := "Weather"; 
add.dvDisplayName := "Weather"; 
add.fieldNames := ["location","temperature","humidity","visibility"]; 
add.fieldTypes := ["string","integer","integer","integer"]; 
add.keyFields := ["location"]; 
route add; 
DataViewException dvException; 
on all DataViewException(): dvException { 
log "*** Weather monitor error: " + 
   dvException.toString() at ERROR; 
}