This document lists changes made to the Editor Guarded Sections API .
Fuller descriptions of all changes can be found below (follow links).
Not all deprecations are listed here, assuming that the deprecated APIs continue to essentially work. For a full deprecation list, please consult the Javadoc.
These API specification versions may be used to indicate that a module requires a certain API feature in order to function. For example, if you see here a feature you need which is labelled 1.20, your manifest should contain in its main attributes the line:
OpenIDE-Module-Module-Dependencies: org.netbeans.modules.editor.guards/1 > 1.20
org.netbeans.api.editor.guards.DocumentGuards
org.netbeans.spi.editor.guards.GuardedRegionMarker
org.netbeans.api.editor.guards.GuardedSectionManager
GuardedSectionManager
; made by: sdedic
GuardedRegionMarker
DocumentGuards
; made by: sdedic; issues:
#244679
APIs exposed and actually used on GuardedDocument in editor.lib
module is now declared in Editor Guarded Sections.
Clients may depend on Guarded Sections instead of on fading-away editor.lib module.
Dependency on openide.text
eliminated, new SPI GuardedRegionMarker
is added for Documents that are willing to style their contents according to guarded areas.
When this option is set, setting the content of a GuardedSection will pass the data through the given guarded writer and back through the given guarded reader, to ensure the result is the same as if it would be read from the disk.
Note that this new mode is not fully compatible with the original mode, e.g. all the set methods of all the GuardedSection classes will throw IllegalStateException if invoked inside the write&read part.
java.nio.Charset
instance
than as a plain encoding name.
Reader createGuardedReader(InputStream stream, String encoding) throws UnsupportedEncodingException
replaced with
Reader createGuardedReader(InputStream stream, Charset charset)
Writer createGuardedWriter(OutputStream stream, String encoding) throws UnsupportedEncodingException
replaced with
Reader createGuardedReader(InputStream stream, Charset charset)