Package com.caucho.util

Examples of com.caucho.util.CharBuffer.indexOf()


    if (host == null) {
      InetAddress addr = getConnection().getRemoteAddress();
      return addr.getHostName();
    }

    int p = host.indexOf(':');
    if (p >= 0)
      return host.substring(0, p);
    else
      return host.toString();
  }
View Full Code Here


      Global global = Global.getGlobalProto();
      LineMap lineMap = global != null ? global.getLineMap(className) : null;
      String line = file.toString();

      if (lineMap != null) {
        p = file.indexOf(':');
        if (p > 0) {
          try {
            String filename = file.substring(0, p);
            int lineNo = Integer.parseInt(file.substring(p + 1));
            line = lineMap.convertLine(filename, lineNo);
View Full Code Here

      // into appropriate ones

      CharBuffer cb = new CharBuffer(_query);

      // take .html out
      int di = cb.indexOf(".html");
      if (di > -1)
        cb.delete(di,di+5);


      // take all (...) out
View Full Code Here

      if (di > -1)
        cb.delete(di,di+5);


      // take all (...) out
      while  ( (di = cb.indexOf('(')) > -1) {
        int di2 = cb.indexOf(')',di);
        if (di2 > di)
          cb.delete(di,di2+1);
      }
View Full Code Here

        cb.delete(di,di+5);


      // take all (...) out
      while  ( (di = cb.indexOf('(')) > -1) {
        int di2 = cb.indexOf(')',di);
        if (di2 > di)
          cb.delete(di,di2+1);
      }

      for (int i = 0; i < cb.length(); i++) {
View Full Code Here

      parseDescr = "parsing href, looking for next \"";
      i = readToAndEat(cb,i,'\"',t);
      while (t.startsWith("../"))
        t.delete(0,3);

      int ai = t.indexOf('#');
      if (ai > -1) {
        path = t.substring(0,ai);
        anchor = t.substring(ai + 1);
      } else {
        path = t.toString();
View Full Code Here

    if (host == null) {
      InetAddress addr = getConnection().getRemoteAddress();
      return addr.getHostName();
    }

    int p = host.indexOf(':');
    if (p >= 0)
      return host.substring(0, p);
    else
      return host.toString();
  }
View Full Code Here

      Global global = Global.getGlobalProto();
      LineMap lineMap = global != null ? global.getLineMap(className) : null;
      String line = file.toString();

      if (lineMap != null) {
        p = file.indexOf(':');
        if (p > 0) {
          try {
            String filename = file.substring(0, p);
            int lineNo = Integer.parseInt(file.substring(p + 1));
            line = lineMap.convertLine(filename, lineNo);
View Full Code Here

      // into appropriate ones

      CharBuffer cb = new CharBuffer(_query);

      // take .html out
      int di = cb.indexOf(".html");
      if (di > -1)
        cb.delete(di,di+5);


      // take all (...) out
View Full Code Here

      if (di > -1)
        cb.delete(di,di+5);


      // take all (...) out
      while  ( (di = cb.indexOf('(')) > -1) {
        int di2 = cb.indexOf(')',di);
        if (di2 > di)
          cb.delete(di,di2+1);
      }
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.