target.apidocs.com.google.api.services.gmail.Gmail.Users.Labels.html Maven / Gradle / Ivy
Gmail.Users.Labels (Gmail API v1-rev20240422-2.0.0)
com.google.api.services.gmail
Class Gmail.Users.Labels
- java.lang.Object
-
- com.google.api.services.gmail.Gmail.Users.Labels
-
- Enclosing class:
- Gmail.Users
public class Gmail.Users.Labels
extends Object
The "labels" collection of methods.
-
-
Nested Class Summary
Nested Classes
Modifier and Type
Class and Description
class
Gmail.Users.Labels.Create
class
Gmail.Users.Labels.Delete
class
Gmail.Users.Labels.Get
class
Gmail.Users.Labels.List
class
Gmail.Users.Labels.Patch
class
Gmail.Users.Labels.Update
-
Constructor Summary
Constructors
Constructor and Description
Labels()
-
Method Summary
All Methods Instance Methods Concrete Methods
Modifier and Type
Method and Description
Gmail.Users.Labels.Create
create(String userId,
Label content)
Creates a new label.
Gmail.Users.Labels.Delete
delete(String userId,
String id)
Immediately and permanently deletes the specified label and removes it from any messages and
threads that it is applied to.
Gmail.Users.Labels.Get
get(String userId,
String id)
Gets the specified label.
Gmail.Users.Labels.List
list(String userId)
Lists all labels in the user's mailbox.
Gmail.Users.Labels.Patch
patch(String userId,
String id,
Label content)
Patch the specified label.
Gmail.Users.Labels.Update
update(String userId,
String id,
Label content)
Updates the specified label.
-
-
Method Detail
-
create
public Gmail.Users.Labels.Create create(String userId,
Label content)
throws IOException
Creates a new label.
Create a request for the method "labels.create".
This request holds the parameters needed by the gmail server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
userId
- The user's email address. The special value `me` can be used to indicate the authenticated user.
[default: me]
content
- the Label
- Returns:
- the request
- Throws:
IOException
-
delete
public Gmail.Users.Labels.Delete delete(String userId,
String id)
throws IOException
Immediately and permanently deletes the specified label and removes it from any messages and
threads that it is applied to.
Create a request for the method "labels.delete".
This request holds the parameters needed by the gmail server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
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 label to delete.
- Returns:
- the request
- Throws:
IOException
-
get
public Gmail.Users.Labels.Get get(String userId,
String id)
throws IOException
Gets the specified label.
Create a request for the method "labels.get".
This request holds the parameters needed by the gmail server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
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 label to retrieve.
- Returns:
- the request
- Throws:
IOException
-
list
public Gmail.Users.Labels.List list(String userId)
throws IOException
Lists all labels in the user's mailbox.
Create a request for the method "labels.list".
This request holds the parameters needed by the gmail server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
userId
- The user's email address. The special value `me` can be used to indicate the authenticated user.
[default: me]
- Returns:
- the request
- Throws:
IOException
-
patch
public Gmail.Users.Labels.Patch patch(String userId,
String id,
Label content)
throws IOException
Patch the specified label.
Create a request for the method "labels.patch".
This request holds the parameters needed by the gmail server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
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 label to update.
content
- the Label
- Returns:
- the request
- Throws:
IOException
-
update
public Gmail.Users.Labels.Update update(String userId,
String id,
Label content)
throws IOException
Updates the specified label.
Create a request for the method "labels.update".
This request holds the parameters needed by the gmail server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
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 label to update.
content
- the Label
- Returns:
- the request
- Throws:
IOException
Copyright © 2011–2024 Google. All rights reserved.
© 2015 - 2024 Weber Informatics LLC | Privacy Policy