Skip to main content

XML Mapping Files

  • Chapter
  • First Online:
Pro Jakarta Persistence in Jakarta EE 10
  • 860 Accesses

Abstract

Back in the early days, after the release of Java SE 5, there was a quiet, and sometimes not-so-quiet, debate about whether annotations were better or worse than XML. The defenders of annotations vigorously proclaimed how annotations are so much simpler and provide in-lined metadata that is co-located with the code that it is describing. The claim was that this avoids the need to replicate the information that is inherent in the source code context of where the metadata applies. The XML proponents then retorted that annotations unnecessarily couple the metadata to the code and that changes to metadata should not require changes to the source code.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Subscribe and save

Springer+
from €37.37 /Month
  • Starting from 10 chapters or articles per month
  • Access and download chapters and articles from more than 300k books and 2,500 journals
  • Cancel anytime
View plans

Buy Now

eBook
EUR 17.99
Price includes VAT (Netherlands)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
EUR 70.84
Price includes VAT (Netherlands)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Similar content being viewed by others

Notes

  1. 1.

    Technically, there is a description element in many of the elements, just as there are in most of the standard schemas in Jakarta EE, but they have little functional value and will not be mentioned here. They might be of some use to tools that parse XML schemas and use the descriptions for tooltips and similar actions.

  2. 2.

    It is possible, and even probable, that vendors will process the mapping files in the order that they are listed, but this is neither required nor standardized.

  3. 3.

    Some have argued that these kinds of tuning exercises are precisely why XML should be used to begin with.

  4. 4.

    The provider may pick one at random or throw an exception at startup time and disallow it altogether.

Author information

Authors and Affiliations

Authors

Rights and permissions

Reprints and permissions

Copyright information

© 2022 The Author(s), under exclusive license to APress Media, LLC, part of Springer Nature

About this chapter

Check for updates. Verify currency and authenticity via CrossMark

Cite this chapter

Jungmann, L., Keith, M., Schincariol, M., Nardone, M. (2022). XML Mapping Files. In: Pro Jakarta Persistence in Jakarta EE 10. Apress, Berkeley, CA. https://doi.org/10.1007/978-1-4842-7443-9_13

Download citation

Publish with us

Policies and ethics