Skip to content

Network iOS xcode26.0 b1

Alex Soto edited this page Jun 9, 2025 · 1 revision

#Network.framework

diff -ruN /Applications/Xcode_16.4.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/Network.framework/Headers/endpoint.h /Applications/Xcode_26.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/Network.framework/Headers/endpoint.h
--- /Applications/Xcode_16.4.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/Network.framework/Headers/endpoint.h	2025-04-27 21:49:56
+++ /Applications/Xcode_26.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/Network.framework/Headers/endpoint.h	2025-05-24 07:02:52
@@ -108,14 +108,16 @@
  *
  * @abstract
  *		Retrieves the hostname string for a network endpoint with
- *		the type nw_endpoint_type_host or nw_endpoint_type_url.
+ *		the type nw_endpoint_type_host, nw_endpoint_type_address,
+ *		or nw_endpoint_type_url.
  *
  * @param endpoint
  *		The endpoint object.
  *
  * @result
  *		Returns the hostname string for the endpoint, or NULL
- *		if the endpoint is not of type nw_endpoint_type_host.
+ *		if the endpoint is not of type nw_endpoint_type_host,
+ *		nw_endpoint_type_address, or nw_endpoint_type_url.
  */
 API_AVAILABLE(macos(10.14), ios(12.0), watchos(5.0), tvos(12.0))
 const char *
diff -ruN /Applications/Xcode_16.4.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/Network.framework/Headers/error.h /Applications/Xcode_26.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/Network.framework/Headers/error.h
--- /Applications/Xcode_16.4.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/Network.framework/Headers/error.h	2025-04-27 21:49:56
+++ /Applications/Xcode_26.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/Network.framework/Headers/error.h	2025-05-24 06:09:05
@@ -47,7 +47,9 @@
 	/*! @const nw_error_domain_dns The error code will be a DNSServiceErrorType error as defined in <dns_sd.h> */
 	nw_error_domain_dns = 2,
 	/*! @const nw_error_domain_tls The error code will be a TLS error as defined in <Security/SecBase.h> */
-	nw_error_domain_tls = 3
+	nw_error_domain_tls = 3,
+	/*! @const nw_error_domain_wifi_aware The error code will be a Wi-Fi Aware error as defined in <WifiAware/errors.swift> */
+	nw_error_domain_wifi_aware API_AVAILABLE(macos(26.0), ios(26.0), watchos(26.0), tvos(26.0), visionos(26.0)) = 4,
 } nw_error_domain_t;
 
 /*!
@@ -102,6 +104,13 @@
  */
 API_AVAILABLE(macos(10.14), ios(12.0), watchos(5.0), tvos(12.0))
 extern const CFStringRef kNWErrorDomainTLS; // Values will be errSSL* errors
+
+/*!
+ * @const kNWErrorDomainWiFiAware
+ * @abstract CFErrorRef domain corresponding to nw_error_domain_wifi_aware.
+ */
+API_AVAILABLE(macos(26.0), ios(26.0), watchos(26.0), tvos(26.0), visionos(26.0))
+extern const CFStringRef kNWErrorDomainWiFiAware; // Values will be errors from <WifiAware/errors.swift>
 
 /*!
  * @function nw_error_copy_cf_error
diff -ruN /Applications/Xcode_16.4.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/Network.framework/Headers/parameters.h /Applications/Xcode_26.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/Network.framework/Headers/parameters.h
--- /Applications/Xcode_16.4.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/Network.framework/Headers/parameters.h	2025-04-19 03:28:52
+++ /Applications/Xcode_26.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/Network.framework/Headers/parameters.h	2025-05-24 05:16:48
@@ -430,7 +430,7 @@
 API_AVAILABLE(macos(10.14), ios(12.0), watchos(5.0), tvos(12.0))
 void
 nw_parameters_set_required_interface_type(nw_parameters_t parameters,
-									 nw_interface_type_t interface_type);
+										  nw_interface_type_t interface_type);
 
 /*!
  * @function nw_parameters_get_required_interface_type
@@ -576,6 +576,38 @@
 API_AVAILABLE(macos(10.15), ios(13.0), watchos(6.0), tvos(13.0))
 bool
 nw_parameters_get_prohibit_constrained(nw_parameters_t parameters);
+
+/*!
+ * @function nw_parameters_set_allow_ultra_constrained
+ *
+ * @abstract
+ *		Explicitly allow connectivity over ultra-constrained interfaces. Without
+ *		this being set, connections are not allowed to use these interfaces.
+ *
+ * @param parameters
+ *		The parameters to modify.
+ *
+ * @param allow_ultra_constrained
+ *		Whether or not ultra-constrained interfaces are allowed.
+ */
+API_AVAILABLE(macos(26.0), ios(26.0), watchos(26.0), tvos(26.0), visionos(26.0))
+void nw_parameters_set_allow_ultra_constrained(nw_parameters_t parameters, bool allow_ultra_constrained);
+
+/*!
+ * @function nw_parameters_get_allow_ultra_constrained
+ *
+ * @abstract
+ *		Check if the parameters explicitly allow connectivity over
+ *		ultra-constrained interfaces.
+ *
+ * @param parameters
+ *		The parameters to check.
+ *
+ * @result
+ *		Returns whether or not ultra-constrained interfaces are allowed.
+ */
+API_AVAILABLE(macos(26.0), ios(26.0), watchos(26.0), tvos(26.0), visionos(26.0))
+bool nw_parameters_get_allow_ultra_constrained(nw_parameters_t parameters);
 
 /*!
  * @function nw_parameters_set_reuse_local_address
diff -ruN /Applications/Xcode_16.4.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/Network.framework/Headers/path.h /Applications/Xcode_26.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/Network.framework/Headers/path.h
--- /Applications/Xcode_16.4.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/Network.framework/Headers/path.h	2025-04-19 03:28:51
+++ /Applications/Xcode_26.0.0-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/Network.framework/Headers/path.h	2025-05-24 05:30:40
@@ -2,7 +2,7 @@
 //  path.h
 //  Network
 //
-//  Copyright (c) 2017-2020 Apple Inc. All rights reserved.
+//  Copyright (c) 2017-2025 Apple Inc. All rights reserved.
 //
 
 #ifndef __NW_PATH_H__
@@ -196,6 +196,23 @@
 nw_path_is_constrained(nw_path_t path);
 
 /*!
+ * @function nw_path_is_ultra_constrained
+ *
+ * @abstract
+ *		Checks if the path uses any network interfaces that are considered ultra-constrained.
+ *
+ * @param path
+ *		The path object to check.
+ *
+ * @result
+ *		Returns true if the path uses any network interface that is considered ultra-constrained,
+ *		false otherwise.
+ */
+API_AVAILABLE(macos(26.0), ios(26.0), watchos(26.0), tvos(26.0), visionos(26.0))
+bool
+nw_path_is_ultra_constrained(nw_path_t path);
+
+/*!
  * @function nw_path_has_ipv4
  *
  * @abstract
@@ -326,6 +343,42 @@
 						   NW_NOESCAPE nw_path_enumerate_gateways_block_t enumerate_block);
 
 #endif // __BLOCKS__
+
+/*!
+ * @typedef nw_link_quality_t
+ * @abstract
+ *		Link quality measurement is a representation of the expected capabilities of the link layer network
+ *		attachment. Use this value to tune initial values for algorithms that can scale with the
+ *		capabilities of the network. Do not use this value to gate connection attempts or to override
+ *		adjustments that would be made based on actual network performance.
+ */
+typedef enum {
+	/*! @const nw_link_quality_unknown No link quality measurement is available */
+	nw_link_quality_unknown = 0,
+	/*! @const nw_link_quality_minimal Link quality is minimal */
+	nw_link_quality_minimal = 10,
+	/*! @const nw_link_quality_moderate Link quality is moderate */
+	nw_link_quality_moderate = 20,
+	/*! @const nw_link_quality_good Link quality is good */
+	nw_link_quality_good = 30
+} nw_link_quality_t;
+
+/*!
+ * @function nw_path_get_link_quality
+ *
+ * @abstract
+ *		Fetches the link quality measurement for the interface.
+ *
+ * @param path
+ *		The path object to check.
+ *
+ * @result
+ *		Returns the link quality measurement of the link layer network attachment.
+ *		Returns nw_link_quality_unknown if there is no measurement available.
+ */
+API_AVAILABLE(macos(26.0), ios(26.0), watchos(26.0), tvos(26.0))
+nw_link_quality_t
+nw_path_get_link_quality(nw_path_t path);
 
 NW_ASSUME_NONNULL_END
 
Clone this wiki locally