code: public String basicCategory(String category) {
      if (category == null) {
        return null;
      }
      return category.substring(0, postBasicCategoryIndex(category));
    }
docs: Returns the basic syntactic category of a String.
  This implementation basically truncates
  stuff after an occurrence of one of the
  <code>labelAnnotationIntroducingCharacters()</code>.
  However, there is also special case stuff to deal with
  labelAnnotationIntroducingCharacters in category labels:
  (i) if the first char is in this set, it's never truncated
  (e.g., '-' or '=' as a token), and (ii) if it starts with
  one of this set, a second instance of the same item from this set is
  also excluded (to deal with '-LLB-', '-RCB-', etc.).
  
  @param category The whole String name of the label
  @return The basic category of the String