Annox Core

Annox is an open source project which allows you to read arbitrary Java annotations from XML resources. JAXB users may be interested in Annox annotation reader for JAXB RI which allows you to define JAXB Java/XML mappings in XML resources (instead of annotations).

License

License

Categories

Categories

Net
GroupId

GroupId

org.jvnet.annox
ArtifactId

ArtifactId

annox
Last Version

Last Version

1.0.2
Release Date

Release Date

Type

Type

jar
Description

Description

Annox Core
Annox is an open source project which allows you to read arbitrary Java annotations from XML resources. JAXB users may be interested in Annox annotation reader for JAXB RI which allows you to define JAXB Java/XML mappings in XML resources (instead of annotations).

Download annox

How to add to project

<!-- https://jarcasting.com/artifacts/org.jvnet.annox/annox/ -->
<dependency>
    <groupId>org.jvnet.annox</groupId>
    <artifactId>annox</artifactId>
    <version>1.0.2</version>
</dependency>
// https://jarcasting.com/artifacts/org.jvnet.annox/annox/
implementation 'org.jvnet.annox:annox:1.0.2'
// https://jarcasting.com/artifacts/org.jvnet.annox/annox/
implementation ("org.jvnet.annox:annox:1.0.2")
'org.jvnet.annox:annox:jar:1.0.2'
<dependency org="org.jvnet.annox" name="annox" rev="1.0.2">
  <artifact name="annox" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.jvnet.annox', module='annox', version='1.0.2')
)
libraryDependencies += "org.jvnet.annox" % "annox" % "1.0.2"
[org.jvnet.annox/annox "1.0.2"]

Dependencies

compile (3)

Group / Artifact Type Version
org.apache.commons : commons-lang3 jar 3.2.1
commons-io : commons-io jar 2.4
com.google.code.javaparser : javaparser jar 1.0.11

provided (1)

Group / Artifact Type Version
com.sun.xml.bind : jaxb-impl jar 2.2.7

test (3)

Group / Artifact Type Version
org.hibernate : hibernate-search jar 3.0.0.GA
javax.transaction : jta jar 1.1
junit : junit jar 4.11

Project Modules

There are no modules declared in this project.

Annox

Parse Java annotations from text or XML resources.

		// Parse annotation from the string
		XAnnotation<XmlRootElement> xannotation =
			(XAnnotation<XmlRootElement>) XAnnotationParser.INSTANCE.parse
				("@javax.xml.bind.annotation.XmlRootElement(name=\"foo\")");

		// Create an instance of the annotation 
		XmlRootElement xmlRootElement = xannotation.getResult();
		assertEquals("foo", xmlRootElement.name());
		assertEquals("##default", xmlRootElement.namespace());
		
		// Analyze the structure of the annotation
		assertEquals(String.class, xannotation.getFieldsMap().get("name").getType());
		assertEquals("##default", xannotation.getFieldsMap().get("namespace").getResult());

Versions

Version
1.0.2
1.0.1
1.0.0
0.5.1
0.5.0
0.4.4
0.4.3
0.4.2
0.4.1
0.4
0.3
0.2.GA
0.2.RC1
0.1