C# Class TodotxtTouch.WindowsPhone.Service.TaskFileService

Mostra file Open project: hartez/TodotxtTouch.WindowsPhone Class Usage Examples

Protected Properties

Property Type Description
Settings ApplicationSettings

Private Properties

Property Type Description
CacheForMerge void
CacheForMerge void
ClearTaskPropertyChangedHandlers void
GetRemoteMetaData void
InitTaskPropertyChangedHandlers void
IntiateMerge void
LoadTasks void
MergeTaskLists void
OverwriteWithRemoteFile void
PauseCollectionChanged void
PushLocal void
ReadLocalFile byte[]
ResumeCollectionChanged void
SaveToStorage void
SendSyncError void
Start void
Sync void
TaskListCollectionChanged void
TaskPropertyChanged void
UseRemoteFile void

Public Methods

Method Description
InvokeLoadingStateChanged ( LoadingStateChangedEventArgs e ) : void
InvokeLocalHasChangesChanged ( LocalHasChangesChangedEventArgs e ) : void
InvokeSynchronizationError ( SynchronizationErrorEventArgs e ) : void
InvokeTaskListChanged ( TaskListChangedEventArgs e ) : void
ReadFully ( Stream stream, int initialLength ) : byte[]

Reads data from a stream until the end is reached. The data is returned as a byte array. An IOException is thrown if any of the underlying IO calls fail.

SaveTasks ( ) : void
Sync ( ) : void
UpdateTask ( todotxtlib.net.Task task, todotxtlib.net.Task oldTask ) : void

Protected Methods

Method Description
GetFileName ( ) : string
GetFilePath ( ) : string
TaskFileService ( DropboxService dropBoxService, ApplicationSettings settings ) : System

Private Methods

Method Description
CacheForMerge ( ) : void
CacheForMerge ( IsolatedStorageFile appStorage ) : void
ClearTaskPropertyChangedHandlers ( ) : void
GetRemoteMetaData ( Action success, Action failure ) : void
InitTaskPropertyChangedHandlers ( ) : void
IntiateMerge ( ) : void
LoadTasks ( ) : void
MergeTaskLists ( string remoteTaskContents ) : void
OverwriteWithRemoteFile ( IRestResponse response, string latestRevision ) : void
PauseCollectionChanged ( ) : void
PushLocal ( ) : void
ReadLocalFile ( string fileName ) : byte[]
ResumeCollectionChanged ( ) : void
SaveToStorage ( ) : void
SendSyncError ( Exception ex ) : void
Start ( ) : void
Sync ( DropNet.Models.MetaData data ) : void
TaskListCollectionChanged ( object sender, NotifyCollectionChangedEventArgs e ) : void
TaskPropertyChanged ( object sender, PropertyChangedEventArgs e ) : void
UseRemoteFile ( string latestRevision ) : void

Method Details

GetFileName() protected abstract method

protected abstract GetFileName ( ) : string
return string

GetFilePath() protected abstract method

protected abstract GetFilePath ( ) : string
return string

InvokeLoadingStateChanged() public method

public InvokeLoadingStateChanged ( LoadingStateChangedEventArgs e ) : void
e TodotxtTouch.WindowsPhone.ViewModel.LoadingStateChangedEventArgs
return void

InvokeLocalHasChangesChanged() public method

public InvokeLocalHasChangesChanged ( LocalHasChangesChangedEventArgs e ) : void
e LocalHasChangesChangedEventArgs
return void

InvokeSynchronizationError() public method

public InvokeSynchronizationError ( SynchronizationErrorEventArgs e ) : void
e SynchronizationErrorEventArgs
return void

InvokeTaskListChanged() public method

public InvokeTaskListChanged ( TaskListChangedEventArgs e ) : void
e TaskListChangedEventArgs
return void

ReadFully() public static method

Reads data from a stream until the end is reached. The data is returned as a byte array. An IOException is thrown if any of the underlying IO calls fail.
public static ReadFully ( Stream stream, int initialLength ) : byte[]
stream Stream The stream to read data from
initialLength int The initial buffer length
return byte[]

SaveTasks() public method

public SaveTasks ( ) : void
return void

Sync() public method

public Sync ( ) : void
return void

TaskFileService() protected method

protected TaskFileService ( DropboxService dropBoxService, ApplicationSettings settings ) : System
dropBoxService DropboxService
settings ApplicationSettings
return System

UpdateTask() public method

public UpdateTask ( todotxtlib.net.Task task, todotxtlib.net.Task oldTask ) : void
task todotxtlib.net.Task
oldTask todotxtlib.net.Task
return void

Property Details

Settings protected_oe property

protected ApplicationSettings Settings
return ApplicationSettings