code: final protected BagOfSourcedTokens asBagOfSourcedTokens(SourcedStringWrapper w) 
      {
          if (w instanceof BagOfSourcedTokens) return (BagOfSourcedTokens)w;
          else {
              SourcedToken[] toks = tokenizer.sourcedTokenize(w.unwrap(), w.getSource());
              return new BagOfSourcedTokens(w.unwrap(), toks);
          }
      }
docs: convert to a bag of tokens