C# Class Synology.AudioStationApi.AudioStationSession

Inheritance: IAudioStationSession
Mostra file Open project: salfab/open-syno Class Usage Examples

Private Properties

Property Type Description
BuildRequest System.Net.HttpWebRequest
OnFileDownloadResponseReceived void

Public Methods

Method Description
AudioStationSession ( ) : System
AudioStationSession ( IVersionDependentResourcesProvider versionDependentResourcesProvider, DsmVersions dsmVersion ) : System
GetAlbumsForArtist ( SynoItem artist, Action callback, Action callbackError ) : void
GetAlbumsForArtistAsync ( SynoItem artist ) : Task>
GetFileStream ( SynoTrack synoTrack, SynoTrack>.Action callback ) : void

Gets the remote file network stream.

The caller is responsible for closing the stream after the call to DownloadFile returns

GetTracksForAlbum ( SynoItem album, Action callback, Action callbackError ) : void
GetTracksForAlbumAsync ( SynoItem album ) : Task>
LoginAsync ( string login, string password, Action callback, Action callbackError, bool useSsl ) : void
SearchAlbums ( string album ) : Task>
SearchAllMusic ( string pattern, Action callback, Action callbackError ) : void
SearchArtist ( string pattern, Action callback, Action callbackError ) : void
SearchArtistAsync ( string artistName ) : Task>

Private Methods

Method Description
BuildRequest ( string url ) : HttpWebRequest
OnFileDownloadResponseReceived ( IAsyncResult ar ) : void

Method Details

AudioStationSession() public method

public AudioStationSession ( ) : System
return System

AudioStationSession() public method

public AudioStationSession ( IVersionDependentResourcesProvider versionDependentResourcesProvider, DsmVersions dsmVersion ) : System
versionDependentResourcesProvider IVersionDependentResourcesProvider
dsmVersion DsmVersions
return System

GetAlbumsForArtist() public method

public GetAlbumsForArtist ( SynoItem artist, Action callback, Action callbackError ) : void
artist SynoItem
callback Action
callbackError Action
return void

GetAlbumsForArtistAsync() public method

public GetAlbumsForArtistAsync ( SynoItem artist ) : Task>
artist SynoItem
return Task>

GetFileStream() public method

Gets the remote file network stream.
The caller is responsible for closing the stream after the call to DownloadFile returns
public GetFileStream ( SynoTrack synoTrack, SynoTrack>.Action callback ) : void
synoTrack SynoTrack The track wor which to retrieve the stream.
callback SynoTrack>.Action The method to call after the stream is open. The HttpResponse is passed as argument
return void

GetTracksForAlbum() public method

public GetTracksForAlbum ( SynoItem album, Action callback, Action callbackError ) : void
album SynoItem
callback Action
callbackError Action
return void

GetTracksForAlbumAsync() public method

public GetTracksForAlbumAsync ( SynoItem album ) : Task>
album SynoItem
return Task>

LoginAsync() public method

public LoginAsync ( string login, string password, Action callback, Action callbackError, bool useSsl ) : void
login string
password string
callback Action
callbackError Action
useSsl bool
return void

SearchAlbums() public method

public SearchAlbums ( string album ) : Task>
album string
return Task>

SearchAllMusic() public method

public SearchAllMusic ( string pattern, Action callback, Action callbackError ) : void
pattern string
callback Action
callbackError Action
return void

SearchArtist() public method

public SearchArtist ( string pattern, Action callback, Action callbackError ) : void
pattern string
callback Action
callbackError Action
return void

SearchArtistAsync() public method

public SearchArtistAsync ( string artistName ) : Task>
artistName string
return Task>