nsIFileSpec

IID:37ef2e71-edef-46c7-acd9-f0b6e0b15083
Inherits From:nsISupports

This interface is implemented by the following components:


Properties

readonly PRInt64 diskSpaceAvailable

char* fileContents

readonly PRUint32 fileSize

readonly nsFileSpec fileSpec

readonly nsIInputStream inputStream

char* leafName

readonly PRUint32 modDate

char* nativePath

readonly char* NSPRPath

readonly nsIOutputStream outputStream

readonly nsIFileSpec parent

char* persistentDescriptorString

AString unicodePath

char* unixStyleFilePath

char* URLString


Methods

void appendRelativeUnixPath ( char* relativePath ) void closeStream ( ) void copyToDir ( nsIFileSpec newParentDir ) void createDir ( ) void delete ( PRBool recursive ) void endLine ( ) PRBool eof ( ) PRBool equals ( nsIFileSpec spec ) void error ( ) void execute ( char* args ) PRBool exists ( ) PRBool failed ( ) void flush ( ) void fromFileSpec ( nsIFileSpec original ) PRBool isChildOf ( nsIFileSpec possibleParent ) PRBool isDirectory ( ) PRBool isFile ( ) PRBool isHidden ( ) PRBool isStreamOpen ( ) PRBool isSymlink ( ) PRBool isValid ( ) void makeUnique ( ) void makeUniqueDir ( ) void makeUniqueDirWithSuggestedName ( char* suggestedName ) void makeUniqueWithSuggestedName ( char* suggestedName ) PRBool modDateChanged ( PRUint32 oldStamp ) void moveToDir ( nsIFileSpec newParentDir ) void openStreamForReading ( ) void openStreamForReadingAndWriting ( ) void openStreamForWriting ( ) PRInt32 read ( inout char* buffer , PRInt32 requestedCount ) void readLine ( inout char* line , PRInt32 bufferSize , out PRBool wasTruncated ) void rename ( char* newLeafName ) void resolveSymlink ( ) void seek ( PRInt32 offset ) [noscript] void setFromFileSpec ( nsFileSpecRef spec ) PRInt32 tell ( ) void touch ( ) void truncate ( PRInt32 newLength ) PRInt32 write ( char* data , PRInt32 requestedCount )

void appendRelativeUnixPath ( char* relativePath )

Arguments:
relativePath

void closeStream ( )


void copyToDir ( nsIFileSpec newParentDir )

Arguments:
newParentDir

void createDir ( )


void delete ( PRBool recursive )

Arguments:
recursive

void endLine ( )


PRBool eof ( )


PRBool equals ( nsIFileSpec spec )

Arguments:
spec

void error ( )


void execute ( char* args )

Arguments:
args

PRBool exists ( )


PRBool failed ( )


void flush ( )


void fromFileSpec ( nsIFileSpec original )

Arguments:
original

PRBool isChildOf ( nsIFileSpec possibleParent )

Arguments:
possibleParent

PRBool isDirectory ( )


PRBool isFile ( )


PRBool isHidden ( )


PRBool isStreamOpen ( )


PRBool isSymlink ( )


PRBool isValid ( )


void makeUnique ( )


void makeUniqueDir ( )


void makeUniqueDirWithSuggestedName ( char* suggestedName )

Arguments:
suggestedName

void makeUniqueWithSuggestedName ( char* suggestedName )

Arguments:
suggestedName

PRBool modDateChanged ( PRUint32 oldStamp )

Arguments:
oldStamp

void moveToDir ( nsIFileSpec newParentDir )

Arguments:
newParentDir

void openStreamForReading ( )


void openStreamForReadingAndWriting ( )


void openStreamForWriting ( )


PRInt32 read ( inout char* buffer , PRInt32 requestedCount )

Arguments:
buffer
requestedCount

void readLine ( inout char* line , PRInt32 bufferSize , out PRBool wasTruncated )

Arguments:
line
bufferSize
wasTruncated

void rename ( char* newLeafName )

Arguments:
newLeafName

void resolveSymlink ( )


void seek ( PRInt32 offset )

Arguments:
offset

void setFromFileSpec ( nsFileSpecRef spec )

Arguments:
spec

PRInt32 tell ( )


void touch ( )


void truncate ( PRInt32 newLength )

Arguments:
newLength

PRInt32 write ( char* data , PRInt32 requestedCount )

Check eof() before each call. CAUTION: false result only indicates line was truncated to fit buffer, or an error occurred (OTHER THAN eof).

Arguments:
data
requestedCount

References

This interface is the type of the following properties:

nsIDirectoryIterator.currentSpec, nsIFileSpec.parent, nsIImapUrl.msgFileSpec, nsIImportABDescriptor.fileSpec, nsIImportMailboxDescriptor.fileSpec, nsIMsgFilterList.defaultFile, nsIMsgFolder.path, nsIMsgIncomingServer.localPath, nsIMsgMessageUrl.messageFile, nsIMsgProtocolInfo.defaultLocalPath, nsINNTPNewsgroupPost.postMessageFile, nsINntpIncomingServer.newsrcFilePath, nsINntpIncomingServer.newsrcRootPath, nsISmtpUrl.PostMessageFile

This interface is passed as an argument to the following methods:

nsIAbLDIFService.importLDIFFile, nsIAbLDIFService.isLDIFFile, nsIAbUpgrader.StartUpgrade4xAddrBook, nsIAddressBook.convertNA2toLDIF, nsIAddressBook.migrate4xAb, nsIDirectoryIterator.init, nsIFileSpec.copyToDir, nsIFileSpec.equals, nsIFileSpec.fromFileSpec, nsIFileSpec.isChildOf, nsIFileSpec.moveToDir, nsIImapService.appendMessageFromFile, nsIImportAddressBooks.FindAddressBooks, nsIImportAddressBooks.GetDefaultLocation, nsIImportAddressBooks.GetNeedsFieldMap, nsIImportAddressBooks.InitFieldMap, nsIImportAddressBooks.SetSampleLocation, nsIImportMail.FindMailboxes, nsIImportMail.GetDefaultLocation, nsIImportMail.ImportMailbox, nsIImportMimeEncode.EncodeFile, nsIImportMimeEncode.Initialize, nsIImportSettings.AutoLocate, nsIImportSettings.SetLocation, nsILocalMailIncomingServer.createDefaultMailboxes, nsIMsgCopyService.CopyFileMessage, nsIMsgDBService.openMailDBFromFileSpec, nsIMsgDatabase.Open, nsIMsgFilterService.OpenFilterList, nsIMsgFilterService.SaveFilterList, nsIMsgFolder.copyFileMessage, nsIMsgFolderCache.Init, nsIMsgIncomingServer.SetDefaultLocalPath, nsIMsgIncomingServer.setFileValue, nsIMsgMailNewsUrl.getSaveAsListener, nsIMsgMessageService.SaveMessageToDisk, nsIMsgSend.notifyListenerOnStopSending, nsIMsgSend.sendMessageFile, nsIMsgSendListener.onStopSending, nsINntpService.postMessage, nsINoIncomingServer.copyDefaultMessages, nsIPref.SetFilePref, nsISmtpService.SendMailMessage

This interface is returned from the following methods:

nsIMsgIncomingServer.getFileValue, nsIPref.GetFilePref

Reference documentation is generated from Mozilla's source.

Add a note User Contributed Notes
No comments available

Copyright © 1999 - 2005 XULPlanet.com