|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.mylar.internal.tasks.ui.TaskDataManager
public class TaskDataManager
Manager for persisting RepositoryTaskData
Field Summary | |
---|---|
private OfflineDataStore |
dataStore
|
private java.io.File |
file
|
private java.util.Map<java.lang.String,RepositoryTaskData> |
newTaskDataMap
Newest version of the task data |
private java.util.Map<java.lang.String,RepositoryTaskData> |
oldTaskDataMap
Older version of Task Data |
private java.util.Map<java.lang.String,RepositoryTaskData> |
unsubmittedTaskData
Unsubmitted tasks data |
Constructor Summary | |
---|---|
TaskDataManager(java.io.File file,
boolean read)
|
Method Summary | |
---|---|
void |
clear()
Public for testing |
void |
clearUnsubmitted()
|
private java.util.Map<java.lang.String,RepositoryTaskData> |
getNewDataMap()
|
java.lang.String |
getNewRepositoryTaskId()
|
private java.util.Map<java.lang.String,RepositoryTaskData> |
getOldDataMap()
|
RepositoryTaskData |
getOldTaskData(java.lang.String handle)
Returns the old copy if exists, null otherwise. |
RepositoryTaskData |
getOldTaskData(java.lang.String repositoryUrl,
java.lang.String taskId)
Returns the old copy if exists, null otherwise. |
RepositoryTaskData |
getTaskData(java.lang.String handle)
Returns the most recent copy of the task data. |
RepositoryTaskData |
getTaskData(java.lang.String repositoryUrl,
java.lang.String taskId)
Returns the most recent copy of the task data. |
java.util.Map<java.lang.String,RepositoryTaskData> |
getUnsubmitted()
|
private java.util.Map<java.lang.String,RepositoryTaskData> |
getUnsubmittedTaskData()
|
void |
put(RepositoryTaskData newEntry)
Add a RepositoryTaskData to the offline reports file. |
void |
putUnsubmitted(RepositoryTaskData newEntry)
Add an unsubmitted RepositoryTaskData to the offline reports file. |
void |
readOfflineData()
Public for testing |
private void |
readOldOfflineFile()
Migrate from old offline task data format (pre 1.0) |
void |
remove(java.util.List<RepositoryTaskData> dataToRemove)
Remove some bugs from the offline reports list |
void |
remove(RepositoryTaskData taskData)
|
void |
removeUnsubmitted(java.lang.String handle)
|
void |
save()
save task data to offline file |
private void |
updateAttributeFactory(RepositoryTaskData taskData)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private java.io.File file
private OfflineDataStore dataStore
private java.util.Map<java.lang.String,RepositoryTaskData> oldTaskDataMap
private java.util.Map<java.lang.String,RepositoryTaskData> newTaskDataMap
private java.util.Map<java.lang.String,RepositoryTaskData> unsubmittedTaskData
Constructor Detail |
---|
public TaskDataManager(java.io.File file, boolean read) throws java.io.IOException, java.lang.ClassNotFoundException
java.io.IOException
java.lang.ClassNotFoundException
Method Detail |
---|
private java.util.Map<java.lang.String,RepositoryTaskData> getOldDataMap()
private java.util.Map<java.lang.String,RepositoryTaskData> getNewDataMap()
private java.util.Map<java.lang.String,RepositoryTaskData> getUnsubmittedTaskData()
public void put(RepositoryTaskData newEntry)
public void putUnsubmitted(RepositoryTaskData newEntry)
public java.util.Map<java.lang.String,RepositoryTaskData> getUnsubmitted()
public void removeUnsubmitted(java.lang.String handle)
public void clearUnsubmitted()
public java.lang.String getNewRepositoryTaskId()
public RepositoryTaskData getTaskData(java.lang.String handle)
public RepositoryTaskData getTaskData(java.lang.String repositoryUrl, java.lang.String taskId)
public RepositoryTaskData getOldTaskData(java.lang.String handle)
public RepositoryTaskData getOldTaskData(java.lang.String repositoryUrl, java.lang.String taskId)
public void remove(java.util.List<RepositoryTaskData> dataToRemove)
indicesToRemove
- An array of the indicies of the bugs to be removedpublic void remove(RepositoryTaskData taskData)
public void clear()
public void readOfflineData() throws java.io.IOException, java.lang.ClassNotFoundException
java.io.IOException
java.lang.ClassNotFoundException
private void readOldOfflineFile() throws java.io.IOException
java.io.IOException
public void save()
private void updateAttributeFactory(RepositoryTaskData taskData)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |