com.aptana.ide.editor.css.contentassist
Class CSSUtils

java.lang.Object
  extended by com.aptana.ide.editor.css.contentassist.CSSUtils

public final class CSSUtils
extends java.lang.Object

Author:
Robin Debreuil

Method Summary
static java.lang.String getLocation(int offset, LexemeList lexemeList)
          Returns the "location" we are currently in.
static Lexeme getNextLexemeOfType(Lexeme startLexeme, int[] lexemeTypes, int[] lexemeTypesToBail, LexemeList lexemeList)
          getNextLexemeOfType
static Lexeme getNextLexemeOfType(Lexeme startLexeme, int[] lexemeTypes, LexemeList lexemeList)
          getNextLexemeOfType
static boolean isColonAlreadyInserted(int offset, LexemeList ll)
          We don't insert a : if there is already one there
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getLocation

public static java.lang.String getLocation(int offset,
                                           LexemeList lexemeList)
Returns the "location" we are currently in. What this means in the end is that it helps us figure out which of three states we are in. This also sets the current name hash (which should be moved to CSSOffsetMapper eventually)

Parameters:
offset - The current offset
lexemeList -
Returns:
One of the location enumerations

isColonAlreadyInserted

public static boolean isColonAlreadyInserted(int offset,
                                             LexemeList ll)
We don't insert a : if there is already one there

Parameters:
offset -
ll -
Returns:
boolean

getNextLexemeOfType

public static Lexeme getNextLexemeOfType(Lexeme startLexeme,
                                         int[] lexemeTypes,
                                         LexemeList lexemeList)
getNextLexemeOfType

Parameters:
startLexeme -
lexemeTypes -
lexemeList -
Returns:
Lexeme

getNextLexemeOfType

public static Lexeme getNextLexemeOfType(Lexeme startLexeme,
                                         int[] lexemeTypes,
                                         int[] lexemeTypesToBail,
                                         LexemeList lexemeList)
getNextLexemeOfType

Parameters:
startLexeme -
lexemeTypes -
lexemeTypesToBail -
lexemeList -
Returns:
Lexeme