diff --git a/bindings/ios/MEGANotification.mm b/bindings/ios/MEGANotification.mm index 41bfa218f5..ed3d8b6387 100644 --- a/bindings/ios/MEGANotification.mm +++ b/bindings/ios/MEGANotification.mm @@ -73,6 +73,10 @@ - (nullable NSString *)imagePath { return self.megaNotification ? [[NSString alloc] initWithUTF8String:self.megaNotification->getImagePath()] : nil; } +- (nullable NSString *)iconName { + return self.megaNotification ? [[NSString alloc] initWithUTF8String:self.megaNotification->getIconName()] : nil; +} + - (nullable NSDate *)startDate { return self.megaNotification ? [[NSDate alloc] initWithTimeIntervalSince1970:self.megaNotification->getStart()] : nil; } diff --git a/bindings/ios/include/MEGANotification.h b/bindings/ios/include/MEGANotification.h index 580e202ebd..445fd53457 100644 --- a/bindings/ios/include/MEGANotification.h +++ b/bindings/ios/include/MEGANotification.h @@ -50,9 +50,6 @@ NS_ASSUME_NONNULL_BEGIN /** * @brief Get the title of this notification. * - * The caller does not take the ownership of the object. - * The object is valid as long as the current MEGANotification object is valid too. - * * @return the title of this notification. */ @property (nonatomic, readonly, nullable) NSString *title; @@ -60,9 +57,6 @@ NS_ASSUME_NONNULL_BEGIN /** * @brief Get the description for this notification. * - * The caller does not take the ownership of the object. - * The object is valid as long as the current MEGANotification object is valid too. - * * @return the description for this notification. */ @property (nonatomic, readonly, nullable) NSString *description; @@ -70,9 +64,6 @@ NS_ASSUME_NONNULL_BEGIN /** * @brief Get the image name for this notification. * - * The caller does not take the ownership of the object. - * The object is valid as long as the current MEGANotification object is valid too. - * * @return the image name for this notification. */ @property (nonatomic, readonly, nullable) NSString *imageName; @@ -80,13 +71,17 @@ NS_ASSUME_NONNULL_BEGIN /** * @brief Get the default static path of the image associated with this notification. * - * The caller does not take the ownership of the object. - * The object is valid as long as the current MEGANotification object is valid too. - * * @return the default static path of the image associated with this notification. */ @property (nonatomic, readonly, nullable) NSString *imagePath; +/** + * @brief Get the name of the icon for this notification. + * + * @return the name of the icon for this notification. + */ +@property (nonatomic, readonly, nullable) NSString *iconName; + /** * @brief Get the date of when the notification became available to the user. * @@ -112,9 +107,6 @@ NS_ASSUME_NONNULL_BEGIN * @brief Get metadata for the first call to action, represented by attributes "link" and "text", * and their corresponding values. * - * The caller does not take the ownership of the returned object. - * The returned object is valid as long as the current MEGANotification object is valid too. - * * @return metadata for the first call to action. */ @property (nonatomic, readonly, nullable) NSDictionary *firstCallToAction; @@ -123,9 +115,6 @@ NS_ASSUME_NONNULL_BEGIN * @brief Get metadata for the second call-to-action, represented by attributes "link" and "text", * and their corresponding values. * - * The caller does not take the ownership of the returned object. - * The returned object is valid as long as the current MegaNotification object is valid too. - * * @return metadata for the second call-to-action. */ @property (nonatomic, readonly, nullable) NSDictionary *secondCallToAction;