docs: public static Encounter decode(String vstr) {
          String[] pcs = StrUtil.split(vstr, VSTR_DELIM, 4);
          long encIEN = NumberUtils.toLong(pcs[3]);
  
          if (encIEN > 0) {
              return DomainFactoryRegistry.fetchObject(Encounter.class, pcs[3]);
          }
  
          long locIEN = NumberUtils.toLong(pcs[0]);
          Location location = locIEN == 0 ? null : DomainFactoryRegistry.fetchObject(Location.class, pcs[0]);
          Date date = FMDate.fromString(pcs[1]);
          return create(PatientContext.getActivePatient(), date, location, pcs[2]);
      }