8071678: javax.script.ScriptContext setAttribute method should clarify behavior when GLOBAL_SCOPE is used and global scope object is null
Reviewed-by: jlaskey, hannesw
This commit is contained in:
parent
9852310517
commit
16fadae534
@ -85,7 +85,8 @@ public interface ScriptContext {
|
||||
public Bindings getBindings(int scope);
|
||||
|
||||
/**
|
||||
* Sets the value of an attribute in a given scope.
|
||||
* Sets the value of an attribute in a given scope. If the scope is <code>GLOBAL_SCOPE</code>
|
||||
* and no Bindings is set for <code>GLOBAL_SCOPE</code>, then setAttribute call is a no-op.
|
||||
*
|
||||
* @param name The name of the attribute to set
|
||||
* @param value The value of the attribute
|
||||
|
@ -213,7 +213,8 @@ public class SimpleScriptContext implements ScriptContext {
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the value of an attribute in a given scope.
|
||||
* Sets the value of an attribute in a given scope. If the scope is <code>GLOBAL_SCOPE</code>
|
||||
* and no Bindings is set for <code>GLOBAL_SCOPE</code>, then setAttribute call is a no-op.
|
||||
*
|
||||
* @param name The name of the attribute to set
|
||||
* @param value The value of the attribute
|
||||
|
Loading…
x
Reference in New Issue
Block a user