Download presentation
Presentation is loading. Please wait.
Published byRolf Lloyd Modified over 9 years ago
1
Object-oriented tools for XML Schema JAXB (Java Architecture for XML Binding) –object connectivity for XML documents HyperJAXB –relational persistence for XML data jaxb-verification –object-level validation
2
JAXB Generates content classes based on the XML Schema Provides XML/objects exchange infrastructure –XML documents may be automatically unmarshalled into object structures –Object structures may be automatically serialized into XML
3
JAXB - Example // Load metadata object structure // from the XML document Metadata metadata = (Metadata) unmarshaller.unmarshal(document); // Serialize metadata object structure // into DOM document Document newDocument = documentBuilder.newDocument(); marshaller.marshal(metadata, newDocument);
4
HyperJAXB Provides JAXB objects with relational persistence layer Automatically generates: –Database schema –Object-relational mapping for JAXB objects
5
HyperJAXB Example – The Schema (1) Excerpt from ISO 19115 XML Schema Metadata, identification information, bounding box elements
6
HyperJAXB Example – The Generated Object Structure (2)
7
HyperJAXB Example – The Generated Database Schema (3)
8
HyperJAXB Example – The Sample XML (4) id000001 en dataset series The abstract. The purpose. planned true 11.7254223679 11.8123425682 48.3282639631 48.4438272635
9
HyperJAXB Example – The Insertion SQL (5) INSERT INTO EXGEOGRAPHICBOUNDINGBOX VALUES('...0003',true,48.4438272635,48.3282639631,11.8123425682,11.7254 223679) INSERT INTO MDIDENTIFICATION VALUES('...0002','planned','The purpose.','...0003','The abstract.') INSERT INTO MDMETADATA VALUES('...0001','id000001','en','...0002') INSERT INTO METADATA VALUES('...0001') INSERT INTO MDMETADATA_HIERARCHYLEVELINTERNAL VALUES('...0001','dataset',0) INSERT INTO MDMETADATA_HIERARCHYLEVELINTERNAL VALUES('...0001','series',1)
10
HyperJAXB – Live Demo
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.