SCCameraKitLensRepositorySpecificObserver
Objective-C
@protocol SCCameraKitLensRepositorySpecificObserver <NSObject>
Swift
protocol LensRepositorySpecificObserver : NSObjectProtocol
Allows conformers to be notified of changes to specific lenses in groups the repository has available.
-
Notifies that an observed specific lens in a group has changed.
Declaration
Objective-C
- (void)repository:(nonnull id<SCCameraKitLensRepository>)repository didUpdateLens:(nonnull id<SCCameraKitLens>)lens forGroupID:(nonnull NSString *)groupID;Swift
func repository(_ repository: any SCCameraKitLensRepository, didUpdate lens: any SCCameraKitLens, forGroupID groupID: String)Parameters
repositorythe CameraKit lens repository responsible for the update.
lensthe newly updated lens object.
groupIDthe updated group ID.
-
Notifies that an observed specific lens in a group has failed to be fetched.
Declaration
Objective-C
- (void)repository:(nonnull id<SCCameraKitLensRepository>)repository didFailToUpdateLensID:(nonnull NSString *)lensID forGroupID:(nonnull NSString *)groupID error:(nullable NSError *)error;Swift
func repository(_ repository: any SCCameraKitLensRepository, didFailToUpdateLensID lensID: String, forGroupID groupID: String, error: (any Error)?)Parameters
repositorythe CameraKit lens repository responsible for the update.
lensIDthe lens ID that failed to update.
groupIDthe group ID that failed to update.
errora detailed error message of what went wrong, if available.