+ /**
+ * Non-throwing version of fromBinary().
+ * On failure returns IPAddressFormatError.
+ */
+ static Expected<IPAddress, IPAddressFormatError> tryFromBinary(
+ ByteRange bytes) noexcept;
+
+ /**
+ * Tries to create a new IPAddress instance from provided string and
+ * returns it on success. Returns IPAddressFormatError on failure.
+ */
+ static Expected<IPAddress, IPAddressFormatError> tryFromString(
+ StringPiece str) noexcept;
+