Examples of PipeLineClosure


Examples of org.crsh.lang.impl.groovy.closure.PipeLineClosure

    }
  }

  public final Object getProperty(String property) {
    if (context instanceof InvocationContext<?>) {
      PipeLineClosure ret = Helper.resolveProperty((InvocationContext)context, property);
      if (ret != null) {
        return ret;
      }
    }
    try {
View Full Code Here

Examples of org.crsh.lang.impl.groovy.closure.PipeLineClosure

    } else {
      if (session != null) {
        try {
          Command<?> cmd = session.getCommand(name);
          if (cmd != null) {
            return new PipeLineClosure(new InvocationContextImpl<Object>(proxy), name, cmd);
          }
        } catch (CommandException ignore) {
          // Really ?
        }
        return super.getVariable(name);
View Full Code Here

Examples of org.crsh.lang.impl.groovy.closure.PipeLineClosure

    CRaSH crash = (CRaSH)context.getSession().get("crash");
    if (crash != null) {
      try {
        Command<?> cmd = crash.getCommand(property);
        if (cmd != null) {
          return new PipeLineClosure(context, property, cmd);
        } else {
          return null;
        }
      } catch (CommandException e) {
        throw new InvokerInvocationException(e);
View Full Code Here

Examples of org.crsh.lang.impl.groovy.closure.PipeLineClosure

      }
      if (cmd != null) {
        return new SafeCallable() {
          @Override
          public Object call() {
            PipeLineClosure closure = new PipeLineClosure(context, name, cmd);
            return closure.call((Object[])args);
          }
        };
      }
    }
    return null;
View Full Code Here

Examples of org.crsh.lang.impl.groovy.closure.PipeLineClosure

    if ("out".equals(property)) {
      return ((InvocationContext<?>)context).getWriter();
    } else if ("context".equals(property)) {
      return context;
    } else {
      PipeLineClosure ret = Helper.resolveProperty(context, property);
      if (ret != null) {
        return ret;
      }
      try {
        return super.getProperty(property);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.