public class Gmail.Users.Messages
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
class |
Gmail.Users.Messages.Attachments
The "attachments" collection of methods.
|
class |
Gmail.Users.Messages.BatchDelete |
class |
Gmail.Users.Messages.BatchModify |
class |
Gmail.Users.Messages.Delete |
class |
Gmail.Users.Messages.Get |
class |
Gmail.Users.Messages.GmailImport |
class |
Gmail.Users.Messages.Insert |
class |
Gmail.Users.Messages.List |
class |
Gmail.Users.Messages.Modify |
class |
Gmail.Users.Messages.Send |
class |
Gmail.Users.Messages.Trash |
class |
Gmail.Users.Messages.Untrash |
Constructor and Description |
---|
Messages() |
Modifier and Type | Method and Description |
---|---|
Gmail.Users.Messages.Attachments |
attachments()
An accessor for creating requests from the Attachments collection.
|
Gmail.Users.Messages.BatchDelete |
batchDelete(java.lang.String userId,
BatchDeleteMessagesRequest content)
Deletes many messages by message ID.
|
Gmail.Users.Messages.BatchModify |
batchModify(java.lang.String userId,
BatchModifyMessagesRequest content)
Modifies the labels on the specified messages.
|
Gmail.Users.Messages.Delete |
delete(java.lang.String userId,
java.lang.String id)
Immediately and permanently deletes the specified message.
|
Gmail.Users.Messages.Get |
get(java.lang.String userId,
java.lang.String id)
Gets the specified message.
|
Gmail.Users.Messages.GmailImport |
gmailImport(java.lang.String userId,
Message content)
Imports a message into only this user's mailbox, with standard email delivery scanning and
classification similar to receiving via SMTP.
|
Gmail.Users.Messages.GmailImport |
gmailImport(java.lang.String userId,
Message content,
com.google.api.client.http.AbstractInputStreamContent mediaContent)
Imports a message into only this user's mailbox, with standard email delivery scanning and
classification similar to receiving via SMTP.
|
Gmail.Users.Messages.Insert |
insert(java.lang.String userId,
Message content)
Directly inserts a message into only this user's mailbox similar to IMAP APPEND, bypassing most
scanning and classification.
|
Gmail.Users.Messages.Insert |
insert(java.lang.String userId,
Message content,
com.google.api.client.http.AbstractInputStreamContent mediaContent)
Directly inserts a message into only this user's mailbox similar to IMAP APPEND, bypassing most
scanning and classification.
|
Gmail.Users.Messages.List |
list(java.lang.String userId)
Lists the messages in the user's mailbox.
|
Gmail.Users.Messages.Modify |
modify(java.lang.String userId,
java.lang.String id,
ModifyMessageRequest content)
Modifies the labels on the specified message.
|
Gmail.Users.Messages.Send |
send(java.lang.String userId,
Message content)
Sends the specified message to the recipients in the To, Cc, and Bcc headers.
|
Gmail.Users.Messages.Send |
send(java.lang.String userId,
Message content,
com.google.api.client.http.AbstractInputStreamContent mediaContent)
Sends the specified message to the recipients in the To, Cc, and Bcc headers.
|
Gmail.Users.Messages.Trash |
trash(java.lang.String userId,
java.lang.String id)
Moves the specified message to the trash.
|
Gmail.Users.Messages.Untrash |
untrash(java.lang.String userId,
java.lang.String id)
Removes the specified message from the trash.
|
public Gmail.Users.Messages.BatchDelete batchDelete(java.lang.String userId, BatchDeleteMessagesRequest content) throws java.io.IOException
AbstractGoogleClientRequest.execute()
method to invoke the remote operation.userId
- The user's email address. The special value me can be used to indicate the authenticated user.
[default: me]content
- the BatchDeleteMessagesRequest
java.io.IOException
public Gmail.Users.Messages.BatchModify batchModify(java.lang.String userId, BatchModifyMessagesRequest content) throws java.io.IOException
AbstractGoogleClientRequest.execute()
method to invoke the remote operation.userId
- The user's email address. The special value me can be used to indicate the authenticated user.
[default: me]content
- the BatchModifyMessagesRequest
java.io.IOException
public Gmail.Users.Messages.Delete delete(java.lang.String userId, java.lang.String id) throws java.io.IOException
AbstractGoogleClientRequest.execute()
method to invoke the remote operation.userId
- The user's email address. The special value me can be used to indicate the authenticated user.
[default: me]id
- The ID of the message to delete.java.io.IOException
public Gmail.Users.Messages.Get get(java.lang.String userId, java.lang.String id) throws java.io.IOException
AbstractGoogleClientRequest.execute()
method to invoke the remote operation.userId
- The user's email address. The special value me can be used to indicate the authenticated user.
[default: me]id
- The ID of the message to retrieve.java.io.IOException
public Gmail.Users.Messages.GmailImport gmailImport(java.lang.String userId, Message content) throws java.io.IOException
AbstractGoogleClientRequest.execute()
method to invoke the remote operation.userId
- The user's email address. The special value me can be used to indicate the authenticated user.
[default: me]content
- the Message
java.io.IOException
public Gmail.Users.Messages.GmailImport gmailImport(java.lang.String userId, Message content, com.google.api.client.http.AbstractInputStreamContent mediaContent) throws java.io.IOException
AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
This method should be used for uploading media content.
userId
- The user's email address. The special value me can be used to indicate the authenticated user.
[default: me]content
- the Message
media metadata or null
if nonemediaContent
- The media HTTP content or null
if none.java.io.IOException
- if the initialization of the request failspublic Gmail.Users.Messages.Insert insert(java.lang.String userId, Message content) throws java.io.IOException
AbstractGoogleClientRequest.execute()
method to invoke the remote operation.userId
- The user's email address. The special value me can be used to indicate the authenticated user.
[default: me]content
- the Message
java.io.IOException
public Gmail.Users.Messages.Insert insert(java.lang.String userId, Message content, com.google.api.client.http.AbstractInputStreamContent mediaContent) throws java.io.IOException
AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
This method should be used for uploading media content.
userId
- The user's email address. The special value me can be used to indicate the authenticated user.
[default: me]content
- the Message
media metadata or null
if nonemediaContent
- The media HTTP content or null
if none.java.io.IOException
- if the initialization of the request failspublic Gmail.Users.Messages.List list(java.lang.String userId) throws java.io.IOException
AbstractGoogleClientRequest.execute()
method to invoke the remote operation.userId
- The user's email address. The special value me can be used to indicate the authenticated user.
[default: me]java.io.IOException
public Gmail.Users.Messages.Modify modify(java.lang.String userId, java.lang.String id, ModifyMessageRequest content) throws java.io.IOException
AbstractGoogleClientRequest.execute()
method to invoke the remote operation.userId
- The user's email address. The special value me can be used to indicate the authenticated user.
[default: me]id
- The ID of the message to modify.content
- the ModifyMessageRequest
java.io.IOException
public Gmail.Users.Messages.Send send(java.lang.String userId, Message content) throws java.io.IOException
AbstractGoogleClientRequest.execute()
method to invoke the remote operation.userId
- The user's email address. The special value me can be used to indicate the authenticated user.
[default: me]content
- the Message
java.io.IOException
public Gmail.Users.Messages.Send send(java.lang.String userId, Message content, com.google.api.client.http.AbstractInputStreamContent mediaContent) throws java.io.IOException
AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
This method should be used for uploading media content.
userId
- The user's email address. The special value me can be used to indicate the authenticated user.
[default: me]content
- the Message
media metadata or null
if nonemediaContent
- The media HTTP content or null
if none.java.io.IOException
- if the initialization of the request failspublic Gmail.Users.Messages.Trash trash(java.lang.String userId, java.lang.String id) throws java.io.IOException
AbstractGoogleClientRequest.execute()
method to invoke the remote operation.userId
- The user's email address. The special value me can be used to indicate the authenticated user.
[default: me]id
- The ID of the message to Trash.java.io.IOException
public Gmail.Users.Messages.Untrash untrash(java.lang.String userId, java.lang.String id) throws java.io.IOException
AbstractGoogleClientRequest.execute()
method to invoke the remote operation.userId
- The user's email address. The special value me can be used to indicate the authenticated user.
[default: me]id
- The ID of the message to remove from Trash.java.io.IOException
public Gmail.Users.Messages.Attachments attachments()
The typical use is:
Gmail gmail = new Gmail(...);
Gmail.Attachments.List request = gmail.attachments().list(parameters ...)