Code example for SimpleBindings

 * Utilities for script evaluation 
public class Utils { 
    private static final String EXTENSION = "js";
    public static final Bindings EMPTY_BINDINGS = new SimpleBindings(Collections.<String, Object>emptyMap());
    public static SlingScriptHelper getHelper(Bindings bindings) {
        return (SlingScriptHelper) bindings.get(SlingBindings.SLING);
    public static boolean isJsScript(String identifier) {
        String extension = StringUtils.substringAfterLast(identifier, ".");
        return EXTENSION.equalsIgnoreCase(extension);
Connect your IDE to all the code out there  Get Codota for Java