C# Class PocketCampus.Moodle.Services.FileStorage

Stores Moodle files in the Windows Phone application data.
Inheritance: IFileStorage
Mostrar archivo Open project: accandme/pocketcampus

Public Methods

Method Description
IsStoredAsync ( MoodleFile moodleFile ) : Task

Asynchronously indicates whether the specified Moodle file is stored on the device.

OpenFileAsync ( MoodleFile moodleFile ) : System.Threading.Tasks.Task

Asynchronously opens the specified Moodle file.

StoreFileAsync ( MoodleFile moodleFile, byte content ) : System.Threading.Tasks.Task

Asynchronously stores the specified Moodle file with the specified content.

Private Methods

Method Description
FixName ( string name, char invalidChars ) : string

Fixes a name by removing invalid characters.

GetFileAsync ( MoodleFile file, bool create ) : Task

Gets a file. Optionally creates it if it doesn't exist.

Method Details

IsStoredAsync() public method

Asynchronously indicates whether the specified Moodle file is stored on the device.
public IsStoredAsync ( MoodleFile moodleFile ) : Task
moodleFile PocketCampus.Moodle.Models.MoodleFile
return Task

OpenFileAsync() public method

Asynchronously opens the specified Moodle file.
public OpenFileAsync ( MoodleFile moodleFile ) : System.Threading.Tasks.Task
moodleFile PocketCampus.Moodle.Models.MoodleFile
return System.Threading.Tasks.Task

StoreFileAsync() public method

Asynchronously stores the specified Moodle file with the specified content.
public StoreFileAsync ( MoodleFile moodleFile, byte content ) : System.Threading.Tasks.Task
moodleFile PocketCampus.Moodle.Models.MoodleFile
content byte
return System.Threading.Tasks.Task