public boolean hasInputArguments() { return getInputArguments() != null && getInputArguments().length > 0; }
public ActionArgument<S> getInputArgument(String name) { for (ActionArgument<S> arg : getInputArguments()) { if (arg.isNameOrAlias(name)) return arg; } return null; }
public ActionArgument<S> getFirstInputArgument() { if (!hasInputArguments()) throw new IllegalStateException("No input arguments: " + this); return getInputArguments()[0]; }
public void readActionInputArguments(Element actionRequestElement, ActionInvocation actionInvocation) throws ActionException { actionInvocation.setInput( readArgumentValues( actionRequestElement.getChildNodes(), actionInvocation.getAction().getInputArguments() ) ); }
protected void readActionInputArguments(XmlPullParser xpp, ActionInvocation actionInvocation) throws Exception { actionInvocation.setInput(readArgumentValues(xpp, actionInvocation.getAction().getInputArguments())); }
for (ActionArgument<LocalService> argument : actionInvocation.getAction().getInputArguments()) {
protected void writeActionInputArguments(Document d, Element actionRequestElement, ActionInvocation actionInvocation) { for (ActionArgument argument : actionInvocation.getAction().getInputArguments()) { log.fine("Writing action input argument: " + argument.getName()); String value = actionInvocation.getInput(argument) != null ? actionInvocation.getInput(argument).toString() : ""; XMLUtil.appendNewElement(d, actionRequestElement, argument.getName(), value); } }
protected ActionArgumentValue[] createDefaultValuesInput(Action action) { ActionArgument[] arguments = action.getInputArguments(); ActionArgumentValue[] defaultValues = new ActionArgumentValue[arguments.length]; for (int i = 0; i < arguments.length; i++) { // Visually, a boolean is shown by the renderer as "off", so even without invoking the editor, we need // to set its value to "off" in the model. if (Datatype.Builtin.BOOLEAN.equals(arguments[i].getDatatype().getBuiltin())) { defaultValues[i] = new ActionArgumentValue(arguments[i], false); } else { defaultValues[i] = new ActionArgumentValue(arguments[i], ""); } } return defaultValues; }
public boolean hasInputArguments() { return getInputArguments() != null && getInputArguments().length > 0; }
public ActionArgument<S> getInputArgument(String name) { for (ActionArgument<S> arg : getInputArguments()) { if (arg.isNameOrAlias(name)) return arg; } return null; }
public ActionArgument<S> getFirstInputArgument() { if (!hasInputArguments()) throw new IllegalStateException("No input arguments: " + this); return getInputArguments()[0]; }
public void readActionInputArguments(Element actionRequestElement, ActionInvocation actionInvocation) throws ActionException { actionInvocation.setInput( readArgumentValues( actionRequestElement.getChildNodes(), actionInvocation.getAction().getInputArguments() ) ); }
protected void readActionInputArguments(XmlPullParser xpp, ActionInvocation actionInvocation) throws Exception { actionInvocation.setInput(readArgumentValues(xpp, actionInvocation.getAction().getInputArguments())); }
for (ActionArgument<LocalService> argument : actionInvocation.getAction().getInputArguments()) {
protected void writeActionInputArguments(Document d, Element actionRequestElement, ActionInvocation actionInvocation) { for (ActionArgument argument : actionInvocation.getAction().getInputArguments()) { log.fine("Writing action input argument: " + argument.getName()); String value = actionInvocation.getInput(argument) != null ? actionInvocation.getInput(argument).toString() : ""; XMLUtil.appendNewElement(d, actionRequestElement, argument.getName(), value); } }
public ActionArgument<S> getInputArgument(String name) { for (ActionArgument<S> arg : getInputArguments()) { if (arg.isNameOrAlias(name)) return arg; } return null; }
public ActionArgument<S> getFirstInputArgument() { if (!hasInputArguments()) throw new IllegalStateException("No input arguments: " + this); return getInputArguments()[0]; }
public void readActionInputArguments(Element actionRequestElement, ActionInvocation actionInvocation) throws ActionException { actionInvocation.setInput( readArgumentValues( actionRequestElement.getChildNodes(), actionInvocation.getAction().getInputArguments() ) ); }
protected void readActionInputArguments(XmlPullParser xpp, ActionInvocation actionInvocation) throws Exception { actionInvocation.setInput(readArgumentValues(xpp, actionInvocation.getAction().getInputArguments())); }
protected void writeActionInputArguments(Document d, Element actionRequestElement, ActionInvocation actionInvocation) { for (ActionArgument argument : actionInvocation.getAction().getInputArguments()) { log.fine("Writing action input argument: " + argument.getName()); String value = actionInvocation.getInput(argument) != null ? actionInvocation.getInput(argument).toString() : ""; XMLUtil.appendNewElement(d, actionRequestElement, argument.getName(), value); } }