code: public final ChannelAddress newChannelAddress(URI location, Map<String, Object> options) {
          String locationSchemeName = location.getScheme();
          String schemeName = getSchemeName();
  
          if (locationSchemeName == null || !locationSchemeName.equals(schemeName)) {
              throw new ChannelException(String.format("Location scheme %s does not match expected scheme %s", location,
                      schemeName));
          }
  
          // make the port explicit
          int locationPort = location.getPort();
          if (locationPort == -1) {
              int newLocationPort = getSchemePort();
              if (newLocationPort != -1) {
                  try {
                      String locationUserInfo = location.getUserInfo();
                      String locationHost = location.getHost();
                      String locationPath = location.getPath();
                      String locationQuery = location.getQuery();
                      String locationFragment = location.getFragment();
                      location = new URI(locationSchemeName, locationUserInfo, locationHost, newLocationPort,
                              locationPath, locationQuery, locationFragment);
                  } catch (URISyntaxException e) {
                      throw new ChannelException(e);
                  }
              }
          }
  
          URI transportURI = (URI) options.remove("transport");
          if (transportURI == null) {
              LocationFactory transportFactory = getTransportFactory();
              if (transportFactory != null) {
                  transportURI = transportFactory.createURI(location);
              }
          }
  
          ChannelAddress transport = null;
          if (transportURI != null) {
              transport = channelAddressFactory.newChannelAddress(transportURI, options);
          }
  
          return newChannelAddress0(location, transport, options);
      }
docs: Returns a {@link ChannelAddress} instance for the named scheme.
  @param options TODO