Package org.apache.sling.scripting.core
Class ScriptNameAwareReader
java.lang.Object
java.io.Reader
java.io.FilterReader
org.apache.sling.scripting.core.ScriptNameAwareReader
- All Implemented Interfaces:
Closeable
,AutoCloseable
,Readable
,ScriptNameAware
The
ScriptNameAwareReader
is a FilterReader
marked with the ScriptNameAware
interface. This reader allows
retrieving the contained script's name.-
Field Summary
Fields inherited from class java.io.FilterReader
in
-
Constructor Summary
ConstructorDescriptionScriptNameAwareReader
(Reader in, String scriptName) Creates aScriptNameAwareReader
based on anotherReader
. -
Method Summary
Modifier and TypeMethodDescriptionReturns the name of the script provided by a markedReader
implementation.Methods inherited from class java.io.FilterReader
close, mark, markSupported, read, read, ready, reset, skip
Methods inherited from class java.io.Reader
nullReader, read, read, transferTo
-
Constructor Details
-
Method Details
-
getScriptName
Description copied from interface:ScriptNameAware
Returns the name of the script provided by a markedReader
implementation.- Specified by:
getScriptName
in interfaceScriptNameAware
- Returns:
- the script's name
-