Package org.jboss.fresh.shell.impl

Examples of org.jboss.fresh.shell.impl.HistoryItem


    String val = null;

    try {
      Iterator it = h.list().iterator();
      while(it.hasNext()) {
        HistoryItem hi = (HistoryItem) it.next();

        if(objs) {
          if(oout == null)
            oout = new BufferObjectWriter(getStdOut());
          oout.writeObject(pout);
        } else {
          StringBuffer sb = new StringBuffer();
          if(time) {
            sb.append(sdf.format(new Date(hi.getTime())));
            sb.append(" ");
          }

          if(global) {
            val = hi.getProject();
            if(val == null)
              val = "<undefined>";
            sb.append(val);
            sb.append(" ");
          }

          if(user) {
            val = hi.getUser();
            if(val == null)
              val = "<undefined>";
            sb.append(val);
            sb.append(" ");         
          }

          sb.append(hi.getCmd());
          sb.append(" ");

          if(clientInfo) {
            String vuser = hi.getUser();
            String vhost = hi.getHost();
            String vapp = hi.getApp();
            if(vuser != null || vhost != null || vapp == null) {

              if(vuser == null) vuser = "<unknown>";
              if(vhost == null) vhost = "<unknown>";
              if(vapp == null) vapp = "<unknown>";
View Full Code Here

TOP

Related Classes of org.jboss.fresh.shell.impl.HistoryItem

Copyright © 2018 www.massapicom. 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.