Examples of deleteLast()


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

            buffer.append(" (references:");
            for (IToken ref : references) {
                buffer.append(ref.getRepresentation());
                buffer.append(",");
            }
            buffer.deleteLast(); //remove the last comma
            buffer.append(") ");
        }

        buffer.append("]");
        return buffer.toString();
View Full Code Here

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

        FastStringBuffer buf = new FastStringBuffer();
        for (String line : StringUtils.splitInLines(str)) {
            buf.append(line);
            char c = buf.lastChar();
            if (c == '\n') {
                buf.deleteLast();
                if (showSpacesAndNewLines) {
                    buf.append("\\n");
                }
                //Adds chars so that the initial presentation is bigger (they are later changed for spaces).
                //If that's not done, the created editor would be too small... especially if we consider
View Full Code Here

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

            }
            if (!found) {
                buf.append(tag);
                buf.append('=');
            } else {
                buf.deleteLast(); //remove the last '\n'
            }
            textControl.setText(buf.toString());
            textControl.setSelection(textControl.getSize());
            textControl.setFocus();
        }
View Full Code Here

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

    public boolean writeNewLine(boolean force) throws IOException {
        if (force || lastState == LAST_STATE_WRITE) {
            FastStringBuffer buffer = writer.getBuffer();
            if (buffer.endsWith(": ")) {
                buffer.deleteLast();
            }

            if (lastState == LAST_STATE_NEW_LINE) {
                this.writeIndent();
            }
View Full Code Here

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

                            buffer = new FastStringBuffer(line.substring(0, i), 0);
                        } else {
                            buffer = new FastStringBuffer(line, 0);
                        }
                        while (buffer.length() > 0 && Character.isWhitespace(buffer.lastChar())) {
                            buffer.deleteLast();
                        }
                        absoluteEnd = start.getOffset() + buffer.length();
                    }
                } catch (BadLocationException e) {
                    //Don't log it. Just return null -- this happens because there's a delay from calculating things
View Full Code Here

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

                retVal.append(((NameTok) aliasType.name).id);
                retVal.append(", ");
            }
            //delete the last 2 chars
            retVal.deleteLast();
            retVal.deleteLast();
            return retVal.toString();

        } else if (astThis.node instanceof ImportFrom) {
            // from wxPython.wx import *
 
View Full Code Here

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

                retVal.append(((NameTok) aliasType.name).id);
                retVal.append(", ");
            }
            //delete the last 2 chars
            retVal.deleteLast();
            retVal.deleteLast();
            return retVal.toString();

        } else if (astThis.node instanceof ImportFrom) {
            // from wxPython.wx import *
            ImportFrom importToken = (ImportFrom) astThis.node;
View Full Code Here

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

            com.aptana.shared_core.string.StringUtils.parsePositiveLong(buf);
            fail("Expecting exception");
        } catch (NumberFormatException e) {
            //empty
        }
        buf.deleteLast();
        assertEquals(101, com.aptana.shared_core.string.StringUtils.parsePositiveLong(buf));

        buf.append("4");
        assertEquals(1014, com.aptana.shared_core.string.StringUtils.parsePositiveLong(buf));
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.