use of org.eclipse.persistence.testing.jaxb.idresolver.MyIDResolver in project eclipselink by eclipse-ee4j.
the class PropertyTestCases method testUnmarshallerIdResolver.
public void testUnmarshallerIdResolver() throws Exception {
String SUN_ID_RESOLVER = "org.glassfish.jaxb.IDResolver";
String SUN_JSE_ID_RESOLVER = "com.sun.xml.internal.bind.IDResolver";
IDResolver resolver = new MyIDResolver();
u.setProperty(UnmarshallerProperties.ID_RESOLVER, resolver);
assertEquals(resolver, u.getProperty(UnmarshallerProperties.ID_RESOLVER));
Object nonELResolver = new NonELIDResolver();
u.setProperty(SUN_ID_RESOLVER, nonELResolver);
assertEquals(nonELResolver, u.getProperty(SUN_ID_RESOLVER));
u.setProperty(SUN_JSE_ID_RESOLVER, nonELResolver);
assertEquals(nonELResolver, u.getProperty(SUN_JSE_ID_RESOLVER));
u.setProperty(SUN_JSE_ID_RESOLVER, null);
assertNull(u.getProperty(SUN_JSE_ID_RESOLVER));
}
Aggregations