本文整理汇总了Java中com.sun.tools.internal.jxc.model.nav.ApNavigator类的典型用法代码示例。如果您正苦于以下问题:Java ApNavigator类的具体用法?Java ApNavigator怎么用?Java ApNavigator使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ApNavigator类属于com.sun.tools.internal.jxc.model.nav包,在下文中一共展示了ApNavigator类的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: bind
import com.sun.tools.internal.jxc.model.nav.ApNavigator; //导入依赖的package包/类
public J2SJAXBModel bind(
Collection<Reference> rootClasses,
Map<QName,Reference> additionalElementDecls,
String defaultNamespaceRemap,
ProcessingEnvironment env) {
ModelBuilder<TypeMirror, TypeElement, VariableElement, ExecutableElement> builder =
new ModelBuilder<TypeMirror, TypeElement, VariableElement, ExecutableElement>(
InlineAnnotationReaderImpl.theInstance,
new ApNavigator(env),
Collections.<TypeElement, TypeElement>emptyMap(),
defaultNamespaceRemap );
builder.setErrorHandler(new ErrorHandlerImpl(env.getMessager()));
for ( Reference ref : rootClasses ) {
TypeMirror t = ref.type;
XmlJavaTypeAdapter xjta = ref.annotations.getAnnotation(XmlJavaTypeAdapter.class);
XmlList xl = ref.annotations.getAnnotation(XmlList.class);
builder.getTypeInfo(new Ref<TypeMirror, TypeElement>(builder, t, xjta, xl));
}
TypeInfoSet<TypeMirror, TypeElement, VariableElement, ExecutableElement> r = builder.link();
if(r==null) return null;
if(additionalElementDecls==null)
additionalElementDecls = Collections.emptyMap();
else {
// fool proof check
for (Map.Entry<QName, ? extends Reference> e : additionalElementDecls.entrySet()) {
if(e.getKey()==null)
throw new IllegalArgumentException("nulls in additionalElementDecls");
}
}
return new JAXBModelImpl(r, builder.reader, rootClasses, new HashMap<QName, Reference>(additionalElementDecls));
}