MonobjcMonobjc Documented Class Library
SetAttributesOfItemAtPathError Method (attributes, path, error)
NamespacesMonobjc.FoundationNSFileManagerSetAttributesOfItemAtPathError(NSDictionary, NSString, NSError%)

Sets the attributes of a given file or directory.

Original signature is '- (BOOL)setAttributes:(NSDictionary *)attributes ofItemAtPath:(NSString *)path error:(NSError **)error'

Available in Mac OS X v10.5 and later.

Declaration Syntax
C#Visual BasicVisual C++
public virtual bool SetAttributesOfItemAtPathError(
	NSDictionary attributes,
	NSString path,
	out NSError error
)
Public Overridable Function SetAttributesOfItemAtPathError ( _
	attributes As NSDictionary, _
	path As NSString, _
	<OutAttribute> ByRef error As NSError _
) As Boolean
public:
virtual bool SetAttributesOfItemAtPathError(
	NSDictionary^ attributes, 
	NSString^ path, 
	[OutAttribute] NSError^% error
)
Parameters
attributes (NSDictionary)
A dictionary containing as keys the attributes to set for path and as values the corresponding value for the attribute. You can set the following attributes: NSFileBusy, NSFileCreationDate, NSFileExtensionHidden, NSFileGroupOwnerAccountID, NSFileGroupOwnerAccountName, NSFileHFSCreatorCode, NSFileHFSTypeCode, NSFileImmutable, NSFileModificationDate, NSFileOwnerAccountID, NSFileOwnerAccountName, NSFilePosixPermissions. You can change single attributes or any combination of attributes; you need not specify keys for all attributes.
path (NSString)
The path of a file or directory.
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
YES if all changes succeed. If any change fails, returns NO, but it is undefined whether any changes actually occurred.
Version Information
  • Available in Monobjc Bridge: 10.6 (For Mac OS X 10.6 and later), 10.5 (For Mac OS X 10.5 and later)

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