| java.lang.Object |
| ↳ |
org.mule.modules.google.AbstractGoogleOAuthConnector |
| |
↳ |
org.mule.module.google.task.GoogleTasksConnector |
Known Direct Subclasses
|
Known Indirect Subclasses
|
Class Overview
Google Tasks Cloud connector.
This connector covers almost all the Google Tasks API v3 using OAuth2 for authentication.
Summary
|
[Expand]
Inherited Constants |
From class
org.mule.modules.google.AbstractGoogleOAuthConnector
| String |
USER_PROFILE_SCOPE |
|
|
| Fields |
|
private
String |
accessToken |
|
|
private
String |
applicationName |
Application name registered on Google API console
|
|
private
Tasks |
client |
The google api client
|
|
private
String |
consumerKey |
The OAuth2 consumer key
|
|
private
String |
consumerSecret |
The OAuth2 consumer secret
|
|
private
String |
scope |
The OAuth scopes you want to request
|
|
[Expand]
Inherited Fields |
From class
org.mule.modules.google.AbstractGoogleOAuthConnector
|
| Public Methods |
|
void
|
clearTasks(String taskListId)
Clears all completed tasks from the specified task list.
|
|
void
|
deleteTask(String taskListId, String taskId)
Deletes the specified task from the task list.
|
|
void
|
deleteTaskList(String taskListId)
Deletes the authenticated user's specified task list.
|
|
String
|
getAccessToken()
|
|
String
|
getApplicationName()
|
|
String
|
getConsumerKey()
|
|
String
|
getConsumerSecret()
|
|
String
|
getScope()
|
|
Task
|
getTaskById(String taskListId, String taskId)
Returns the specified task.
|
|
TaskList
|
getTaskListById(String taskListId)
Returns the authenticated user's specified task list
|
|
PagingDelegate<TaskList>
|
getTaskLists(PagingConfiguration pagingConfiguration)
Returns all the authenticated user's task lists.
|
|
PagingDelegate<Task>
|
getTasks(String taskListId, String completedMin, String completedMax, String dueMin, String dueMax, String updatedMin, boolean showDeleted, boolean showHidden, boolean showcompleted, PagingConfiguration pagingConfiguration)
Returns all tasks in the specified task list.
|
|
Task
|
insertTask(String taskListId, Task task)
Creates a new task on the specified task list
|
|
TaskList
|
insertTaskList(TaskList taskList)
Creates a new task list and adds it to the authenticated user's task lists.
|
|
Task
|
move(String taskListId, String taskId, String parentId, String previousId)
Moves the specified task to another position in the task list.
|
|
void
|
postAuth()
|
|
void
|
setAccessToken(String accessToken)
|
|
void
|
setApplicationName(String applicationName)
|
|
void
|
setConsumerKey(String consumerKey)
|
|
void
|
setConsumerSecret(String consumerSecret)
|
|
void
|
setScope(String scope)
|
|
Task
|
updateTask(String taskListId, String taskId, Task task)
Updates the specified task.
|
|
TaskList
|
updateTaskList(TaskList taskList, String taskListId)
Updates the authenticated user's specified task list.
|
|
[Expand]
Inherited Methods |
From class
org.mule.modules.google.AbstractGoogleOAuthConnector
|
abstract
String
|
getAccessToken()
|
|
String
|
getUserId()
|
|
void
|
setUserId(String arg0)
|
|
From class
java.lang.Object
|
Object
|
clone()
|
|
boolean
|
equals(Object arg0)
|
|
void
|
finalize()
|
|
final
Class<?>
|
getClass()
|
|
int
|
hashCode()
|
|
final
void
|
notify()
|
|
final
void
|
notifyAll()
|
|
String
|
toString()
|
|
final
void
|
wait()
|
|
final
void
|
wait(long arg0, int arg1)
|
|
final
void
|
wait(long arg0)
|
|
Constants
public
static
final
String
NEXT_PAGE_TOKEN
Constant Value:
"GoogleTask_NEXT_PAGE_TOKEN"
Fields
private
String
accessToken
private
String
applicationName
Application name registered on Google API console
private
String
consumerKey
private
String
consumerSecret
The OAuth2 consumer secret
private
String
scope
The OAuth scopes you want to request
Public Constructors
public
GoogleTasksConnector
()
Public Methods
public
void
clearTasks
(String taskListId)
Clears all completed tasks from the specified task list. The affected tasks will be marked as
'hidden' and no longer be returned by default when retrieving all tasks for a task list.
Parameters
| taskListId
| Task list identifier |
Throws
| IOException
| if there's an error in the communication
|
public
void
deleteTask
(String taskListId, String taskId)
Deletes the specified task from the task list.
Parameters
| taskListId
| Task list identifier |
| taskId
| Task identifier. |
Throws
| IOException
| if there's an error in the communication
|
public
void
deleteTaskList
(String taskListId)
Deletes the authenticated user's specified task list.
Parameters
| taskListId
| Task list identifier. |
Throws
| IOException
| if there's an error in the communication
|
public
String
getAccessToken
()
public
String
getApplicationName
()
public
String
getConsumerKey
()
public
String
getConsumerSecret
()
public
String
getScope
()
public
Task
getTaskById
(String taskListId, String taskId)
Returns the specified task.
Parameters
| taskListId
| Task list identifier |
| taskId
| Task identifier |
Throws
| IOException
| if there's an error in the communication
|
public
TaskList
getTaskListById
(String taskListId)
Returns the authenticated user's specified task list
Parameters
| taskListId
| Task list identifier. |
Throws
| IOException
| if there's an error in the communication
|
public
PagingDelegate<TaskList>
getTaskLists
(PagingConfiguration pagingConfiguration)
Returns all the authenticated user's task lists.
Parameters
| pagingConfiguration
| The pagingConfiguration object |
Returns
- an auto paginated iterator with instances of
TaskList
Throws
| IOException
| if there's an error in the communication
|
public
PagingDelegate<Task>
getTasks
(String taskListId, String completedMin, String completedMax, String dueMin, String dueMax, String updatedMin, boolean showDeleted, boolean showHidden, boolean showcompleted, PagingConfiguration pagingConfiguration)
Returns all tasks in the specified task list. This method accepts a number
of filtering attributes. The one for which no values is specified will not be used
when filtering
Parameters
| taskListId
| Task list identifier |
| completedMin
| Lower bound for a task's completion date (as a RFC 3339 timestamp) to filter by |
| completedMax
| Upper bound for a task's completion date (as a RFC 3339 timestamp) to filter by |
| dueMin
| Lower bound for a task's due date (as a RFC 3339 timestamp) to filter by |
| dueMax
| Upper bound for a task's due date (as a RFC 3339 timestamp) to filter by |
| updatedMin
| Lower bound for a task's last modification time (as a RFC 3339 timestamp) to filter by |
| showDeleted
| Flag indicating whether deleted tasks are returned in the result |
| showHidden
| Flag indicating whether hidden tasks are returned in the result |
| showcompleted
| Flag indicating whether completed tasks are returned in the result |
| pagingConfiguration
| The paging configuration object |
Returns
- list with instances of
Task
Throws
| IOException
| if there's an error in the communication
|
public
Task
insertTask
(String taskListId, Task task)
Creates a new task on the specified task list
Parameters
| taskListId
| Task list identifier |
| task
| Instance of Task containing the state of the task to be inserted |
Returns
- instance of
Task representing the state of the newly inserted task
Throws
| IOException
| if there's an error in the communication
|
public
TaskList
insertTaskList
(TaskList taskList)
Creates a new task list and adds it to the authenticated user's task lists.
Parameters
| taskList
| The taskList to be inserted |
Returns
- an instance of
TaskList representing the newly inserted task list
Throws
| IOException
| if there's an error in the communication
|
public
Task
move
(String taskListId, String taskId, String parentId, String previousId)
Moves the specified task to another position in the task list. This can include putting it as a
child task under a new parent and/or move it to a different position among its sibling tasks.
Parameters
| taskListId
| Task list identifier |
| taskId
| Identifier for the task being moved. |
| parentId
| Parent task identifier. If the task is created at the top level, this parameter is omitted |
| previousId
| New previous sibling task identifier. If the task is moved to the first position among its
siblings, this parameter is omitted |
Returns
- an instance of
Task representing the state of the moved task
Throws
| IOException
| if there's an error in the communication
|
public
void
setAccessToken
(String accessToken)
public
void
setApplicationName
(String applicationName)
public
void
setConsumerKey
(String consumerKey)
public
void
setConsumerSecret
(String consumerSecret)
public
void
setScope
(String scope)
public
Task
updateTask
(String taskListId, String taskId, Task task)
Updates the specified task.
Parameters
| taskListId
| Task list identifier |
| taskId
| Task identifier. |
| task
| Instance of Task containing the state we want the updated task to have |
Returns
- an instance of
Task representing the state of the updated task
Throws
| IOException
| if there's an error in the communication
|
public
TaskList
updateTaskList
(TaskList taskList, String taskListId)
Updates the authenticated user's specified task list.
Parameters
| taskList
| An instance of TaskList with the task list's new state |
| taskListId
| Task list identifier |
Returns
- an instance of
TaskList representing the state of the updated list
Throws
| IOException
| if there's an error in the communication
|