Package org.eclipse.php.internal.core.util.text

Examples of org.eclipse.php.internal.core.util.text.TextSequence.subSequence()


    useTrait = new ClassStatementContext().isValid(sourceModule, offset,
        requestor);
    TextSequence statementText = getStatementText();
    if (statementText.length() >= 4) {
      if ("use".equals(statementText.subSequence(0, 3).toString()) //$NON-NLS-1$
          && Character.isWhitespace(statementText.subSequence(3, 4)
              .charAt(0))) {
        return true;
      }
    }
View Full Code Here


    useTrait = new ClassStatementContext().isValid(sourceModule, offset,
        requestor);
    TextSequence statementText = getStatementText();
    if (statementText.length() >= 4) {
      if ("use".equals(statementText.subSequence(0, 3).toString()) //$NON-NLS-1$
          && Character.isWhitespace(statementText.subSequence(3, 4)
              .charAt(0))) {
        return true;
      }
    }
    return false;
View Full Code Here

        int wordStart = PHPTextSequenceUtilities.readIdentifierStartIndex(
                phpVersion, statementText, wordEnd, true);
        if (wordStart < 0 || wordEnd < 0 || wordStart > wordEnd) {
            return "";
        }
        String previousWord = statementText.subSequence(wordStart, wordEnd)
                .toString();

        if (hasWhitespaceBeforeCursor()) {
            return previousWord;
        }
View Full Code Here

        wordStart = PHPTextSequenceUtilities.readIdentifierStartIndex(
                phpVersion, statementText, wordEnd, true);
        if (wordStart < 0 || wordEnd < 0 || wordStart > wordEnd) {
            return "";
        }
        previousWord = statementText.subSequence(wordStart, wordEnd).toString();

        return previousWord;
    }

    /**
 
View Full Code Here

        }
        if (wordStart < 0 || wordEnd < 0 || wordStart > wordEnd) {
            return "";
        }
        String previousWord = statementText.subSequence(wordStart, wordEnd)
                .toString();

        if (hasWhitespaceBeforeCursor()) {
            return previousWord;
        }
View Full Code Here

        wordStart = PHPTextSequenceUtilities.readIdentifierStartIndex(
                phpVersion, statementText, wordEnd, true);
        if (wordStart < 0 || wordEnd < 0 || wordStart > wordEnd) {
            return "";
        }
        previousWord = statementText.subSequence(wordStart, wordEnd).toString();

        return previousWord;
    }

    /**
 
View Full Code Here

                statementText, statementLength); // read whitespace

        int prefixStart = TwigTextSequenceUtilities.readIdentifierStartIndex(
                statementText, prefixEnd);

        return statementText.subSequence(prefixStart, prefixEnd).toString();
    }

    /**
     * Returns the end of the word on which code assist was invoked
     *
 
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.