MonobjcMonobjc Documented Class Library
ContentsOfDirectoryAtURLIncludingPropertiesForKeysOptionsError Method (url, keys, mask, error)
NamespacesMonobjc.FoundationNSFileManagerContentsOfDirectoryAtURLIncludingPropertiesForKeysOptionsError(NSURL, NSArray, NSDirectoryEnumerationOptions, NSError%)

Returns the contents of a directory.

Original signature is '- (NSArray *)contentsOfDirectoryAtURL:(NSURL *)url includingPropertiesForKeys:(NSArray *)keys options:(NSDirectoryEnumerationOptions)mask error:(NSError **)error'

Available in Mac OS X v10.6 and later.

Declaration Syntax
C#Visual BasicVisual C++
public virtual NSArray ContentsOfDirectoryAtURLIncludingPropertiesForKeysOptionsError(
	NSURL url,
	NSArray keys,
	NSDirectoryEnumerationOptions mask,
	out NSError error
)
Public Overridable Function ContentsOfDirectoryAtURLIncludingPropertiesForKeysOptionsError ( _
	url As NSURL, _
	keys As NSArray, _
	mask As NSDirectoryEnumerationOptions, _
	<OutAttribute> ByRef error As NSError _
) As NSArray
public:
virtual NSArray^ ContentsOfDirectoryAtURLIncludingPropertiesForKeysOptionsError(
	NSURL^ url, 
	NSArray^ keys, 
	NSDirectoryEnumerationOptions mask, 
	[OutAttribute] NSError^% error
)
Parameters
url (NSURL)
The location of the directory for which you want an enumeration.
keys (NSArray)
On input, an array of property keys for which you would like the corresponding values. These specify the file properties that are pre-fetched for each of the files in the directory.
mask (NSDirectoryEnumerationOptions)
Options for the enumeration. Because this method only performs shallow enumeration only the NSDirectoryEnumerationSkipsHiddenFiles option should be used.
error (NSError%)
If an error occurs, upon return contains an NSError object that describes the problem. Pass NULL if you do not want error information.
Return Value
An array of NSURL objects identifying the directory entries. If the directory contains no entries, this method returns an empty array. If an error occurs, returns nil after setting error to an NSError object that describes the reason why the directory could not be enumerated.
Version Information
  • Available in Monobjc Bridge: 10.6 (For Mac OS X 10.6 and later)

Assembly: Monobjc.Foundation (Module: Monobjc.Foundation)