|
|
|
@ -114,6 +114,88 @@ class InfoTitle {
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
class Manager {
|
|
|
|
|
+ {static} readonly int MAX_NAME_LENGTH = 75
|
|
|
|
|
+ {static} readonly int MAX_DESCRIPTION_LENGTH = 500
|
|
|
|
|
+ {static} readonly string DEFAULT_NAME = "Unknown"
|
|
|
|
|
+ {static} readonly string DEFAULT_URL = "none.png"
|
|
|
|
|
+ {static} readonly string DEFAULT_DESC = ""
|
|
|
|
|
+ IDataManager DataManager
|
|
|
|
|
- ObservableCollection<Album> Albums
|
|
|
|
|
- ObservableCollection<CustomTitle> CustomTitles
|
|
|
|
|
- ObservableCollection<InfoTitle> InfoTitles
|
|
|
|
|
- ObservableCollection<Playlist> Playlists
|
|
|
|
|
- ObservableCollection<Artist> Artists
|
|
|
|
|
+ Album CurrentAlbum
|
|
|
|
|
+ Playlist CurrentPlaylist
|
|
|
|
|
+ InfoTitle CurrentInfoTitle
|
|
|
|
|
+ CustomTitle CurrentPlaying
|
|
|
|
|
+ Manager(IDataManager dataManager)
|
|
|
|
|
+ void NextTitle()
|
|
|
|
|
+ void PreviousTitle()
|
|
|
|
|
+ CustomTitle CurrentTitle()
|
|
|
|
|
+ void Loop()
|
|
|
|
|
+ void Shuffle()
|
|
|
|
|
+ void AddAlbum(Album album)
|
|
|
|
|
+ void AddCustomTitle(CustomTitle title)
|
|
|
|
|
+ void AddInfoTitle(InfoTitle title)
|
|
|
|
|
+ void AddPlaylist(Playlist playlist)
|
|
|
|
|
+ void AddArtist(Artist artist)
|
|
|
|
|
+ void RemoveAlbum(Album album)
|
|
|
|
|
+ void RemoveCustomTitle(CustomTitle title)
|
|
|
|
|
+ void RemoveInfoTitle(InfoTitle title)
|
|
|
|
|
+ void RemovePlaylist(Playlist playlist)
|
|
|
|
|
+ ObservableCollection<Playlist> GetPlaylists()
|
|
|
|
|
+ ObservableCollection<Album> GetAlbums()
|
|
|
|
|
+ ObservableCollection<CustomTitle> GetCustomTitles()
|
|
|
|
|
+ ObservableCollection<InfoTitle> GetInfoTitles()
|
|
|
|
|
+ ObservableCollection<Artist> GetArtists()
|
|
|
|
|
+ void LoadSerialization()
|
|
|
|
|
+ void SaveSerialization()
|
|
|
|
|
+ Playlist GetPlaylistByName(string name)
|
|
|
|
|
+ Artist GetArtistByName(string name)
|
|
|
|
|
+ CustomTitle GetCustomTitleByPath(string path)
|
|
|
|
|
+ InfoTitle GetInfoTitleByName(string name)
|
|
|
|
|
+ Album GetAlbumByName(string name)
|
|
|
|
|
+ Album GetAlbumById(long id)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
Album o-- "+ Artist" Artist
|
|
|
|
|
Album *-- "+ InfoTitles*" InfoTitle
|
|
|
|
|
Album .. Manager
|
|
|
|
|
|
|
|
|
|
Artist .. Manager
|
|
|
|
|
|
|
|
|
|
Playlist o-- "+ Titles*" CustomTitle
|
|
|
|
|
Playlist .. Manager
|
|
|
|
|
|
|
|
|
|
Title .. Manager
|
|
|
|
|
|
|
|
|
|
CustomTitle --|> Title
|
|
|
|
|
|
|
|
|
|
InfoTitle --|> Title
|
|
|
|
|
InfoTitle o-- "+ Genre" Genre
|
|
|
|
|
InfoTitle o-- "+ Artist" Artist
|
|
|
|
|
InfoTitle o-- "+ Feat*" Artist
|
|
|
|
|
|
|
|
|
|
Manager o-- "+ Albums*" Album
|
|
|
|
|
Manager o-- "+ Artists*" Artist
|
|
|
|
|
Manager o-- "+ InfoTitles*" InfoTitle
|
|
|
|
|
Manager o-- "+ Playlists*" Playlist
|
|
|
|
|
Manager o-- "+ CustomTitles*" CustomTitle
|
|
|
|
|
Manager o-- "+ CurrentAlbum" Album
|
|
|
|
|
Manager o-- "+ CurrentPlaylist" Playlist
|
|
|
|
|
Manager o-- "+ CurrentInfoTitle" InfoTitle
|
|
|
|
|
Manager o-- "+ CurrentPlaying" CustomTitle
|
|
|
|
|
|
|
|
|
|
@enduml
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
```plantuml
|
|
|
|
|
@startuml
|
|
|
|
|
|
|
|
|
|
interface IDataManager {
|
|
|
|
|
+ void AddAlbum(Album album)
|
|
|
|
|
+ void AddAlbums(List<Album> albumsList)
|
|
|
|
@ -172,52 +254,6 @@ interface IDataManager {
|
|
|
|
|
+ bool ExistsInfoTitleByName(string name)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
class Manager {
|
|
|
|
|
+ {static} readonly int MAX_NAME_LENGTH = 75
|
|
|
|
|
+ {static} readonly int MAX_DESCRIPTION_LENGTH = 500
|
|
|
|
|
+ {static} readonly string DEFAULT_NAME = "Unknown"
|
|
|
|
|
+ {static} readonly string DEFAULT_URL = "none.png"
|
|
|
|
|
+ {static} readonly string DEFAULT_DESC = ""
|
|
|
|
|
+ IDataManager DataManager
|
|
|
|
|
- ObservableCollection<Album> Albums
|
|
|
|
|
- ObservableCollection<CustomTitle> CustomTitles
|
|
|
|
|
- ObservableCollection<InfoTitle> InfoTitles
|
|
|
|
|
- ObservableCollection<Playlist> Playlists
|
|
|
|
|
- ObservableCollection<Artist> Artists
|
|
|
|
|
+ Album CurrentAlbum
|
|
|
|
|
+ Playlist CurrentPlaylist
|
|
|
|
|
+ InfoTitle CurrentInfoTitle
|
|
|
|
|
+ CustomTitle CurrentPlaying
|
|
|
|
|
+ Manager(IDataManager dataManager)
|
|
|
|
|
+ void NextTitle()
|
|
|
|
|
+ void PreviousTitle()
|
|
|
|
|
+ CustomTitle CurrentTitle()
|
|
|
|
|
+ void Loop()
|
|
|
|
|
+ void Shuffle()
|
|
|
|
|
+ void AddAlbum(Album album)
|
|
|
|
|
+ void AddCustomTitle(CustomTitle title)
|
|
|
|
|
+ void AddInfoTitle(InfoTitle title)
|
|
|
|
|
+ void AddPlaylist(Playlist playlist)
|
|
|
|
|
+ void AddArtist(Artist artist)
|
|
|
|
|
+ void RemoveAlbum(Album album)
|
|
|
|
|
+ void RemoveCustomTitle(CustomTitle title)
|
|
|
|
|
+ void RemoveInfoTitle(InfoTitle title)
|
|
|
|
|
+ void RemovePlaylist(Playlist playlist)
|
|
|
|
|
+ ObservableCollection<Playlist> GetPlaylists()
|
|
|
|
|
+ ObservableCollection<Album> GetAlbums()
|
|
|
|
|
+ ObservableCollection<CustomTitle> GetCustomTitles()
|
|
|
|
|
+ ObservableCollection<InfoTitle> GetInfoTitles()
|
|
|
|
|
+ ObservableCollection<Artist> GetArtists()
|
|
|
|
|
+ void LoadSerialization()
|
|
|
|
|
+ void SaveSerialization()
|
|
|
|
|
+ Playlist GetPlaylistByName(string name)
|
|
|
|
|
+ Artist GetArtistByName(string name)
|
|
|
|
|
+ CustomTitle GetCustomTitleByPath(string path)
|
|
|
|
|
+ InfoTitle GetInfoTitleByName(string name)
|
|
|
|
|
+ Album GetAlbumByName(string name)
|
|
|
|
|
+ Album GetAlbumById(long id)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
class StubManager {
|
|
|
|
|
+ StubAlbum StubAlbum
|
|
|
|
|
+ StubArtist StubArtist
|
|
|
|
@ -362,132 +398,6 @@ class LinqXmlSerialization {
|
|
|
|
|
+ bool ExistsInfoTitleByName(string name)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
Album o-- "+ Artist" Artist
|
|
|
|
|
Album *-- "+ InfoTitles*" InfoTitle
|
|
|
|
|
Album .. Manager
|
|
|
|
|
|
|
|
|
|
Artist .. Manager
|
|
|
|
|
|
|
|
|
|
Playlist o-- "+ Titles*" CustomTitle
|
|
|
|
|
Playlist .. Manager
|
|
|
|
|
|
|
|
|
|
Title .. Manager
|
|
|
|
|
|
|
|
|
|
CustomTitle --|> Title
|
|
|
|
|
|
|
|
|
|
InfoTitle --|> Title
|
|
|
|
|
InfoTitle o-- "+ Genre" Genre
|
|
|
|
|
InfoTitle o-- "+ Artist" Artist
|
|
|
|
|
InfoTitle o-- "+ Feat*" Artist
|
|
|
|
|
|
|
|
|
|
Manager *-- "+ DataManager" IDataManager
|
|
|
|
|
Manager o-- "+ Albums*" Album
|
|
|
|
|
Manager o-- "+ Artists*" Artist
|
|
|
|
|
Manager o-- "+ InfoTitles*" InfoTitle
|
|
|
|
|
Manager o-- "+ Playlists*" Playlist
|
|
|
|
|
Manager o-- "+ CustomTitles*" CustomTitle
|
|
|
|
|
Manager o-- "+ CurrentAlbum" Album
|
|
|
|
|
Manager o-- "+ CurrentPlaylist" Playlist
|
|
|
|
|
Manager o-- "+ CurrentInfoTitle" InfoTitle
|
|
|
|
|
Manager o-- "+ CurrentPlaying" CustomTitle
|
|
|
|
|
|
|
|
|
|
StubManager --|> IDataManager
|
|
|
|
|
StubManager .. InfoTitle
|
|
|
|
|
StubManager .. Artist
|
|
|
|
|
StubManager .. Album
|
|
|
|
|
StubManager .. CustomTitle
|
|
|
|
|
StubManager .. Playlist
|
|
|
|
|
|
|
|
|
|
LinqXmlSerialization --|> IDataManager
|
|
|
|
|
LinqXmlSerialization o-- "+ Artists*" Artist
|
|
|
|
|
LinqXmlSerialization o-- "+ Albums*" Album
|
|
|
|
|
LinqXmlSerialization o-- "+ Playlists*" Playlist
|
|
|
|
|
LinqXmlSerialization o-- "+ Infotitles*" InfoTitle
|
|
|
|
|
LinqXmlSerialization o-- "+ Customtitles*" CustomTitle
|
|
|
|
|
|
|
|
|
|
IDataManager .. Album
|
|
|
|
|
IDataManager .. Artist
|
|
|
|
|
IDataManager .. InfoTitle
|
|
|
|
|
IDataManager .. CustomTitle
|
|
|
|
|
IDataManager .. Playlist
|
|
|
|
|
IDataManager .. Genre
|
|
|
|
|
|
|
|
|
|
@enduml
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
```plantuml
|
|
|
|
|
@startuml
|
|
|
|
|
|
|
|
|
|
class StubManager {
|
|
|
|
|
+ StubAlbum StubAlbum
|
|
|
|
|
+ StubArtist StubArtist
|
|
|
|
|
+ StubCustomTitle StubCustomTitle
|
|
|
|
|
+ StubInfoTitle StubInfoTitle
|
|
|
|
|
+ StubPlaylist StubPlaylist
|
|
|
|
|
+ StubManager()
|
|
|
|
|
+ ObservableCollection<Album> GetAlbums()
|
|
|
|
|
+ List<Artist> GetArtists()
|
|
|
|
|
+ ObservableCollection<Playlist> GetPlaylists()
|
|
|
|
|
+ ObservableCollection<CustomTitle> GetCustomTitles()
|
|
|
|
|
+ ObservableCollection<InfoTitle> GetInfoTitles()
|
|
|
|
|
+ void AddAlbum(Album album)
|
|
|
|
|
+ void AddCustomTitle(CustomTitle title)
|
|
|
|
|
+ void AddInfoTitle(InfoTitle title)
|
|
|
|
|
+ {static} void AddFeat(InfoTitle infoTitle, Artist artist)
|
|
|
|
|
+ void AddPlaylist(Playlist playlist)
|
|
|
|
|
+ void AddArtist(Artist artist)
|
|
|
|
|
+ void RemoveAlbum(Album album)
|
|
|
|
|
+ void RemoveCustomTitle(CustomTitle title)
|
|
|
|
|
+ void RemoveInfoTitle(InfoTitle title)
|
|
|
|
|
+ void RemovePlaylist(Playlist playlist)
|
|
|
|
|
+ void RemoveArtist(Artist artist)
|
|
|
|
|
+ void LoadSerialization()
|
|
|
|
|
+ void SaveSerialization()
|
|
|
|
|
+ CustomTitle GetCustomTitleByPath(string custom)
|
|
|
|
|
+ InfoTitle GetInfoTitleByName(string name)
|
|
|
|
|
+ Album GetAlbumByName(string name)
|
|
|
|
|
+ Artist GetArtistByName(string name)
|
|
|
|
|
+ void AddAlbums(List<Album> albumsList)
|
|
|
|
|
+ void AddArtists(List<Artist> artistsList)
|
|
|
|
|
+ void AddPlaylists(List<Playlist> playlistsList)
|
|
|
|
|
+ void AddCustomTitles(List<CustomTitle> customTitlesList)
|
|
|
|
|
+ void AddInfoTitles(List<InfoTitle> infoTitlesList)
|
|
|
|
|
+ Playlist GetPlaylistByName(string name)
|
|
|
|
|
+ void UpdateCustomTitle(CustomTitle title, string name, string url, string info, string path)
|
|
|
|
|
+ void UpdateCustomTitleByPath(string path, string name, string newUrl, string info, string newPath)
|
|
|
|
|
+ void UpdateInfoTitle(InfoTitle title, string name, string url, string info, Artist artist, string description, Genre genre)
|
|
|
|
|
+ void UpdateInfoTitleByName(string name, string newUrl, string info, Artist artist, string description, Genre genre)
|
|
|
|
|
+ void UpdateAlbum(Album album, string name, string url, Artist artist, string description, string info)
|
|
|
|
|
+ void UpdateAlbumByName(string name, string newUrl, Artist artist, string description, string info)
|
|
|
|
|
+ void UpdateAlbumByArtistName(Album album, string name, string url, string artist, string description, string info)
|
|
|
|
|
+ void UpdateAlbumByNameByArtistName(string name, string newUrl, string artist, string description, string info)
|
|
|
|
|
+ void UpdatePlaylist(Playlist playlist, string name, string description, string url)
|
|
|
|
|
+ void UpdatePlaylistByName(string name, string description, string newUrl)
|
|
|
|
|
+ void UpdateArtist(Artist artist, string name)
|
|
|
|
|
+ void UpdateArtistByName(string name, string newName)
|
|
|
|
|
+ void RemoveAlbums(List<Album> albumsList)
|
|
|
|
|
+ void RemoveArtists(List<Artist> artistsList)
|
|
|
|
|
+ void RemovePlaylists(List<Playlist> playlistsList)
|
|
|
|
|
+ void RemoveCustomTitles(List<CustomTitle> customTitlesList)
|
|
|
|
|
+ void RemoveInfoTitles(List<InfoTitle> infoTitlesList)
|
|
|
|
|
+ bool ExistsPlaylist(Playlist playlist)
|
|
|
|
|
+ bool ExistsPlaylistByName(string name)
|
|
|
|
|
+ bool ExistsAlbum(Album album)
|
|
|
|
|
+ bool ExistsAlbumByName(string name)
|
|
|
|
|
+ bool ExistsArtist(Artist artist)
|
|
|
|
|
+ bool ExistsArtistByName(string name)
|
|
|
|
|
+ bool ExistsCustomTitle(CustomTitle title)
|
|
|
|
|
+ bool ExistsCustomTitleByName(string name)
|
|
|
|
|
+ bool ExistsInfoTitle(InfoTitle title)
|
|
|
|
|
+ bool ExistsInfoTitleByName(string name)
|
|
|
|
|
+ Album GetAlbumById(long id)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class StubAlbum {
|
|
|
|
|
+ StubArtist StubArtist
|
|
|
|
|
+ ObservableCollection<Album> Albums
|
|
|
|
@ -537,23 +447,34 @@ class StubPlaylist {
|
|
|
|
|
+ void RemovePlaylist(Playlist playlist)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
LinqXmlSerialization --|> IDataManager
|
|
|
|
|
StubManager --|> IDataManager
|
|
|
|
|
StubManager *-- "+ StubArtist" StubArtist
|
|
|
|
|
StubManager *-- "+ StubPlaylist" StubPlaylist
|
|
|
|
|
StubManager *-- "+ StubAlbum" StubAlbum
|
|
|
|
|
StubManager *-- "+ StubInfoTitle" StubInfoTitle
|
|
|
|
|
StubManager *-- "+ StubCustomTitle" StubCustomTitle
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
StubInfoTitle *-- "+ StubArtist" StubArtist
|
|
|
|
|
StubAlbum *-- "+ StubArtist" StubArtist
|
|
|
|
|
|
|
|
|
|
LinqXmlSerialization o-- "+ StubInfoTitle" StubInfoTitle
|
|
|
|
|
|
|
|
|
|
@enduml
|
|
|
|
|
````
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
```plantuml
|
|
|
|
|
@startuml
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@enduml
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
# Note
|
|
|
|
|
|
|
|
|
|
*Les classes CustomTitle, Playlist et Manager héritent de l'interface INotifyPropertyChanged afin de permettre le DataBinding de ces classes*
|
|
|
|
|