code: private static void storeEmits(int position, State currentState, List<Emit> collectedEmits)
      {
          Collection<String> emits = currentState.emit();
          if (emits != null && !emits.isEmpty())
          {
              for (String emit : emits)
              {
                  collectedEmits.add(new Emit(position - emit.length() + 1, position, emit));
              }
          }
      }
docs: 保存匹配结果
  
  @param position       当前位置，也就是匹配到的模式串的结束位置+1
  @param currentState   当前状态
  @param collectedEmits 保存位置