forked from airsonic-advanced/airsonic-advanced
-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#318 Changed search results to show folder
- Loading branch information
1 parent
b85c8f7
commit 4ebc7a9
Showing
5 changed files
with
330 additions
and
75 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
81 changes: 81 additions & 0 deletions
81
airsonic-main/src/main/java/org/airsonic/player/command/SearchResultAlbum.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
/* | ||
This file is part of Airsonic. | ||
Airsonic is free software: you can redistribute it and/or modify | ||
it under the terms of the GNU General Public License as published by | ||
the Free Software Foundation, either version 3 of the License, or | ||
(at your option) any later version. | ||
Airsonic is distributed in the hope that it will be useful, | ||
but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
GNU General Public License for more details. | ||
You should have received a copy of the GNU General Public License | ||
along with Airsonic. If not, see <http://www.gnu.org/licenses/>. | ||
Copyright 2024 (C) Y.Tory | ||
*/ | ||
package org.airsonic.player.command; | ||
|
||
import org.airsonic.player.domain.MusicFolder; | ||
|
||
import java.util.HashSet; | ||
import java.util.Set; | ||
|
||
public class SearchResultAlbum { | ||
|
||
private String album; | ||
|
||
private String artist; | ||
|
||
private MusicFolder folder; | ||
|
||
private Set<Integer> mediaFileIds = new HashSet<>(); | ||
|
||
public SearchResultAlbum(String album, String artist, MusicFolder folder) { | ||
this.album = album; | ||
this.artist = artist; | ||
this.folder = folder; | ||
} | ||
|
||
public String getAlbum() { | ||
return album; | ||
} | ||
|
||
public void setAlbum(String album) { | ||
this.album = album; | ||
} | ||
|
||
public String getArtist() { | ||
return artist; | ||
} | ||
|
||
public void setArtist(String artist) { | ||
this.artist = artist; | ||
} | ||
|
||
public MusicFolder getFolder() { | ||
return folder; | ||
} | ||
|
||
public void setFolder(MusicFolder folder) { | ||
this.folder = folder; | ||
} | ||
|
||
public Set<Integer> getMediaFileIds() { | ||
return mediaFileIds; | ||
} | ||
|
||
public void setMediaFileIds(Set<Integer> mediaFileIds) { | ||
this.mediaFileIds = mediaFileIds; | ||
} | ||
|
||
public void addMediaFileId(Integer mediaFileId) { | ||
this.mediaFileIds.add(mediaFileId); | ||
} | ||
|
||
public void addMediaFileIds(Set<Integer> mediaFileIds) { | ||
this.mediaFileIds.addAll(mediaFileIds); | ||
} | ||
} |
71 changes: 71 additions & 0 deletions
71
airsonic-main/src/main/java/org/airsonic/player/command/SearchResultArtist.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
/* | ||
This file is part of Airsonic. | ||
Airsonic is free software: you can redistribute it and/or modify | ||
it under the terms of the GNU General Public License as published by | ||
the Free Software Foundation, either version 3 of the License, or | ||
(at your option) any later version. | ||
Airsonic is distributed in the hope that it will be useful, | ||
but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
GNU General Public License for more details. | ||
You should have received a copy of the GNU General Public License | ||
along with Airsonic. If not, see <http://www.gnu.org/licenses/>. | ||
Copyright 2024 (C) Y.Tory | ||
*/ | ||
package org.airsonic.player.command; | ||
|
||
import org.airsonic.player.domain.MusicFolder; | ||
|
||
import java.util.HashSet; | ||
import java.util.Set; | ||
|
||
public class SearchResultArtist { | ||
|
||
private String artist; | ||
|
||
private MusicFolder folder; | ||
|
||
private Set<Integer> mediaFileIds = new HashSet<>(); | ||
|
||
public SearchResultArtist(String artist, MusicFolder folder) { | ||
this.artist = artist; | ||
this.folder = folder; | ||
} | ||
|
||
public String getArtist() { | ||
return artist; | ||
} | ||
|
||
public void setArtist(String artist) { | ||
this.artist = artist; | ||
} | ||
|
||
public MusicFolder getFolder() { | ||
return folder; | ||
} | ||
|
||
public void setFolder(MusicFolder folder) { | ||
this.folder = folder; | ||
} | ||
|
||
public Set<Integer> getMediaFileIds() { | ||
return mediaFileIds; | ||
} | ||
|
||
public void setMediaFileIds(Set<Integer> mediaFileIds) { | ||
this.mediaFileIds = mediaFileIds; | ||
} | ||
|
||
public void addMediaFileId(Integer mediaFileId) { | ||
this.mediaFileIds.add(mediaFileId); | ||
} | ||
|
||
public void addMediaFileIds(Set<Integer> mediaFileIds) { | ||
this.mediaFileIds.addAll(mediaFileIds); | ||
} | ||
|
||
} |
Oops, something went wrong.