Skip to content

Latest commit

 

History

History
137 lines (113 loc) · 6.29 KB

File metadata and controls

137 lines (113 loc) · 6.29 KB

Changelog

2.0.1 - 2026-04-16

Changed

  • Updated to object-copier 1.2.0.

2.0.0 - 2026-03-31

Added

  • Added a comprehensive User Guide covering the core concepts of xml-objects and providing examples to help you get started.
  • Added a dependency on the new standalone object-copier library, which supersedes the built-in copy infrastructure that was previously part of xml-objects.

Changed

  • Breaking: The CopyBuilder class and the entire util.copy package have been removed. The object-copier library is the designated replacement, providing a significantly more powerful and flexible copy framework.
    • The central entry point is now the Copier class (package org.xmlobjects.copy), which is created via CopierBuilder using CopierBuilder.newCopier() for a default instance or CopierBuilder.newInstance() for a customized one.
    • Copyable, CopyContext, and TypeCloner have been moved to the org.xmlobjects.copy package of the object-copier library. The semantics of Copyable have changed: shallowCopy/deepCopy are replaced by shallowCopyTo/deepCopyTo (accepting a CopyContext) and newInstance.
    • failOnError has been removed. Errors are always propagated as CopyException (unchecked).
    • See the object-copier documentation for details on the new capabilities. In particular, the CopySession feature now enables maintaining object identity across multiple copy operations.

1.3.0 - 2025-12-29

Changed

  • Made CopyBuilder thread-safe for concurrent use.
  • Removed Serializable from Copyable. Implementations must declare serialization explicitly now.
  • Removed withClone and withSelfCopy from CopyBuilder.
  • Updated Copyable.shallowCopy and Copyable.deepCopy to accept a CopyContext, which now provides the former withClone and withSelfCopy functionality.
  • Changed CopyBuilder.failOnError to be true by default.

Fixed

  • CopyBuilder now invokes Copyable.shallowCopy for the initial object being copied, when provided.

1.2.0 - 2025-11-20

Changed

  • Introduced TextContent.ABSENT sentinel to represent missing content, replacing the previous TextContent.EMPTY. New API methods:
    • TextContent absent() — returns an absent instance (ignored during serialization).
    • boolean isAbsent()true if content is absent.
    • boolean isPresent()true if content exists.
    • boolean isEmpty()true if content exists but is an empty string.
  • Added getAsXOrElse and getAsXOrElseGet methods to TextContent to provide a default value when parsing into the expected type fails: OrElse takes a direct value, OrElseGet takes a Supplier for lazy evaluation.

Fixed

  • Fixed XMLReader.getTextContent() to return TextContent.ABSENT if the reader is not at a start element.
  • Fixed TextContent.collapse() to no longer produce strings starting with '\0'.
  • Corrected typo in getAsCalendar and getAsCalendarList methods of TextContent.

1.1.6 - 2025-09-27

Changed

  • Updated xsom to 4.0.6.

1.1.5 - 2025-03-02

Fixed

  • Removed unnecessary use of WeakReference in XMLReader.

1.1.4 - 2025-01-19

Changed

  • Updated classindex to 3.13.1.
  • Updated Gradle to 8.12.

1.1.2 - 2024-12-01

Added

  • Added method getObjectTypes to XMLObjects class to get supported object types with their XML element name mappings.

1.1.1 - 2024-07-05

Fixed

  • Avoid unnecessary conversion to OffsetDateTime in TextContent.

1.1.0 - 2024-01-29

Changed

  • Breaking: Java 17 is now the minimum required version for using xml-objects.

Fixed

  • Unknown XML content is mapped to DOM elements using the default DOM transformer to avoid issues with external XML libraries.

1.0.4 - 2023-11-03

Added

  • Added getEncoding method to XMLReader, which returns the input encoding if known or null if unknown.
  • Added methods to build default factories to SecureXMLProcessors and XMLReaderFactory.
  • Added useAsFragment method to SAXBuffer to enable writing of XML fragments.

Fixed

  • Fixed CopyBuilder to avoid deep-copying those parents of Child objects that are outside the hierarchy of the object to be copied.

1.0.3 - 2023-04-04

Added

  • Added support for providing an XML factory when creating an instance of XMLReaderFactory and SchemaHandler.
  • SecureXMLProcessors now allows for obtaining an XML factory from a class name and a class loader. This gives more control to the application as it can specify which implementation should be loaded.

Changed

  • Updated xsom to 4.0.2.

1.0.2 - 2023-02-06

Changed

  • Updated xsom to 4.0.1.

1.0.1 - 2022-09-08

Changed

  • SAXWriter now uses the newline character (\n) for line breaks instead of the system-specific line separator.

Fixed

  • Fixed DepthXMLStreamReader to read schema documents specified by a Windows path in xsi:schemaLocation.

1.0.0 - 2022-08-20

This is the initial release of xml-objects.