code: public UnitFactor get(Unit from, Unit to) {
      Map<Unit, UnitFactor> map = factors.get(from);
      if (map != null) {
        UnitFactor factor = map.get(to);
        if (factor != null) {
          return factor;
        }
      }
      return null;
    }
docs: Find an exact conversion factor between the from and to units, or return
  null if none exists.