asciidoctor / asciidoctorj

:coffee: Java bindings for Asciidoctor. Asciidoctor on the JVM!
http://asciidoctor.org
Apache License 2.0
625 stars 173 forks source link

Add setContext function #1253

Closed RayOffiah closed 9 months ago

RayOffiah commented 9 months ago

Added unit test for changing the context: ContextChangeTest.java (#1250) Reformatting the setContext function. Added entry to CHANGELOG.adoc (cherry picked from commit 43154994a316728363286bd42894536fa9af6b15)

Thank you for opening a pull request and contributing to AsciidoctorJ!

Please take a bit of time giving some details about your pull request:

Kind of change

Description

What is the goal of this pull request? Add setContext function to ContentNode

How does it achieve that? By adding a new function and unit test

Are there any alternative ways to implement this? Probably not

Are there any implications of this pull request? Anything a user must know?

Used a cherry-pick to bring the function over; there are a lot of @deprecated statements that have appeared too. Worth checking before rebasing.

Issue

If this PR fixes an open issue, please add a line of the form:

Fixes #Issue

Release notes

Please add a corresponding entry to the file CHANGELOG.adoc