Ruby 1.8.7 リファレンスマニュアル > ライブラリ一覧 > net/imapライブラリ > Net::IMAPクラス
クラスの継承リスト: Net::IMAP < Object < Kernel
IMAP access class.
定義 | 説明 | |
---|---|---|
add_authenticator(auth_type, authenticator)
|
Adds an authenticator for Net::IMAP#authenticate. |
|
debug
|
Returns the debug mode. |
|
debug=(val)
|
Sets the debug mode. |
|
decode_utf7
|
||
encode_utf7
|
||
new(host, port = 143, usessl = false, certs = nil, verify = false)
|
Creates a new Net::IMAP object and connects it to the specified port on the named host. If usessl is true, then an attempt will be made to use SSL (now TLS) to connect to the server. For this to work OpenSSL[OSSL] and the Ruby OpenSSL (openssl) extension need to be installed. The certs parameter indicates the path or file containing the CA cert of the server, and the verify parameter is for the OpenSSL verification callback. |
定義 | 説明 | |
---|---|---|
add_response_handler(handler = Proc.new)
|
Adds a response handler. |
|
append(mailbox, message, flags = nil, date_time = nil)
|
Sends a APPEND command to append the message to the end of the mailbox. |
|
authenticate(auth_type, arg...)
|
Sends an AUTEHNTICATE command to authenticate the client. The auth_type parameter is a string that represents the authentication mechanism to be used. Currently Net::IMAP supports "LOGIN" and "CRAM-MD5" for the auth_type. |
|
capability
|
Sends a CAPABILITY command, and returns a listing of capabilities that the server supports. |
|
check
|
Sends a CHECK command to request a checkpoint of the currently selected mailbox. |
|
client_thread
|
The thread to receive exceptions. |
|
close
|
Sends a CLOSE command to close the currently selected mailbox. The CLOSE command permanently removes from the mailbox all messages that have the \Deleted flag set. |
|
copy(set, mailbox)
|
Sends a COPY command to copy the specified message(s) to the end of the specified destination mailbox. the set parameter is a number or an array of numbers or a Range object. the number is a message sequence number (copy) or a unique identifier (uid_copy). |
|
create(mailbox)
|
Sends a CREATE command to create a new mailbox. |
|
delete(mailbox)
|
Sends a DELETE command to remove the mailbox. |
|
disconnect
|
Disconnects from the server. |
|
disconnected?
|
Returns true if disconnected from the server. |
|
examine(mailbox)
|
Sends a EXAMINE command to select a mailbox so that messages in the mailbox can be accessed. However, the selected mailbox is identified as read-only. |
|
expunge
|
Sends a EXPUNGE command to permanently remove from the currently selected mailbox all messages that have the \Deleted flag set. |
|
fetch(set, attr)
|
Sends a FETCH command to retrieve data associated with a message in the mailbox. the set parameter is a number or an array of numbers or a Range object. the number is a message sequence number (fetch) or a unique identifier (uid_fetch). The return value is an array of Net::IMAP::FetchData. |
|
getacl(mailbox)
|
Send the GETACL command along with specified mailbox. If this mailbox exists, an array containing objects of Net::IMAP::MailboxACLItem will be returned. |
|
getquota(mailbox)
|
Sends the GETQUOTA command along with specified mailbox. If this mailbox exists, then an array containing a Net::IMAP::MailboxQuota object is returned. This command generally is only available to server admin. |
|
getquotaroot(mailbox)
|
Sends the GETQUOTAROOT command along with specified mailbox. This command is generally available to both admin and user. If mailbox exists, returns an array containing objects of Net::IMAP::MailboxQuotaRoot and Net::IMAP::MailboxQuota. |
|
greeting
|
Returns an initial greeting response from the server. |
|
list(refname, mailbox)
|
Sends a LIST command, and returns a subset of names from the complete set of all names available to the client. The return value is an array of Net::IMAP::MailboxList. |
|
login(user, password)
|
Sends a LOGIN command to identify the client and carries the plaintext password authenticating this user. |
|
logout
|
Sends a LOGOUT command to inform the server that the client is done with the connection. |
|
lsub(refname, mailbox)
|
Sends a LSUB command, and returns a subset of names from the set of names that the user has declared as being "active" or "subscribed". The return value is an array of Net::IMAP::MailboxList. |
|
noop
|
Sends a NOOP command to the server. It does nothing. |
|
remove_response_handler(handler)
|
Removes the response handler. |
|
rename(mailbox, newname)
|
Sends a RENAME command to change the name of the mailbox to the newname. |
|
response_handlers
|
Returns all response handlers. |
|
responses
|
Returns recorded untagged responses. |
|
search(keys, charset = nil)
|
Sends a SEARCH command to search the mailbox for messages that match the given searching criteria, and returns message sequence numbers (search) or unique identifiers (uid_search). |
|
select(mailbox)
|
Sends a SELECT command to select a mailbox so that messages in the mailbox can be accessed. |
|
setacl(mailbox, user, rights)
|
Sends the SETACL command along with mailbox, user and the rights that user is to have on that mailbox. If rights is nil, then that user will be stripped of any rights to that mailbox. The IMAP ACL commands are described in [RFC2086]. |
|
setquota(mailbox, quota)
|
Sends a SETQUOTA command along with the specified mailbox and quota. If quota is nil, then quota will be unset for that mailbox. Typically one needs to be logged in as server admin for this to work. The IMAP quota commands are described in [RFC2087]. |
|
sort(sort_keys, search_keys, charset)
|
Sends a SORT command to sort messages in the mailbox. |
|
status(mailbox, attr)
|
Sends a STATUS command, and returns the status of the indicated mailbox. return value is a hash of attributes. |
|
store(set, attr, flags)
|
Sends a STORE command to alter data associated with a message in the mailbox. the set parameter is a number or an array of numbers or a Range object. the number is a message sequence number (store) or a unique identifier (uid_store). The return value is an array of Net::IMAP::FetchData. |
|
subscribe(mailbox)
|
Sends a SUBSCRIBE command to add the specified mailbox name to the server's set of "active" or "subscribed" mailboxes. |
|
thread(algorithm, search_keys, charset)
|
As for #search(), but returns message sequence numbers in threaded format, as a Net::IMAP::ThreadMember tree. The supported algorithms are: |
|
uid_thread(algorithm, search_keys, charset)
|
As for #thread(), but returns unique identifiers instead of message sequence numbers. |
|
unsubscribe(mailbox)
|
Sends a UNSUBSCRIBE command to remove the specified mailbox name from the server's set of "active" or "subscribed" mailboxes. |
==
===
=~
__id__
__send__
_dump
class
clone
dclone
display
enum_for
eql?
equal?
extend
freeze
frozen?
hash
initialize
initialize_copy
inspect
instance_eval
instance_exec
instance_of?
instance_variable_defined?
instance_variable_get
instance_variable_set
instance_variables
is_a?
marshal_dump
marshal_load
method
method_missing
methods
nil?
pretty_inspect
pretty_print
pretty_print_cycle
pretty_print_inspect
pretty_print_instance_variables
private_methods
protected_methods
public_methods
remove_instance_variable
respond_to?
singleton_method_added
singleton_method_removed
singleton_method_undefined
singleton_methods
taint
tainted?
tap
to_a
to_ary
to_hash
to_int
to_io
to_proc
to_regexp
to_s
to_str
to_yaml
to_yaml_properties
to_yaml_style
untaint