private static String getPortAsString(LocatorLauncher launcher) {
      if (InternalLocator.hasLocator()) {
        final InternalLocator locator = InternalLocator.getLocator();
        final String portAsString = String.valueOf(locator.getPort());
        if (isNotBlank(portAsString)) {
          return portAsString;
        }
      }
      return launcher.getPortAsString();
    }
Unmarshals a LocatorState instance from the JSON String.

@param json a JSON String
@return a LocatorState value unmarshalled from the JSON String.
geode-core/src/main/java/org/apache/geode/distributed/LocatorLauncher.java