Package com.caucho.util

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


    IntMap messages = new IntMap();

    try {
      while (true) {
        do {
          line.clear();
          if (! is.readLine(line)) {
            if (ws != null)
              ws.println("</message>");
            return false;
          }
View Full Code Here


        String from = null;
        String id = null;
        String references = null;

        do {
          line.clear();
          if (! is.readLine(line))
            return false;
          if (line.length() == 0)
            break;
View Full Code Here

    String result;
   
    if (readLine(cb, true)) {
      result = cb.toString();
      cb.clear();
    }
    else if (cb.length() == 0)
      result = null;
    else {
      result = cb.toString();
View Full Code Here

    }
    else if (cb.length() == 0)
      result = null;
    else {
      result = cb.toString();
      cb.clear();
    }
   
    return result;
  }
View Full Code Here

                      badChar(ch)));
    }

    String name = cb.toString();

    cb.clear();
    parseVelocityName(cb);

    if (cb.length() == 0) {
      throw error(L.l("Expected 'in' for #foreach at `{0}'.  The velocity-style #foreach syntax is: #foreach ($a in expr)",
                      badChar(ch)));
View Full Code Here

    if (name.startsWith("$"))
      name = name.substring(1);

    _jspBuilder.attribute(new QName("var"), name);

    cb.clear();
    parseVelocityExpr(cb, ')');
    String expr = cb.close();

    if (expr.indexOf("..") > 0) {
      int h = 0;
View Full Code Here

    boolean hasJavaScript = false;
    int i = 0;
    while (i < array.length) {
      fun.clear();
      file.clear();
      int start = i;
      int end;
      for (end = i; end < array.length && array[end] != '\n'; end++) {
      }
View Full Code Here

    while (i < len && (ch = localeName.charAt(i++)) != '-' && ch != '_') {
      sb.append(ch);
    }

    language = sb.toString();
    sb.clear();

    while (i < len && (ch = localeName.charAt(i)) != '.' && ch != '@') {
      sb.append(ch);

      i++;
View Full Code Here

    if (ch == '.')
      i++;

    country = sb.toString();
    sb.clear();

    while (i < len && (ch = localeName.charAt(i)) != '@') {
      sb.append(ch);

      i++;
View Full Code Here

      cb.append(ch);

    String language = cb.toString();

    if (ch == '_' || ch == '-') {
      cb.clear();

      for (i++; i < len && (ch = value.charAt(i)) != '_' && ch != '-'; i++)
        cb.append(ch);

      String country = cb.toString();
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.