/NSPair

Foundation API suggestion for a NSPair class.

Primary LanguageObjective-C

NSPair

Build Status Coverage Status Issues Status License Contact
Donate-Patreon Donate-Gratipay Donate-Paypal

About

Feature request for a NSPair object in Apple's Foundation framework:
http://openradar.appspot.com/radar?id=5050086249725952

Proposed interface:

NS_ASSUME_NONNULL_BEGIN

@interface NSPair< __covariant FirstType, __covariant SecondType >: NSObject < NSCoding, NSCopying >

@property( atomic, readwrite, strong, nullable ) FirstType  first;
@property( atomic, readwrite, strong, nullable ) SecondType second;

- ( instancetype )initWithFirstValue: ( nullable FirstType )first secondValue: ( nullable SecondType )second NS_DESIGNATED_INITIALIZER;

@end

NS_ASSUME_NONNULL_END

License

NSPair is released under the terms of the MIT license.

Repository Infos

Owner:          Jean-David Gadina - XS-Labs
Web:            www.xs-labs.com
Blog:           www.noxeos.com
Twitter:        @macmade
GitHub:         github.com/macmade
LinkedIn:       ch.linkedin.com/in/macmade/
StackOverflow:  stackoverflow.com/users/182676/macmade