rg.setPriority((short)10) ;
ArrayList<RouteRecord> routeRecordList = new ArrayList<RouteRecord>() ;
//Add 2 route records, alternatively NAPTRs could also be added
RouteRecord rr1 = new RouteRecord() ;
rr1.setOrganizationName("rgtest1") ;
rr1.setRouteRecordName("rgtest_rr1") ;
rr1.setPriority(Short.valueOf("5")) ;
routeRecordList.add(rr1) ;
RouteRecord rr2 = new RouteRecord() ;
rr2.setOrganizationName("rgtest1") ;
rr2.setRouteRecordName("rgtest_rr2") ;
rr2.setPriority(Short.valueOf("6")) ;
routeRecordList.add(rr2) ;
// set RouteRecords
rg.setRouteRecordList(routeRecordList) ;