Skip to content

Photos macOS xcode15.0 b1

Haritha Mohan edited this page Sep 6, 2023 · 3 revisions

#Photos.framework https://github.com/xamarin/xamarin-macios/pull/18941

diff -ruN /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHAsset.h /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHAsset.h
--- /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHAsset.h	2023-03-09 19:17:25
+++ /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHAsset.h	2023-05-31 04:03:27
@@ -21,6 +21,7 @@
 API_AVAILABLE_BEGIN(macos(10.13), ios(8), tvos(10))
 
 OS_EXPORT
+NS_SWIFT_SENDABLE
 @interface PHAsset : PHObject
 
 #pragma mark - Properties
diff -ruN /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHChange.h /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHChange.h
--- /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHChange.h	2023-03-09 19:09:41
+++ /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHChange.h	2023-05-31 09:17:19
@@ -16,6 +16,7 @@
 API_AVAILABLE_BEGIN(macos(10.13), ios(8), tvos(10))
 
 OS_EXPORT
+NS_SWIFT_SENDABLE
 @interface PHChange : NSObject
 
 - (nullable PHObjectChangeDetails *)changeDetailsForObject:(PHObject *)object;
@@ -26,6 +27,7 @@
 
 #pragma mark -
 OS_EXPORT
+NS_SWIFT_SENDABLE
 @interface PHObjectChangeDetails<ObjectType: PHObject *> : NSObject
 
 // returns the object that was passed in to changeDetailsForObject: (used to determine the changes to the object vs. the objectAfterChanges)
@@ -45,6 +47,7 @@
 
 #pragma mark -
 OS_EXPORT
+NS_SWIFT_SENDABLE
 @interface PHFetchResultChangeDetails<ObjectType: PHObject *> : NSObject
 
 // fetch result with the state of the fetched objects before this change (returns the fetch result passed in to changeDetailsForFetchResult:)
diff -ruN /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHCloudIdentifier.h /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHCloudIdentifier.h
--- /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHCloudIdentifier.h	2023-03-09 23:53:51
+++ /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHCloudIdentifier.h	2023-05-31 09:17:19
@@ -13,6 +13,7 @@
 
 
 OS_EXPORT
+NS_SWIFT_SENDABLE
 @interface PHCloudIdentifier : NSObject <NSSecureCoding>
 
 /// DEPRECATED: If there is a failure to determine the global identifier for a local identifier, the notFoundIdentifier is provided in that array slot.
@@ -32,6 +33,7 @@
 
 /// Contains the cloud identifier result from looking up a local identifier via \c cloudIdentifierMappingsForLocalIdentifiers, or an \c error indicating why the lookup failed
 OS_EXPORT NS_REFINED_FOR_SWIFT
+NS_SWIFT_SENDABLE
 @interface PHCloudIdentifierMapping : NSObject
 @property (nonatomic, readonly, nullable) PHCloudIdentifier *cloudIdentifier; /// The cloud identifier of the resource found for this local identifier
 @property (nonatomic, readonly, nullable) NSError *error; /// error An error indicating why the \c cloudIdentifier is nil. \c PHPhotosErrorIdentifierNotFound if no resource could be found for the provided local identifier.
@@ -39,6 +41,7 @@
 
 /// Contains the local identifier result from looking up a cloud identifier via \c localIdentifierMappingsForCloudIdentifiers, or an \c error indicating why the lookup failed
 OS_EXPORT NS_REFINED_FOR_SWIFT
+NS_SWIFT_SENDABLE
 @interface PHLocalIdentifierMapping : NSObject
 @property (nonatomic, readonly, nullable) NSString *localIdentifier; /// The \c NSString representing the local identifier of the resource found for this cloud identifier, or nil if the match was not found.
 @property (nonatomic, readonly, nullable) NSError *error; /// An error indicating why the \c localIdentifier is nil. \c PHPhotosErrorIdentifierNotFound if no resource could be found for the provided cloud identifier. \c PHPhotosErrorMultipleLocalIdentifiersFound if the cloud identifier matched more than one photo library resource, so there were multiple local identifiers found. The array of matching local identifiers can be retrieved from the error's user info via the \c PHLocalIdentifiersErrorKey
diff -ruN /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHCollection.h /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHCollection.h
--- /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHCollection.h	2023-03-09 23:50:45
+++ /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHCollection.h	2023-05-31 05:44:50
@@ -16,6 +16,7 @@
 API_AVAILABLE_BEGIN(macos(10.15), ios(8), tvos(10))
 
 OS_EXPORT API_AVAILABLE(macos(10.13))
+NS_SWIFT_SENDABLE
 @interface PHCollection : PHObject
 
 @property (nonatomic, assign, readonly) BOOL canContainAssets;
@@ -37,6 +38,7 @@
 
 #pragma mark -
 OS_EXPORT API_AVAILABLE(macos(10.13))
+NS_SWIFT_SENDABLE
 @interface PHAssetCollection : PHCollection
 
 @property (nonatomic, assign, readonly) PHAssetCollectionType assetCollectionType;
@@ -87,6 +89,7 @@
 
 #pragma mark -
 OS_EXPORT API_AVAILABLE(macos(10.13))
+NS_SWIFT_SENDABLE
 @interface PHCollectionList : PHCollection
 
 @property (nonatomic, assign, readonly) PHCollectionListType collectionListType;
diff -ruN /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHContentEditingOutput.h /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHContentEditingOutput.h
--- /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHContentEditingOutput.h	2023-03-09 19:09:40
+++ /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHContentEditingOutput.h	2023-05-31 09:17:19
@@ -7,7 +7,7 @@
 
 #import <Foundation/Foundation.h>
 
-@class PHContentEditingInput, PHAdjustmentData;
+@class PHContentEditingInput, PHAdjustmentData, UTType;
 
 NS_ASSUME_NONNULL_BEGIN
 API_AVAILABLE_BEGIN(macos(10.11), ios(8), tvos(10))
@@ -19,8 +19,17 @@
 
 @property (readwrite, strong, nullable) PHAdjustmentData *adjustmentData;
 
-// File URL where the rendered output, with adjustments baked-in, needs to be written to.
+/// File URL where the rendered output in the default format, with adjustments baked-in, needs to be written to.
 @property (readonly, copy) NSURL *renderedContentURL;
+
+/// Returns the default type for the rendered content output
+@property (readonly, copy, nullable) UTType *defaultRenderedContentType API_AVAILABLE(macos(14), ios(17), tvos(17));
+
+/// Returns the supported types for the rendered content output
+@property (readonly, copy) NSArray<UTType *> *supportedRenderedContentTypes API_AVAILABLE(macos(14), ios(17), tvos(17));
+
+/// Returns a file URL where the rendered output in the specified format, with adjustments baked-in, needs to be written to. Returns nil and provides an error identifying the reason if the format is unsupported or the requested content URL cannot be provided
+- (nullable NSURL *)renderedContentURLForType:(UTType *)type error:(NSError * __autoreleasing *)error API_AVAILABLE(macos(14), ios(17), tvos(17));
 
 @end
 
diff -ruN /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHFetchResult.h /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHFetchResult.h
--- /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHFetchResult.h	2023-03-09 19:09:40
+++ /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHFetchResult.h	2023-05-31 09:17:19
@@ -14,6 +14,7 @@
 // Accessing fetched results (fetches objects from the backing store in chunks on demand rather than all at once)
 // Fetched objects will be kept in a cache and purged under memory pressure
 OS_EXPORT
+NS_SWIFT_SENDABLE
 @interface PHFetchResult<__covariant ObjectType> : NSObject <NSCopying, NSFastEnumeration>
 
 @property (readonly) NSUInteger count;
diff -ruN /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHImageManager.h /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHImageManager.h
--- /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHImageManager.h	2023-03-09 19:09:40
+++ /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHImageManager.h	2023-05-31 09:17:19
@@ -62,6 +62,7 @@
 @property (nonatomic, assign, getter=isNetworkAccessAllowed) BOOL networkAccessAllowed; // if necessary will download the image from iCloud (client can monitor or cancel using progressHandler). Defaults to NO (see start/stopCachingImagesForAssets)
 @property (nonatomic, assign, getter=isSynchronous) BOOL synchronous; // return only a single result, blocking until available (or failure). Defaults to NO
 @property (nonatomic, copy, nullable) PHAssetImageProgressHandler progressHandler; // provide caller a way to be told how much progress has been made prior to delivering the data when it comes from iCloud. Defaults to nil, shall be set by caller
+@property (nonatomic) BOOL allowSecondaryDegradedImage API_AVAILABLE(macos(14), ios(17), tvos(17)); // in addition to the initial degraded result, an additional degraded result will be returned if conditions permit
 
 @end
 
@@ -101,7 +102,7 @@
 typedef void (^PHAssetVideoProgressHandler)(double progress, NSError *__nullable error, BOOL *stop, NSDictionary *__nullable info);
 
 OS_EXPORT
-@interface PHVideoRequestOptions : NSObject
+@interface PHVideoRequestOptions : NSObject <NSCopying>
 
 @property (nonatomic, assign, getter=isNetworkAccessAllowed) BOOL networkAccessAllowed;
 @property (nonatomic, assign) PHVideoRequestOptionsVersion version;
diff -ruN /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHObject.h /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHObject.h
--- /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHObject.h	2023-03-09 19:09:41
+++ /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHObject.h	2023-05-31 09:17:19
@@ -14,6 +14,7 @@
 
 
 OS_EXPORT
+NS_SWIFT_SENDABLE
 @interface PHObject : NSObject <NSCopying>
 
 // Returns an identifier which persistently identifies the object on a given device
@@ -23,6 +24,7 @@
 
 // PHObjectPlaceholder represents a model object future , vended by change requests when creating a model object.  PHObjectPlaceholder is a read-only object and may be used as a proxy for the real object that will be created both inside and outside of the change block.  Will compare isEqual: to the fetched model object after the change block is performed.
 OS_EXPORT API_AVAILABLE(macos(10.15))
+NS_SWIFT_SENDABLE
 @interface PHObjectPlaceholder : PHObject
 @end
 
diff -ruN /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHPersistentChange.h /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHPersistentChange.h
--- /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHPersistentChange.h	2023-03-09 19:09:39
+++ /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHPersistentChange.h	2023-05-31 09:17:19
@@ -14,6 +14,7 @@
 @class PHPersistentObjectChangeDetails;
 
 API_AVAILABLE(macosx(13), ios(16), tvos(16))
+NS_SWIFT_SENDABLE
 @interface PHPersistentChange : NSObject
 
 + (instancetype)new NS_UNAVAILABLE;
diff -ruN /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHPersistentChangeToken.h /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHPersistentChangeToken.h
--- /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHPersistentChangeToken.h	2023-03-09 19:09:39
+++ /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHPersistentChangeToken.h	2023-05-31 09:17:19
@@ -10,6 +10,7 @@
 
 API_AVAILABLE(macos(13), ios(16), tvos(16))
 
+NS_SWIFT_SENDABLE
 @interface PHPersistentChangeToken : NSObject <NSCopying, NSSecureCoding>
 
 + (instancetype)new NS_UNAVAILABLE;
diff -ruN /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHPersistentObjectChangeDetails.h /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHPersistentObjectChangeDetails.h
--- /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHPersistentObjectChangeDetails.h	2023-03-09 19:09:40
+++ /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHPersistentObjectChangeDetails.h	2023-05-31 09:17:19
@@ -13,6 +13,7 @@
 @class PHObject;
 
 API_AVAILABLE(macosx(13), ios(16), tvos(16))
+NS_SWIFT_SENDABLE
 @interface PHPersistentObjectChangeDetails : NSObject
 
 @property (nonatomic, readonly) PHObjectType objectType;
diff -ruN /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHPhotoLibrary.h /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHPhotoLibrary.h
--- /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHPhotoLibrary.h	2023-03-09 19:14:11
+++ /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHPhotoLibrary.h	2023-05-31 09:17:19
@@ -53,6 +53,7 @@
  */
 #pragma mark -
 OS_EXPORT
+NS_SWIFT_SENDABLE
 @interface PHPhotoLibrary : NSObject
 
 + (PHPhotoLibrary *)sharedPhotoLibrary;
diff -ruN /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHProjectChangeRequest.h /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHProjectChangeRequest.h
--- /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHProjectChangeRequest.h	2023-03-09 19:09:40
+++ /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PHProjectChangeRequest.h	2023-05-31 09:17:19
@@ -33,7 +33,7 @@
 /**
  The projectExtensionData property is intended for storage of compressed, project specific data
  only. Do not include things like rasterized images that can be locally cached in this data. The
- total size of stored data is limited to 1 MB. Attempting to store more data than allowed will result
+ total size of stored data is limited to 5 MB. Attempting to store more data than allowed will result
  in an error.
  */
 @property (nonatomic, copy, readwrite) NSData *projectExtensionData;
diff -ruN /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PhotosTypes.h /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PhotosTypes.h
--- /Applications/Xcode_14.3.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PhotosTypes.h	2023-03-09 23:50:46
+++ /Applications/Xcode_15.0.0-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Photos.framework/Headers/PhotosTypes.h	2023-05-31 05:20:10
@@ -176,6 +176,7 @@
     PHAssetResourceTypeAdjustmentBasePairedVideo API_AVAILABLE(macos(10.15), ios(10)) = 11,
     PHAssetResourceTypeAdjustmentBaseVideo API_AVAILABLE(macos(10.15), ios(13)) = 12,
 
+    PHAssetResourceTypePhotoProxy API_AVAILABLE(macos(14), ios(17))= 19,
 } API_AVAILABLE(ios(9));
 
 API_AVAILABLE_END
Clone this wiki locally