@Override
 public <A extends XmlAdapter> A getAdapter(Class<A> type) {
   if (type == null) throw new IllegalArgumentException();
   if (coordinator.containsAdapter(type))
     // so as not to create a new instance when this method is called
     return coordinator.getAdapter(type);
   else return null;
 }
Esempio n. 2
0
 @Override
 public <A extends XmlAdapter> A getAdapter(Class<A> type) {
   if (type == null) {
     throw new IllegalArgumentException();
   }
   if (coordinator.containsAdapter(type)) {
     return coordinator.getAdapter(type);
   } else {
     return null;
   }
 }