Cargo Features

[dependencies]
objc2-foundation = { version = "0.2.2", default-features = false, features = ["std", "alloc", "all", "apple", "gnustep-1-7", "gnustep-1-8", "gnustep-1-9", "gnustep-2-0", "gnustep-2-1", "unstable-static-nsstring", "dispatch", "bitflags", "block2", "libc", "NSAffineTransform", "NSAppleEventDescriptor", "NSArchiver", "NSArray", "NSAttributedString", "NSBundle", "NSByteCountFormatter", "NSCache", "NSCalendar", "NSCoder", "NSComparisonPredicate", "NSConnection", "NSData", "NSDate", "NSDateComponentsFormatter", "NSDecimal", "NSDecimalNumber", "NSDictionary", "NSDistributedLock", "NSDistributedNotificationCenter", "NSEnergyFormatter", "NSEnumerator", "NSError", "NSExtensionItem", "NSExtensionRequestHandling", "NSFileCoordinator", "NSFileHandle", "NSFileManager", "NSFilePresenter", "NSFileWrapper", "NSGarbageCollector", "NSGeometry", "NSHashTable", "NSHost", "NSISO8601DateFormatter", "NSInvocation", "NSJSONSerialization", "NSKeyValueCoding", "NSKeyValueObserving", "NSLengthFormatter", "NSLinguisticTagger", "NSLock", "NSMapTable", "NSMeasurement", "NSMeasurementFormatter", "NSMorphology", "NSNetServices", "NSNotification", "NSNotificationQueue", "NSNumberFormatter", "NSObjCRuntime", "NSObject", "NSOrderedCollectionChange", "NSOrderedCollectionDifference", "NSOrthography", "NSPathUtilities", "NSPersonNameComponents", "NSPersonNameComponentsFormatter", "NSPointerArray", "NSPointerFunctions", "NSPort", "NSPredicate", "NSProcessInfo", "NSProgress", "NSPropertyList", "NSRange", "NSRegularExpression", "NSScanner", "NSScriptCommand", "NSScriptExecutionContext", "NSScriptObjectSpecifiers", "NSScriptSuiteRegistry", "NSScriptWhoseTests", "NSSet", "NSSpellServer", "NSStream", "NSString", "NSTermOfAddress", "NSTextCheckingResult", "NSThread", "NSTimer", "NSURL", "NSURLConnection", "NSURLError", "NSURLRequest", "NSUbiquitousKeyValueStore", "NSUserDefaults", "NSValueTransformer", "NSXMLNode", "NSXMLNodeOptions", "NSXMLParser", "NSXPCConnection", "NSZone"] }
default = std

The std feature is set by default whenever objc2-foundation is added without default-features = false somewhere in the dependency tree.

std default = alloc

Currently not possible to turn off, put here for forwards compatibility.

Enables std of optional bitflags, optional block2, optional libc, and objc2

alloc std

Enables alloc of optional block2 and objc2

all = FoundationErrors, FoundationLegacySwiftCompatibility, NSAffineTransform, NSAppleEventDescriptor, NSAppleEventManager, NSAppleScript, NSArchiver, NSArray, NSAttributedString, NSAutoreleasePool, NSBackgroundActivityScheduler, NSBundle, NSByteCountFormatter, NSByteOrder, NSCache, NSCalendar, NSCalendarDate, NSCharacterSet, NSClassDescription, NSCoder, NSComparisonPredicate, NSCompoundPredicate, NSConnection, NSData, NSDate, NSDateComponentsFormatter, NSDateFormatter, NSDateInterval, NSDateIntervalFormatter, NSDecimal, NSDecimalNumber, NSDictionary, NSDistantObject, NSDistributedLock, NSDistributedNotificationCenter, NSEnergyFormatter, NSEnumerator, NSError, NSException, NSExpression, NSExtensionContext, NSExtensionItem, NSExtensionRequestHandling, NSFileCoordinator, NSFileHandle, NSFileManager, NSFilePresenter, NSFileVersion, NSFileWrapper, NSFormatter, NSGarbageCollector, NSGeometry, NSHFSFileTypes, NSHTTPCookie, NSHTTPCookieStorage, NSHashTable, NSHost, NSISO8601DateFormatter, NSIndexPath, NSIndexSet, NSInflectionRule, NSInvocation, NSItemProvider, NSJSONSerialization, NSKeyValueCoding, NSKeyValueObserving, NSKeyedArchiver, NSLengthFormatter, NSLinguisticTagger, NSListFormatter, NSLocale, NSLock, NSMapTable, NSMassFormatter, NSMeasurement, NSMeasurementFormatter, NSMetadata, NSMetadataAttributes, NSMethodSignature, NSMorphology, NSNetServices, NSNotification, NSNotificationQueue, NSNull, NSNumberFormatter, NSObjCRuntime, NSObject, NSObjectScripting, NSOperation, NSOrderedCollectionChange, NSOrderedCollectionDifference, NSOrderedSet, NSOrthography, NSPathUtilities, NSPersonNameComponents, NSPersonNameComponentsFormatter, NSPointerArray, NSPointerFunctions, NSPort, NSPortCoder, NSPortMessage, NSPortNameServer, NSPredicate, NSProcessInfo, NSProgress, NSPropertyList, NSProtocolChecker, NSProxy, NSRange, NSRegularExpression, NSRelativeDateTimeFormatter, NSRunLoop, NSScanner, NSScriptClassDescription, NSScriptCoercionHandler, NSScriptCommand, NSScriptCommandDescription, NSScriptExecutionContext, NSScriptKeyValueCoding, NSScriptObjectSpecifiers, NSScriptStandardSuiteCommands, NSScriptSuiteRegistry, NSScriptWhoseTests, NSSet, NSSortDescriptor, NSSpellServer, NSStream, NSString, NSTask, NSTermOfAddress, NSTextCheckingResult, NSThread, NSTimeZone, NSTimer, NSURL, NSURLAuthenticationChallenge, NSURLCache, NSURLConnection, NSURLCredential, NSURLCredentialStorage, NSURLDownload, NSURLError, NSURLHandle, NSURLProtectionSpace, NSURLProtocol, NSURLRequest, NSURLResponse, NSURLSession, NSUUID, NSUbiquitousKeyValueStore, NSUndoManager, NSUnit, NSUserActivity, NSUserDefaults, NSUserNotification, NSUserScriptTask, NSValue, NSValueTransformer, NSXMLDTD, NSXMLDTDNode, NSXMLDocument, NSXMLElement, NSXMLNode, NSXMLNodeOptions, NSXMLParser, NSXPCConnection, NSZone, bitflags, block2, libc
apple
gnustep-1-7 gnustep-1-8?

Enables gnustep-1-7 of optional block2 and objc2

block2:

Link to GNUStep's libobjc2 (which contains the block implementation).

gnustep-1-8 gnustep-1-9? = gnustep-1-7

Enables gnustep-1-8 of optional block2 and objc2

gnustep-1-9 gnustep-2-0? = gnustep-1-8

Enables gnustep-1-9 of optional block2 and objc2

gnustep-2-0 gnustep-2-1? = gnustep-1-9

Enables gnustep-2-0 of optional block2 and objc2

gnustep-2-1 = gnustep-2-0

Enables gnustep-2-1 of optional block2 and objc2

unstable-static-nsstring
dispatch

Enables dispatch

Affects thread::run_on_main, thread::MainThreadBound

bitflags NSAppleEventDescriptor? NSArray? NSAttributedString? NSByteCountFormatter? NSCalendar? NSComparisonPredicate? NSData? NSDateComponentsFormatter? NSDistributedNotificationCenter? NSFileCoordinator? NSFileManager? NSFileVersion? NSFileWrapper? NSGeometry? NSISO8601DateFormatter? NSItemProvider? NSJSONSerialization? NSKeyValueObserving? NSLinguisticTagger? NSMeasurementFormatter? NSNetServices? NSNotificationQueue? NSObjCRuntime? NSOrderedCollectionDifference? NSPathUtilities? NSPersonNameComponentsFormatter? NSPointerFunctions? NSPort? NSProcessInfo? NSPropertyList? NSRegularExpression? NSStream? NSString? NSTextCheckingResult? NSURL? NSXMLNodeOptions? NSXPCConnection? all?

Enables bitflags

block2 all?

Enables block2

Affects NSBackgroundActivityScheduler::NSBackgroundActivityCompletionHandler, NSObjCRuntime::NSComparator, NSProgress::NSProgressUnpublishingHandler, NSProgress::NSProgressPublishingHandler, NSUserScriptTask::NSUserScriptTaskCompletionHandler, NSUserScriptTask::NSUserUnixTaskCompletionHandler, NSUserScriptTask::NSUserAutomatorTaskCompletionHandler, NSItemProvider::NSItemProviderCompletionHandler, NSUserScriptTask::NSUserAppleScriptTaskCompletionHandler, NSItemProvider::NSItemProviderLoadHandler

libc all?

Enables libc

FoundationErrors FoundationLegacySwiftCompatibility NSAffineTransform all?
NSAppleEventDescriptor all? = bitflags

Affects NSUserScriptTask::NSUserAppleScriptTaskCompletionHandler

NSAppleEventManager NSAppleScript NSArchiver all?
NSArray all? = bitflags

Affects NSHashTable::NSAllHashTableObjects, NSMapTable::NSAllMapTableKeys, NSMapTable::NSAllMapTableValues, objc2-foundation::array, NSPathUtilities::NSSearchPathForDirectoriesInDomains

NSAttributedString all? = bitflags
NSAutoreleasePool NSBackgroundActivityScheduler NSBundle all?
NSByteCountFormatter all? = bitflags
NSByteOrder NSCache all?
NSCalendar all? = bitflags
NSCalendarDate NSCharacterSet NSClassDescription NSCoder all?
NSComparisonPredicate all? = bitflags
NSCompoundPredicate NSConnection all?
NSData all? = bitflags
NSDate all?
NSDateComponentsFormatter all? = bitflags
NSDateFormatter NSDateInterval NSDateIntervalFormatter NSDecimal all?
NSDecimalNumber all?
NSDictionary all?

Affects objc2-foundation::dictionary, NSItemProvider::NSItemProviderLoadHandler

NSDistantObject NSDistributedLock all?
NSDistributedNotificationCenter all? = bitflags
NSEnergyFormatter all?
NSEnumerator all?

Affects array::Iter, array::IterMut, array::IterRetained, array::IntoIter, objc2-foundation::enumerator, set::Iter, set::IterRetained, set::IntoIter

NSError all?

Affects NSNetServices::NSNetServicesErrorDomain, NSStream::NSStreamSocketSSLErrorDomain, NSStream::NSStreamSOCKSErrorDomain, NSURLError::NSURLErrorDomain, NSURLError::NSURLErrorNetworkUnavailableReasonKey, NSUserScriptTask::NSUserScriptTaskCompletionHandler, NSUserScriptTask::NSUserUnixTaskCompletionHandler, NSUserScriptTask::NSUserAutomatorTaskCompletionHandler, NSXMLParser::NSXMLParserErrorDomain, NSItemProvider::NSItemProviderCompletionHandler, NSUserScriptTask::NSUserAppleScriptTaskCompletionHandler, NSItemProvider::NSItemProviderLoadHandler

NSException NSExpression NSExtensionContext NSExtensionItem all?
NSExtensionRequestHandling all?
NSFileCoordinator all? = bitflags
NSFileHandle all?
NSFileManager all? = bitflags
NSFilePresenter all?
NSFileVersion NSFileWrapper all? = bitflags
NSFormatter NSGarbageCollector all?
NSGeometry all? = bitflags

Affects NSAffineTransform::NSAffineTransformStruct

NSHFSFileTypes NSHTTPCookie NSHTTPCookieStorage NSHashTable all?
NSHost all?
NSISO8601DateFormatter all? = bitflags
NSIndexPath NSIndexSet NSInflectionRule NSInvocation all?
NSItemProvider NSJSONSerialization all? = bitflags
NSKeyValueCoding all?
NSKeyValueObserving all? = bitflags
NSKeyedArchiver NSLengthFormatter all?
NSLinguisticTagger all? = bitflags
NSListFormatter NSLocale NSLock all?
NSMapTable all?

Affects ns_consumed::NSFreeMapTable

NSMassFormatter NSMeasurement all?
NSMeasurementFormatter all? = bitflags
NSMetadata NSMetadataAttributes NSMethodSignature NSMorphology all?
NSNetServices all? = bitflags
NSNotification all?

Affects NSAppleEventManager::NSAppleEventManagerWillProcessFirstEventNotification, NSBundle::NSBundleDidLoadNotification, NSBundle::NSBundleResourceRequestLowDiskSpaceNotification, NSCalendar::NSCalendarDayChangedNotification, NSClassDescription::NSClassDescriptionNeededForClassNotification, NSDate::NSSystemClockDidChangeNotification, NSFileHandle::NSFileHandleReadCompletionNotification, NSFileHandle::NSFileHandleReadToEndOfFileCompletionNotification, NSFileHandle::NSFileHandleConnectionAcceptedNotification, NSFileHandle::NSFileHandleDataAvailableNotification, NSFileManager::NSUbiquityIdentityDidChangeNotification, NSHTTPCookieStorage::NSHTTPCookieManagerAcceptPolicyChangedNotification, NSHTTPCookieStorage::NSHTTPCookieManagerCookiesChangedNotification, NSLocale::NSCurrentLocaleDidChangeNotification, NSMetadata::NSMetadataQueryDidStartGatheringNotification, NSMetadata::NSMetadataQueryGatheringProgressNotification, NSMetadata::NSMetadataQueryDidFinishGatheringNotification, NSMetadata::NSMetadataQueryDidUpdateNotification, NSPort::NSPortDidBecomeInvalidNotification, NSProcessInfo::NSProcessInfoThermalStateDidChangeNotification

NSNotificationQueue all? = bitflags
NSNull NSNumberFormatter all?
NSObjCRuntime all? = bitflags

Affects NSDecimal::NSDecimalCompare, NSString::NSCharacterConversionException, NSString::NSParseErrorException, NSDecimalNumber::NSDecimalNumberExactnessException, NSDecimalNumber::NSDecimalNumberOverflowException, NSDecimalNumber::NSDecimalNumberUnderflowException, NSDecimalNumber::NSDecimalNumberDivideByZeroException, NSException::NSGenericException, NSException::NSRangeException, NSException::NSInvalidArgumentException, NSException::NSInternalInconsistencyException, NSException::NSMallocException, NSException::NSObjectInaccessibleException, NSException::NSObjectNotAvailableException, NSException::NSDestinationInvalidException, NSException::NSPortTimeoutException, NSException::NSInvalidSendPortException, NSException::NSInvalidReceivePortException, NSException::NSPortSendException, NSException::NSPortReceiveException

NSObject all?

Affects NSItemProvider::NSItemProviderCompletionHandler, NSItemProvider::NSItemProviderLoadHandler

NSObjectScripting NSOperation NSOrderedCollectionChange all?
NSOrderedCollectionDifference all? = bitflags
NSOrderedSet NSOrthography all?
NSPathUtilities all? = bitflags
NSPersonNameComponents all?
NSPersonNameComponentsFormatter all? = bitflags
NSPointerArray all?
NSPointerFunctions all? = bitflags

Affects NSHashTable::NSHashTableStrongMemory, NSHashTable::NSHashTableZeroingWeakMemory, NSHashTable::NSHashTableCopyIn, NSHashTable::NSHashTableObjectPointerPersonality, NSHashTable::NSHashTableWeakMemory, NSMapTable::NSMapTableStrongMemory, NSMapTable::NSMapTableZeroingWeakMemory, NSMapTable::NSMapTableCopyIn, NSMapTable::NSMapTableObjectPointerPersonality, NSMapTable::NSMapTableWeakMemory

NSPort all? = bitflags
NSPortCoder NSPortMessage NSPortNameServer NSPredicate all?
NSProcessInfo all? = bitflags
NSProgress all?
NSPropertyList all? = bitflags
NSProtocolChecker NSProxy NSRange all?
NSRegularExpression all? = bitflags
NSRelativeDateTimeFormatter NSRunLoop NSScanner all?
NSScriptClassDescription NSScriptCoercionHandler NSScriptCommand all?
NSScriptCommandDescription NSScriptExecutionContext all?
NSScriptKeyValueCoding NSScriptObjectSpecifiers all?
NSScriptStandardSuiteCommands NSScriptSuiteRegistry all?
NSScriptWhoseTests all?
NSSet all?

Affects objc2-foundation::set

NSSortDescriptor NSSpellServer all?
NSStream all? = bitflags
NSString all? = bitflags

Affects NSAppleScript::NSAppleScriptErrorMessage, NSAppleScript::NSAppleScriptErrorNumber, NSAppleScript::NSAppleScriptErrorAppName, NSAppleScript::NSAppleScriptErrorBriefMessage, NSAppleScript::NSAppleScriptErrorRange, NSAttributedString::NSAttributedStringKey, NSAttributedString::NSAttributedStringFormattingContextKey, NSAttributedString::NSInflectionConceptsKey, NSAttributedString::NSInlinePresentationIntentAttributeName, NSAttributedString::NSAlternateDescriptionAttributeName, NSAttributedString::NSImageURLAttributeName, NSAttributedString::NSLanguageIdentifierAttributeName, NSAttributedString::NSMarkdownSourcePositionAttributeName, NSAttributedString::NSReplacementIndexAttributeName, NSAttributedString::NSMorphologyAttributeName, NSAttributedString::NSInflectionRuleAttributeName, NSAttributedString::NSInflectionAgreementArgumentAttributeName, NSAttributedString::NSInflectionAgreementConceptAttributeName, NSAttributedString::NSInflectionReferentConceptAttributeName, NSAttributedString::NSInflectionAlternativeAttributeName

NSTask NSTermOfAddress all?
NSTextCheckingResult all? = bitflags
NSThread all?

Affects thread::is_multi_threaded, thread::is_main_thread, thread::run_on_main, thread::MainThreadBound

NSTimeZone NSTimer all?
NSURL all? = bitflags
NSURLAuthenticationChallenge NSURLCache NSURLConnection all?
NSURLCredential NSURLCredentialStorage NSURLDownload NSURLError all?
NSURLHandle NSURLProtectionSpace NSURLProtocol NSURLRequest all?
NSURLResponse NSURLSession NSUUID NSUbiquitousKeyValueStore all?
NSUndoManager NSUnit NSUserActivity NSUserDefaults all?
NSUserNotification NSUserScriptTask NSValue NSValueTransformer all?
NSXMLDTD NSXMLDTDNode NSXMLDocument NSXMLElement NSXMLNode all?
NSXMLNodeOptions all? = bitflags
NSXMLParser all?
NSXPCConnection all? = bitflags
NSZone all?

Affects NSHashTable::NSCopyHashTableWithZone, NSMapTable::NSCopyMapTableWithZone, NSObject::NSAllocateObject, NSObject::NSCopyObject, NSObject::NSShouldRetainWithZone, NSHashTable::NSCreateHashTableWithZone, NSMapTable::NSCreateMapTableWithZone