Rails API Doc for Mail::Message?

Hi,

I am very new to Rails. I am trying to delete an email that I have retrieved from a pop3 account. I googled around but couldn’t find any thing on that topic. I couldn’t find any API Doc either. What do I need to do to delete an email?

That really depends on the library (gem) you used, the method you
store it as and most importantly where you stored it at. Since it's
not a system account (I'm assuming) it's not going to store it in
system mail unless the gem is absolutely ignorant so you would have
had to of told it where and how to store it (the how is subjective
though because you could have stored it as another type of flat file,
mbox or maildir or even just kept it in memory long enough to parse it
into a db.)

Figure out where you stored it and go from there.

Isn’t the mail gem part of rails 3.2.8?

In my code, I put require ‘mail’

Mail.defaults do
retriever_method :pop3,
address: “pop.xxx.com”,
port: 995,
user_name: ‘xxx’,
password: ‘xxx’,
enable_ssl: true
end

My email is:

email = Mail.first

I then can access some methods:

logger.info "Subject: " + email.subject unless email.subject.nil?
logger.info "From: " + email.from[0] unless
logger.info "To: " + email.to[0]
logger.info "Body: " + email.body.decoded

I would like to know where can get some documentation on all the available methods I can use.

The mail is in my pop3 account. How do I delete it off my pop3 account?

I also have questions on how to get attachments from my email… but maybe things will be clear when I find out how to find the proper documentation.