home | O'Reilly's CD bookshelfs | FreeBSD | Linux | Cisco | Cisco Exam  


new

 $

folder

 
= new
(

ftype

[, 

foldername

][, 

options

])

Creates a new Mail::Folder object of the specified type. Arguments are:

ftype

The type of folder. Possible values are mbox , maildir , emaul , or NNTP .

foldername

The name of the folder. If present, the open method is called with foldername as the argument.

options

A hash where the following options may be the keys:

Content-Length

Content-length header is created or updated by append_message and update_message .

Create

If set, the folder is created if it doesn't already exist.

DefaultFolderType

Autodetects folder type if create option is set and AUTODETECT has been set.

DotLock

Uses .lock -style folder locking with the proper folder interface (currently used only with the mbox interface).

Flock

Uses flock-style folder locking with the proper folder interface (currently used only with the mbox interface).

NFSLock

Deals with NFS-style file locking with the proper folder interface and the NFS server in question.

notMUA

If set, makes updates but doesn't save message labels or the current message indicator. If not set (the default), saves labels and the current message indicator as appropriate for the folder interface.

Timeout

Overrides the default timeout value. Specified in seconds. Particularly useful for folder interfaces that involve network communications.