Release Notes

This page provides information about the latest releases of Office-stamper, including new features, bug fixes, and other changes.

Latest Release

v3.1.0

API Consolidation

  • Public API: Moved PlaceholderHooker, CommentHooker, and HookRemover to the pro.verron.officestamper.api package for better accessibility and consistent extension points.
  • Experimental Features: All experimental stamper implementations are now located in the pro.verron.officestamper.experimental package.

Cleanup & Refinement

  • Internal streamlining: Removed several internal utility classes (SectionUtil, ParagraphCollector, etc.) to simplify the engine’s architecture.
  • Logging: Switched many verbose debug messages to trace level to reduce noise during normal development.
  • Post-processing: Replaced cleanTags with the more powerful Postprocessors.removeTags(String).

Previous Releases

v3.0.0

Core Overhaul

  • Processing model overhaul: The engine now iterates "hooks" (placeholders, inline processors, comments) strictly in document order.
  • New Hook concept: Each placeholder or comment is treated as a Hook. The iterator walks hooks one by one, allowing for more predictable results.
  • Hierarchical Scopes: ContextTree resolves placeholders along the current branch; unresolved values bubble up to parent scopes.
  • Simplified Comment Processors: Processors are created per hook and executed once, with a fresh ProcessorContext.

API Changes

  • Moved API classes: PlaceholderHooker, CommentHooker, and HookRemover are now public in the pro.verron.officestamper.api package.
  • Renamed classes: ContextDependent renamed to Hook.
  • Standard configuration: OfficeStamperConfigurations.standard() now includes recommended preprocessors and post-processors by default.
  • Evaluation Context: EvaluationContextConfigurer replaced by EvaluationContextFactory.
  • Insert API: Introduced a new Insert API for more flexible content insertion.

Dependencies

  • Upgrade Java version to 25.
  • Spring dependencies bumped to 7.0.2 (when available, currently tracking latest).

For information about previous releases, see the full release notes on GitHub.

Upgrading

From v3.0.0 to v3.1.0

  • Package Moves: Update your imports for PlaceholderHooker, CommentHooker, and HookRemover to pro.verron.officestamper.api.
  • Experimental API: If you used ExperimentalStampers, it has moved to pro.verron.officestamper.experimental.
  • Post-processing: Replace any usage of cleanTags with Postprocessors.removeTags(String).
  • Internal Classes: If you were using internal classes like SectionUtil, they have been removed. You will need to implement this logic yourself if needed.

From v2.9.0 to v3.0.0

  • Java 25 required: Ensure your project is running on Java 25 or higher.
  • API Package: If you were using PlaceholderHooker, CommentHooker, or HookRemover from internal packages, update your imports to pro.verron.officestamper.api.
  • Hooks: The engine now uses a "hook" based processing. If you have custom processors, they now receive a ProcessorContext.
  • Standard Configuration: OfficeStamperConfigurations.standard() now includes preprocessing by default. You may no longer need standardWithPreprocessing().

From v2.8.x to v2.9.0

  • MAY (unlikely) BREAK some formatting after a replaceWordWith comment.
  • Update your dependencies to the latest versions.

From v2.7.x to v2.8.0

  • No breaking changes.
  • Update your dependencies to the latest versions.

From v2.6.x to v2.7.0

  • If you were using Paragraph#getComment(), you’ll need to update your code to handle a Collection instead of an Optional.
  • Update your dependencies to the latest versions.

From v2.5.x to v2.6.x

  • No breaking changes.
  • Update your dependencies to the latest versions.

From v2.4.x to v2.5.x

  • No breaking changes.
  • Update your dependencies to the latest versions.

Reporting Issues

If you encounter any issues with a release, report them on the GitHub Issues page.

Next Steps