Skip to content

Foundation macOS xcode16.0 b1

Rolf Bjarne Kvinge edited this page Jun 18, 2024 · 4 revisions

#Foundation.framework

diff -ruN /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h
--- /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h	2024-04-05 22:17:33
+++ /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h	2024-05-30 04:48:32
@@ -49,6 +49,7 @@
 #import <Foundation/NSJSONSerialization.h>
 #import <Foundation/NSKeyValueCoding.h>
 #import <Foundation/NSKeyValueObserving.h>
+#import <Foundation/NSKeyValueSharedObservers.h>
 #import <Foundation/NSKeyedArchiver.h>
 #import <Foundation/NSLocale.h>
 #import <Foundation/NSLock.h>
@@ -60,6 +61,7 @@
 #import <Foundation/NSNotificationQueue.h>
 #import <Foundation/NSNull.h>
 #import <Foundation/NSNumberFormatter.h>
+#import <Foundation/NSLocalizedNumberFormatRule.h>
 #import <Foundation/NSObject.h>
 #import <Foundation/NSOperation.h>
 #import <Foundation/NSOrderedSet.h>
diff -ruN /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSAttributedString.h /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSAttributedString.h
--- /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSAttributedString.h	2024-04-19 07:59:24
+++ /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSAttributedString.h	2024-05-30 03:40:42
@@ -337,6 +337,10 @@
     NS_SWIFT_NAME(inflectionAlternative)
     API_AVAILABLE(macos(12.0), ios(15.0), watchos(8.0), tvos(15.0));
 
+FOUNDATION_EXPORT NSAttributedStringKey const NSLocalizedNumberFormatAttributeName
+    NS_SWIFT_NAME(localizedNumberFormat)
+    API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0));
+
 FOUNDATION_EXTERN
 const NSAttributedStringKey NSPresentationIntentAttributeName API_AVAILABLE(macos(12.0), ios(15.0), watchos(8.0), tvos(15.0));
 
diff -ruN /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSBundle.h /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSBundle.h
--- /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSBundle.h	2024-04-05 22:35:33
+++ /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSBundle.h	2024-05-30 10:19:17
@@ -53,7 +53,11 @@
 @property (nullable, readonly, copy) NSURL *sharedSupportURL API_AVAILABLE(macos(10.6), ios(4.0), watchos(2.0), tvos(9.0));
 @property (nullable, readonly, copy) NSURL *builtInPlugInsURL API_AVAILABLE(macos(10.6), ios(4.0), watchos(2.0), tvos(9.0));
 
+#if defined(__swift__) // Deprecated for Swift only
+@property (nullable, readonly, copy) NSURL *appStoreReceiptURL API_DEPRECATED("Use AppTransaction.shared and Transaction.all from StoreKit.framework instead", macosx(10.7,15.0), ios(7.0,18.0), watchos(2.0,11.0), tvos(9.0,18.0));
+#else
 @property (nullable, readonly, copy) NSURL *appStoreReceiptURL API_AVAILABLE(macos(10.7), ios(7.0), watchos(2.0), tvos(9.0));
+#endif
 
 @property (readonly, copy) NSString *bundlePath;
 @property (nullable, readonly, copy) NSString *resourcePath;
diff -ruN /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSCalendar.h /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSCalendar.h
--- /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSCalendar.h	2024-04-19 07:59:21
+++ /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSCalendar.h	2024-05-30 04:48:38
@@ -61,6 +61,7 @@
         NSCalendarUnitWeekOfYear         API_AVAILABLE(macos(10.7), ios(5.0), watchos(2.0), tvos(9.0)) = kCFCalendarUnitWeekOfYear,
         NSCalendarUnitYearForWeekOfYear  API_AVAILABLE(macos(10.7), ios(5.0), watchos(2.0), tvos(9.0)) = kCFCalendarUnitYearForWeekOfYear,
         NSCalendarUnitNanosecond         API_AVAILABLE(macos(10.7), ios(5.0), watchos(2.0), tvos(9.0)) = (1 << 15),
+        NSCalendarUnitDayOfYear          API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0)) = kCFCalendarUnitDayOfYear,
         NSCalendarUnitCalendar           API_AVAILABLE(macos(10.7), ios(4.0), watchos(2.0), tvos(9.0)) = (1 << 20),
         NSCalendarUnitTimeZone           API_AVAILABLE(macos(10.7), ios(4.0), watchos(2.0), tvos(9.0)) = (1 << 21),
     #if !0
@@ -432,6 +433,7 @@
 @property NSInteger weekOfMonth API_AVAILABLE(macos(10.7), ios(5.0), watchos(2.0), tvos(9.0));
 @property NSInteger weekOfYear API_AVAILABLE(macos(10.7), ios(5.0), watchos(2.0), tvos(9.0));
 @property NSInteger yearForWeekOfYear API_AVAILABLE(macos(10.7), ios(5.0), watchos(2.0), tvos(9.0));
+@property NSInteger dayOfYear API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0));
 @property (getter=isLeapMonth) BOOL leapMonth API_AVAILABLE(macos(10.8), ios(6.0), watchos(2.0), tvos(9.0));
 @property (nullable, readonly, copy) NSDate *date API_AVAILABLE(macos(10.7), ios(4.0), watchos(2.0), tvos(9.0));
 
@@ -447,7 +449,7 @@
 
 /*
 	This API allows one to get the value of a specific component of NSDateComponents, by enum constant value rather than property name.
-	The calendar and timeZone and isLeapMonth property values cannot be gotten by this method.
+	The calendar and timeZone and isLeapMonth property values cannot be retrieved by this method.
 */
 - (NSInteger)valueForComponent:(NSCalendarUnit)unit API_AVAILABLE(macos(10.9), ios(8.0), watchos(2.0), tvos(9.0));
 
diff -ruN /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSKeyValueSharedObservers.h /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSKeyValueSharedObservers.h
--- /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSKeyValueSharedObservers.h	1970-01-01 01:00:00
+++ /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSKeyValueSharedObservers.h	2024-05-30 02:44:28
@@ -0,0 +1,77 @@
+//
+//  NSKeyValueSharedObservers.h
+//  Foundation
+//
+//  Copyright (c) 2024, Apple Inc.
+//  All rights reserved.
+//
+
+#import <Foundation/NSKeyValueObserving.h>
+
+NS_HEADER_AUDIT_BEGIN(nullability, sendability)
+
+/// A collection of key-value observations which may be registered with multiple
+/// observable objects. Create using ``-[NSKeyValueSharedObservers snapshot]``
+API_AVAILABLE(macos(15.0), ios(18.0), tvos(18.0), watchos(11.0), visionos(2.0))
+@interface NSKeyValueSharedObserversSnapshot: NSObject
+- (id)init NS_UNAVAILABLE;
++ (id)new NS_UNAVAILABLE;
+@end
+
+/// A collection of key-value observations which may be registered with multiple
+/// observable objects
+API_AVAILABLE(macos(15.0), ios(18.0), tvos(18.0), watchos(11.0), visionos(2.0))
+@interface NSKeyValueSharedObservers: NSObject
+/// A new collection of observables for an observable object of the given class
+- (id)initWithObservableClass:(Class)observableClass;
+- (id)init NS_UNAVAILABLE;
++ (id)new NS_UNAVAILABLE;
+
+/// Add a new observer to the collection.
+///
+/// This method works like `-[NSObject addObserver: forKey: options: context:]`,
+/// but observations on nested and computed properties are disallowed. Observers
+/// are not registered until `setSharedObservers` is called on the observable.
+///
+/// - Parameter observer: The observer object to register for KVO notifications.
+///   The observer must implement the key-value observing method ``observeValue:
+///   forKeyPath: of: change: context:``
+/// - Parameter key: key of the property being observed. This cannot be a nested
+///   key path or a computed property
+/// - Parameter options: A combination of NSKeyValueObservingOptions values that
+///   specify what is included in observation notifications. For possible values
+///   see NSKeyValueObservingOptions.
+/// - Parameter context: Arbitrary data which is passed to the observer object
+- (void)addSharedObserver:(NSObject *)observer
+                   forKey:(NSString *)key
+                  options:(NSKeyValueObservingOptions)options
+                  context:(nullable void *)context;
+
+- (void)addObserver:(NSObject *)observer forKeyPath:(NSString *)keyPath options:(NSKeyValueObservingOptions)options context:(nullable void *)context NS_UNAVAILABLE;
+
+/// A momentary snapshot of all observers added to the collection thus far, that
+/// can be assigned to an observable using ``-[NSObject setSharedObservers:]``
+- (NSKeyValueSharedObserversSnapshot *)snapshot;
+@end
+
+@interface NSObject(NSKeyValueSharedObserverRegistration)
+/// Register shared observations.
+///
+/// A shared observation collection might be shared between multiple observables
+/// to minimise registration work. Shared observers remain registered throughout
+/// the object's lifetime and do not need to be removed using `removeObserver:`.
+///
+/// An observable may only have one set of shared observations. Subsequent calls
+/// to this method will replace existing shared observations.
+///
+/// - Parameter sharedObservers: shared observer collection that was initialized
+///   with the class of this object
+/// - Invariant: `sharedObserers` was initialized with the class of this object
+/// - Throws: Exception if the class of the receiving observable object does not
+///   match the class with which `sharedObserers` was initialized.
+- (void)setSharedObservers:(NSKeyValueSharedObserversSnapshot * _Nullable)sharedObservers API_AVAILABLE(macos(15.0), ios(18.0), tvos(18.0), watchos(11.0), visionos(2.0));
+
+
+@end
+
+NS_HEADER_AUDIT_END(nullability, sendability)
diff -ruN /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSLocalizedNumberFormatRule.h /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSLocalizedNumberFormatRule.h
--- /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSLocalizedNumberFormatRule.h	1970-01-01 01:00:00
+++ /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSLocalizedNumberFormatRule.h	2024-05-30 02:44:28
@@ -0,0 +1,25 @@
+//
+//  NSLocalizedNumberFormatRule.h
+//  Foundation
+//
+//  Copyright (c) 2024, Apple Inc.
+//  All rights reserved.
+//
+
+#import <Foundation/Foundation.h>
+
+NS_HEADER_AUDIT_BEGIN(nullability, sendability)
+
+API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0))
+NS_REFINED_FOR_SWIFT
+@interface NSLocalizedNumberFormatRule : NSObject <NSCopying, NSSecureCoding>
+
++ (id)new NS_UNAVAILABLE;
+- (id)init NS_UNAVAILABLE;
+
++ (NSLocalizedNumberFormatRule *)automatic;
+
+@end
+
+NS_HEADER_AUDIT_END(nullability, sendability)
+
diff -ruN /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSNumberFormatter.h /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSNumberFormatter.h
--- /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSNumberFormatter.h	2024-04-19 08:01:25
+++ /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSNumberFormatter.h	2024-05-30 05:00:49
@@ -54,6 +54,8 @@
 + (NSNumberFormatterBehavior)defaultFormatterBehavior;
 + (void)setDefaultFormatterBehavior:(NSNumberFormatterBehavior)behavior;
 
+// See `kCFNumberFormatterMinGroupingDigits` in `CFNumberFormatter` for an explanation on how minimum grouping digits is used.
+@property NSInteger minimumGroupingDigits API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0), visionos(2.0));
 @property NSNumberFormatterStyle numberStyle;
 @property (null_resettable, copy) NSLocale *locale;
 @property BOOL generatesDecimalNumbers;
diff -ruN /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h
--- /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h	2024-04-19 07:39:44
+++ /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h	2024-05-30 05:00:50
@@ -283,7 +283,12 @@
    // Indicates that a specific member of an 'NS_SWIFT_UI_ACTOR'-isolated type is "threadsafe" and should be callable from outside the main actor.
 #  define NS_SWIFT_NONISOLATED __attribute__((swift_attr("nonisolated")))
 
-#  define __NS_HEADER_AUDIT_BEGIN_sendability _Pragma("clang attribute NS_HEADER_AUDIT_sendability.push (__attribute__((swift_attr(\"@_nonSendable(_assumed)\"))), apply_to = any(objc_interface, record, enum))")
+#  define __NS_HEADER_AUDIT_BEGIN_sendability \
+    _Pragma("clang diagnostic push") \
+    _Pragma("clang diagnostic ignored \"-Wpragma-clang-attribute\"") \
+    _Pragma("clang attribute NS_HEADER_AUDIT_sendability.push (__attribute__((swift_attr(\"@_nonSendable(_assumed)\"))), apply_to = any(objc_interface, record, enum))") \
+    _Pragma("clang diagnostic pop")
+
 #  define __NS_HEADER_AUDIT_END_sendability   _Pragma("clang attribute NS_HEADER_AUDIT_sendability.pop")
 #else
 #  define NS_SWIFT_SENDABLE
diff -ruN /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSStream.h /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSStream.h
--- /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSStream.h	2024-04-19 07:31:40
+++ /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSStream.h	2024-05-30 04:48:40
@@ -38,7 +38,7 @@
 - (void)open;
 - (void)close;
 
-@property (nullable, assign) id <NSStreamDelegate> delegate;
+@property (nullable, assign /* actually weak */) id <NSStreamDelegate> delegate;
     // By default, a stream is its own delegate, and subclassers of NSInputStream and NSOutputStream must maintain this contract. [someStream setDelegate:nil] must restore this behavior. As usual, delegates are not retained.
 
 - (nullable id)propertyForKey:(NSStreamPropertyKey)key;
diff -ruN /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSURL.h /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSURL.h
--- /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSURL.h	2024-04-19 07:31:42
+++ /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSURL.h	2024-05-30 04:24:46
@@ -1,5 +1,5 @@
 /*	NSURL.h
-	Copyright (c) 1997-2019, Apple Inc. All rights reserved.
+	Copyright (c) 1997-2023, Apple Inc. All rights reserved.
 */
 
 #import <Foundation/NSObject.h>
@@ -505,11 +505,7 @@
 NS_SWIFT_SENDABLE // Immutable with no mutable subclasses
 API_AVAILABLE(macos(10.10), ios(8.0), watchos(2.0), tvos(9.0))
 // NSURLQueryItem encapsulates a single query name-value pair. The name and value strings of a query name-value pair are not percent encoded. For use with the NSURLComponents queryItems property.
-@interface NSURLQueryItem : NSObject <NSSecureCoding, NSCopying> {
-@private
-    NSString *_name;
-    NSString *_value;
-}
+@interface NSURLQueryItem : NSObject <NSSecureCoding, NSCopying> 
 - (instancetype)initWithName:(NSString *)name value:(nullable NSString *)value NS_DESIGNATED_INITIALIZER;
 + (instancetype)queryItemWithName:(NSString *)name value:(nullable NSString *)value;
 @property (readonly) NSString *name;
diff -ruN /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSURLProtocol.h /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSURLProtocol.h
--- /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSURLProtocol.h	2024-04-19 07:39:44
+++ /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSURLProtocol.h	2024-05-30 04:48:39
@@ -62,6 +62,7 @@
 loading system that is intended for use by NSURLProtocol
 implementors.
 */
+NS_SWIFT_SENDABLE
 API_AVAILABLE(macos(10.2), ios(2.0), watchos(2.0), tvos(9.0))
 @protocol NSURLProtocolClient <NSObject>
 
diff -ruN /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSURLRequest.h /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSURLRequest.h
--- /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSURLRequest.h	2024-04-19 08:01:25
+++ /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSURLRequest.h	2024-05-30 10:19:15
@@ -203,103 +203,103 @@
 API_AVAILABLE(macos(10.2), ios(2.0), watchos(2.0), tvos(9.0))
 @interface NSURLRequest : NSObject <NSSecureCoding, NSCopying, NSMutableCopying>
 {
-    @private
+@private
     NSURLRequestInternal *_internal;
 }
 
-/*! 
-    @method requestWithURL:
-    @abstract Allocates and initializes an NSURLRequest with the given
-    URL.
-    @discussion Default values are used for cache policy
-    (NSURLRequestUseProtocolCachePolicy) and timeout interval (60
-    seconds).
-    @param URL The URL for the request.
-    @result A newly-created and autoreleased NSURLRequest instance.
-*/
+/*!
+ @method requestWithURL:
+ @abstract Allocates and initializes an NSURLRequest with the given
+ URL.
+ @discussion Default values are used for cache policy
+ (NSURLRequestUseProtocolCachePolicy) and timeout interval (60
+ seconds).
+ @param URL The URL for the request.
+ @result A newly-created and autoreleased NSURLRequest instance.
+ */
 + (instancetype)requestWithURL:(NSURL *)URL;
 
 /*!
-    @property supportsSecureCoding
-    @abstract Indicates that NSURLRequest implements the NSSecureCoding protocol.
-    @result A BOOL value set to YES.
-*/
+ @property supportsSecureCoding
+ @abstract Indicates that NSURLRequest implements the NSSecureCoding protocol.
+ @result A BOOL value set to YES.
+ */
 @property (class, readonly) BOOL supportsSecureCoding;
 /*!
-    @method requestWithURL:cachePolicy:timeoutInterval:
-    @abstract Allocates and initializes a NSURLRequest with the given
-    URL and cache policy.
-    @param URL The URL for the request. 
-    @param cachePolicy The cache policy for the request. 
-    @param timeoutInterval The timeout interval for the request. See the
-    commentary for the <tt>timeoutInterval</tt> for more information on
-    timeout intervals.
-    @result A newly-created and autoreleased NSURLRequest instance. 
-*/
+ @method requestWithURL:cachePolicy:timeoutInterval:
+ @abstract Allocates and initializes a NSURLRequest with the given
+ URL and cache policy.
+ @param URL The URL for the request.
+ @param cachePolicy The cache policy for the request.
+ @param timeoutInterval The timeout interval for the request. See the
+ commentary for the <tt>timeoutInterval</tt> for more information on
+ timeout intervals.
+ @result A newly-created and autoreleased NSURLRequest instance.
+ */
 + (instancetype)requestWithURL:(NSURL *)URL cachePolicy:(NSURLRequestCachePolicy)cachePolicy timeoutInterval:(NSTimeInterval)timeoutInterval;
 
-/*! 
-    @method initWithURL:
-    @abstract Initializes an NSURLRequest with the given URL. 
-    @discussion Default values are used for cache policy
-    (NSURLRequestUseProtocolCachePolicy) and timeout interval (60
-    seconds).
-    @param URL The URL for the request. 
-    @result An initialized NSURLRequest. 
-*/
+/*!
+ @method initWithURL:
+ @abstract Initializes an NSURLRequest with the given URL.
+ @discussion Default values are used for cache policy
+ (NSURLRequestUseProtocolCachePolicy) and timeout interval (60
+ seconds).
+ @param URL The URL for the request.
+ @result An initialized NSURLRequest.
+ */
 - (instancetype)initWithURL:(NSURL *)URL;
 
-/*! 
-    @method initWithURL:
-    @abstract Initializes an NSURLRequest with the given URL and
-    cache policy.
-    @discussion This is the designated initializer for the 
-    NSURLRequest class.
-    @param URL The URL for the request. 
-    @param cachePolicy The cache policy for the request. 
-    @param timeoutInterval The timeout interval for the request. See the
-    commentary for the <tt>timeoutInterval</tt> for more information on
-    timeout intervals.
-    @result An initialized NSURLRequest. 
-*/
+/*!
+ @method initWithURL:
+ @abstract Initializes an NSURLRequest with the given URL and
+ cache policy.
+ @discussion This is the designated initializer for the
+ NSURLRequest class.
+ @param URL The URL for the request.
+ @param cachePolicy The cache policy for the request.
+ @param timeoutInterval The timeout interval for the request. See the
+ commentary for the <tt>timeoutInterval</tt> for more information on
+ timeout intervals.
+ @result An initialized NSURLRequest.
+ */
 - (instancetype)initWithURL:(NSURL *)URL cachePolicy:(NSURLRequestCachePolicy)cachePolicy timeoutInterval:(NSTimeInterval)timeoutInterval NS_DESIGNATED_INITIALIZER;
 
-/*! 
-    @abstract Returns the URL of the receiver. 
-    @result The URL of the receiver. 
-*/
+/*!
+ @abstract Returns the URL of the receiver.
+ @result The URL of the receiver.
+ */
 @property (nullable, readonly, copy) NSURL *URL;
 
-/*! 
-    @abstract Returns the cache policy of the receiver.
-    @result The cache policy of the receiver. 
-*/
+/*!
+ @abstract Returns the cache policy of the receiver.
+ @result The cache policy of the receiver.
+ */
 @property (readonly) NSURLRequestCachePolicy cachePolicy;
 
-/*! 
-    @abstract Returns the timeout interval of the receiver.
-    @discussion The timeout interval specifies the limit on the idle
-    interval allotted to a request in the process of loading. The "idle
-    interval" is defined as the period of time that has passed since the
-    last instance of load activity occurred for a request that is in the
-    process of loading. Hence, when an instance of load activity occurs
-    (e.g. bytes are received from the network for a request), the idle
-    interval for a request is reset to 0. If the idle interval ever
-    becomes greater than or equal to the timeout interval, the request
-    is considered to have timed out. This timeout interval is measured
-    in seconds.
-    @result The timeout interval of the receiver. 
-*/
+/*!
+ @abstract Returns the timeout interval of the receiver.
+ @discussion The timeout interval specifies the limit on the idle
+ interval allotted to a request in the process of loading. The "idle
+ interval" is defined as the period of time that has passed since the
+ last instance of load activity occurred for a request that is in the
+ process of loading. Hence, when an instance of load activity occurs
+ (e.g. bytes are received from the network for a request), the idle
+ interval for a request is reset to 0. If the idle interval ever
+ becomes greater than or equal to the timeout interval, the request
+ is considered to have timed out. This timeout interval is measured
+ in seconds.
+ @result The timeout interval of the receiver.
+ */
 @property (readonly) NSTimeInterval timeoutInterval;
 
 /*!
-    @abstract The main document URL associated with this load.
-    @discussion This URL is used for the cookie "same domain as main
-    document" policy, and attributing the request as a sub-resource
-    of a user-specified URL. There may also be other future uses.
-    See setMainDocumentURL:
-    @result The main document URL.
-*/
+ @abstract The main document URL associated with this load.
+ @discussion This URL is used for the cookie "same domain as main
+ document" policy, and attributing the request as a sub-resource
+ of a user-specified URL. There may also be other future uses.
+ See setMainDocumentURL:
+ @result The main document URL.
+ */
 @property (nullable, readonly, copy) NSURL *mainDocumentURL;
 
 /*!
@@ -357,6 +357,15 @@
  */
 @property (readonly) BOOL requiresDNSSECValidation API_AVAILABLE(macos(13.0), ios(16.1), watchos(9.1), tvos(16.1));
 
+/*!
+ @abstract Allows storing and usage of DNS answers, potentially beyond TTL expiry,
+ in a persistent per-process cache. This should only be set for hostnames whose resolutions
+ are not expected to change across networks.
+ @discussion YES, if the DNS lookup for this request is allowed to use a persistent per-process cache,
+ NO otherwise. Defaults to NO.
+ */
+@property (readonly) BOOL allowsPersistentDNS API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0), visionos(2.0));
+
 @end
 
 
@@ -482,6 +491,15 @@
  No otherwise. Defaults to NO.
  */
 @property BOOL requiresDNSSECValidation API_AVAILABLE(macos(13.0), ios(16.1), watchos(9.1), tvos(16.1));
+
+/*!
+ @abstract Allows storing and usage of DNS answers, potentially beyond TTL expiry,
+ in a persistent per-process cache. This should only be set for hostnames whose resolutions
+ are not expected to change across networks.
+ @discussion YES, if the DNS lookup for this request is allowed to use a persistent per-process cache,
+ NO otherwise. Defaults to NO.
+ */
+@property BOOL allowsPersistentDNS API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0), visionos(2.0));
 
 @end
 
diff -ruN /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSUndoManager.h /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSUndoManager.h
--- /Applications/Xcode_15.4.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSUndoManager.h	2024-04-19 07:18:53
+++ /Applications/Xcode_16.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSUndoManager.h	2024-05-30 04:48:41
@@ -20,6 +20,9 @@
 // used with NSRunLoop's performSelector:target:argument:order:modes:
 static const NSUInteger NSUndoCloseGroupingRunLoopOrdering = 350000;
 
+/// A key used to set and get user info for undo and redo actions
+typedef NSString * NSUndoManagerUserInfoKey NS_TYPED_EXTENSIBLE_ENUM NS_SWIFT_NAME(UndoManager.UserInfoKey) API_AVAILABLE(macos(15.0), ios(18.0), tvos(18.0), watchos(11.0));
+
 API_AVAILABLE(macos(10.0), ios(3.0), watchos(2.0), tvos(9.0))
 @interface NSUndoManager : NSObject
 
@@ -198,6 +201,21 @@
 /// 
 /// - Parameter actionName: The name of the action.
 - (void)setActionName:(NSString *)actionName;
+
+/// Get a value from the undo action's user info
+///
+/// - Parameter key: Which value should be retrieved
+-(id _Nullable)undoActionUserInfoValueForKey:(NSUndoManagerUserInfoKey)key API_AVAILABLE(macos(15.0), ios(18.0), tvos(18.0), watchos(11.0));
+
+/// Get a value from the redo action's user info
+/// 
+/// - Parameter key: Which value should be retrieved
+-(id _Nullable)redoActionUserInfoValueForKey:(NSUndoManagerUserInfoKey)key API_AVAILABLE(macos(15.0), ios(18.0), tvos(18.0), watchos(11.0));
+
+/// Set user info for the Undo or Redo command.
+/// - Parameter info: Value to be saved in the user info
+/// - Parameter key: Key at which the object should be saved
+-(void)setActionUserInfoValue:(id _Nullable)info forKey:(NSUndoManagerUserInfoKey)key API_AVAILABLE(macos(15.0), ios(18.0), tvos(18.0), watchos(11.0));
 
 // Call undoMenuItemTitle or redoMenuItemTitle to get the string for the undo or redo menu item.
 // In English they will return "Undo <action name>"/"Redo <action name>" or "Undo"/"Redo" if there is
Clone this wiki locally