code: public static Vec updateDomain(Vec source, String[] toDomain) {
      CategoricalWrappedVec tv = makeTransientVec(source.domain(), toDomain);
      new RemapTask(tv).doAll(source);
      source.setDomain(tv.domain());
      DKV.put(source);
      return source;
    }
docs: Updates Vec's domain in-place (instead of creating a wrapper Vec)
  @param source source Vec
  @param toDomain target domain
  @return updated instance of Vec