Package com.aptana.shared_core.string

Examples of com.aptana.shared_core.string.FastStringBuffer.clear()


                                //it is a valid python file
                                if (i % 15 == 0) {
                                    if (monitor.isCanceled()) {
                                        return null;
                                    }
                                    buffer.clear();
                                    monitor.setTaskName(buffer.append("Found in ").append(zipFileName)
                                            .append(" module ").append(name).toString());
                                    monitor.worked(1);
                                }
View Full Code Here


                    //Fallthrough

                case '\n':
                    //Note that we don't add the \r nor \n to the memo (but we clear it if the  line did not end with a \).
                    if (lineMemo.length() > 0 && lineMemo.lastChar() != '\\') {
                        lineMemo.clear();
                    }
                    break;

                default:
                    if (lineMemo.length() == 0) {
View Full Code Here

                String lowerImportRep = importRep.toLowerCase();
                if (!lowerImportRep.startsWith(lowerQual)) {
                    continue;
                }

                displayString.clear();
                displayString.append(importRep);

                String packageName = strings[0];
                if (packageName.length() > 0) {
                    if (addAutoImport) {
View Full Code Here

                    String lowerImportRep = importRep.toLowerCase();
                    if (!lowerImportRep.startsWith(lowerQual) || importedNames.contains(importRep)) {
                        continue;
                    }

                    displayString.clear();
                    displayString.append(importRep);

                    String packageName = strings[0];
                    if (packageName.length() > 0) {
                        if (addAutoImport) {
View Full Code Here

                            //it's not an operator, but vararg. kwarg or list expansion
                        }
                        if (Character.isJavaIdentifierPart(localC)) {
                            //ok, there's a chance that it can be an operator, but we still have to check
                            //the chance that it's a wild import
                            tempBuf.clear();
                            while (Character.isJavaIdentifierPart(localC)) {
                                tempBuf.append(localC);
                                j--;
                                if (j < 0) {
                                    break; //break while
View Full Code Here

                case '-':

                    if (c == '-' || c == '+') { // could also be *

                        //handle exponentials correctly: e.g.: 1e-6 cannot have a space
                        tempBuf.clear();
                        boolean started = false;

                        for (int j = buf.length() - 1;; j--) {
                            if (j < 0) {
                                break;
View Full Code Here

                    } catch (Exception e) {
                        Log.log(e);
                    }
                }

                temp = temp.clear();
                if (def.value != null) {
                    if (astToPrint instanceof FunctionDef) {
                        temp.append("def ");

                    } else if (astToPrint instanceof ClassDef) {
View Full Code Here

                            IPackageFragment childPackage = (IPackageFragment) child;
                            String elementName = childPackage.getElementName();

                            //and if the java package is 'accepted'
                            if (filter.accept(elementName, root, childPackage)) {
                                buffer.clear();
                                buffer.append(elementName);
                                int packageNameLen = buffer.length();
                                if (packageNameLen > 0) {
                                    buffer.append('.');
                                    packageNameLen++;
View Full Code Here

                fillImportFromInfo(entry, importsAndComments, importsAndNoComments);

                //ok, it's all filled, let's start rewriting it!
                boolean firstInLine = true;
                line.clear();
                boolean addedParenForLine = false;

                //ok, write all the ones with comments after the ones without any comments (each one with comment
                //will be written as a new import)
                importsAndNoComments.addAll(importsAndComments);
View Full Code Here

                                line.append('\\');
                                line.append(endLineDelim);
                                line.append(indentStr);
                            }
                            all.append(line);
                            line.clear();
                        }
                    }

                    line.append(tuple.o1);
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.