1 package org.kohsuke.stapler.jelly.groovy; 2 3 import groovy.lang.Binding; 4 import org.apache.commons.jelly.JellyContext; 5 import org.apache.commons.jelly.XMLOutput; 6 7 12 public class JellyBinding extends Binding { 13 private final JellyContext context; 14 15 private final XMLOutput out; 16 17 public JellyBinding(JellyContext context, XMLOutput out) { 18 this.context = context; 19 this.out = out; 20 setProperty("output",out); 21 } 22 23 public Object getVariable(String name) { 24 return context.getVariable(name); 25 } 26 27 public void setVariable(String name, Object value) { 28 context.setVariable(name,value); 29 } 30 } 31 | Popular Tags |