public class Gmail.Users.Drafts extends Object
| Modifier and Type | Class and Description |
|---|---|
class |
Gmail.Users.Drafts.Create |
class |
Gmail.Users.Drafts.Delete |
class |
Gmail.Users.Drafts.Get |
class |
Gmail.Users.Drafts.List |
class |
Gmail.Users.Drafts.Send |
class |
Gmail.Users.Drafts.Update |
| Constructor and Description |
|---|
Drafts() |
| Modifier and Type | Method and Description |
|---|---|
Gmail.Users.Drafts.Create |
create(String userId,
Draft content)
Creates a new draft with the `DRAFT` label.
|
Gmail.Users.Drafts.Create |
create(String userId,
Draft content,
com.google.api.client.http.AbstractInputStreamContent mediaContent)
Creates a new draft with the `DRAFT` label.
|
Gmail.Users.Drafts.Delete |
delete(String userId,
String id)
Immediately and permanently deletes the specified draft.
|
Gmail.Users.Drafts.Get |
get(String userId,
String id)
Gets the specified draft.
|
Gmail.Users.Drafts.List |
list(String userId)
Lists the drafts in the user's mailbox.
|
Gmail.Users.Drafts.Send |
send(String userId,
Draft content)
Sends the specified, existing draft to the recipients in the `To`, `Cc`, and `Bcc` headers.
|
Gmail.Users.Drafts.Send |
send(String userId,
Draft content,
com.google.api.client.http.AbstractInputStreamContent mediaContent)
Sends the specified, existing draft to the recipients in the `To`, `Cc`, and `Bcc` headers.
|
Gmail.Users.Drafts.Update |
update(String userId,
String id,
Draft content)
Replaces a draft's content.
|
Gmail.Users.Drafts.Update |
update(String userId,
String id,
Draft content,
com.google.api.client.http.AbstractInputStreamContent mediaContent)
Replaces a draft's content.
|
public Gmail.Users.Drafts.Create create(String userId, Draft content) throws 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 DraftIOExceptionpublic Gmail.Users.Drafts.Create create(String userId, Draft content, com.google.api.client.http.AbstractInputStreamContent mediaContent) throws 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 Draft media metadata or null if nonemediaContent - The media HTTP content.IOException - if the initialization of the request failspublic Gmail.Users.Drafts.Delete delete(String userId, String id) throws 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 draft to delete.IOExceptionpublic Gmail.Users.Drafts.Get get(String userId, String id) throws 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 draft to retrieve.IOExceptionpublic Gmail.Users.Drafts.List list(String userId) throws 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]IOExceptionpublic Gmail.Users.Drafts.Send send(String userId, Draft content) throws 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 DraftIOExceptionpublic Gmail.Users.Drafts.Send send(String userId, Draft content, com.google.api.client.http.AbstractInputStreamContent mediaContent) throws 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 Draft media metadata or null if nonemediaContent - The media HTTP content.IOException - if the initialization of the request failspublic Gmail.Users.Drafts.Update update(String userId, String id, Draft content) throws 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 draft to update.content - the DraftIOExceptionpublic Gmail.Users.Drafts.Update update(String userId, String id, Draft content, com.google.api.client.http.AbstractInputStreamContent mediaContent) throws 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]@param id The ID of the draft to update.content - the Draft media metadata or null if nonemediaContent - The media HTTP content.IOException - if the initialization of the request failsCopyright © 2011–2025 Google. All rights reserved.