/** * This method is used to extract the annotations associated with * the type. Annotations extracted include the <code>Root</code> * annotation and the <code>Namespace</code> annotation as well as * other annotations that are used to describe the type. * * @param type this is the type to extract the annotations from */ private void extract(Class type) { for(Annotation label : labels) { if(label instanceof Namespace) { namespace(label); } if(label instanceof NamespaceList) { scope(label); } if(label instanceof Root) { root(label); } if(label instanceof Order) { order(label); } if(label instanceof Default) { access(label); } } }
/** * This returns the <code>NamespaceList</code> annotation that was * declared on the type. A list of namespaces are used to simply * declare the namespaces without specifically making the type * belong to any of the declared namespaces. * * @return this returns the namespace declarations, if any */ public NamespaceList getNamespaceList() { return detail.getNamespaceList(); }
/** * This returns the <code>NamespaceList</code> annotation that was * declared on the type. A list of namespaces are used to simply * declare the namespaces without specifically making the type * belong to any of the declared namespaces. * * @return this returns the namespace declarations, if any */ public NamespaceList getNamespaceList() { return declaration; }
/** * This is use to scan for <code>NamespaceList</code> annotations * on the class. Once a namespace list has been located then it is * used to populate the internal namespace decorator. This can then * be used to decorate any output node that requires it. * * @param label the XML annotation to scan for namespace lists */ private void scope(Annotation label) { if(label != null) { declaration = (NamespaceList)label; } }
/** * This returns the <code>NamespaceList</code> annotation that was * declared on the type. A list of namespaces are used to simply * declare the namespaces without specifically making the type * belong to any of the declared namespaces. * * @return this returns the namespace declarations, if any */ NamespaceList getNamespaceList();