Class FileHandler.Updater
java.lang.Object
org.apache.commons.configuration2.io.FileHandler.Updater
- Enclosing class:
- FileHandler
An internal class that performs all update operations of the handler's
FileLocator
in a safe way even if
there is concurrent access. This class implements anon-blocking algorithm for replacing the immutable
FileLocator
instance stored in an atomic reference by a manipulated instance. (If we already had lambdas,
this could be done without a class in a more elegant way.)-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
update()
Performs an update of the enclosing file handler'sFileLocator
object.protected abstract void
Updates the passed in builder object to apply the manipulation to be performed by thisUpdater
.
-
Constructor Details
-
Updater
private Updater()
-
-
Method Details
-
update
public void update()Performs an update of the enclosing file handler'sFileLocator
object. -
updateBuilder
Updates the passed in builder object to apply the manipulation to be performed by thisUpdater
. The builder has been setup with the former content of theFileLocator
to be manipulated.- Parameters:
builder
- the builder for creating an updatedFileLocator
-