Debian Codegraph @

Playlist.h

raw symbols ◀ ▶ SCIP
1 Debian patch touch this file
1 /* Playlist.h - this file is part of Cynthiune
2 *
3 * Copyright (C) 2005 Wolfgang Sourdeau
4 *
5 * Author: Wolfgang Sourdeau <[email protected]>
6 *
7 * This file is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; either version 2, or (at your option)
10 * any later version.
11 *
12 * This file is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program; see the file COPYING. If not, write to
19 * the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
20 * Boston, MA 02111-1307, USA.
21 */
22
23 #ifndef Playlist_H
24 #define Playlist_H
25
26 @class NSNumber;
27 @class NSMutableArray;
28 @class Song;
29
30 @interface Playlist : NSObject
31 {
32 id delegate;
33 NSMutableArray *list;
34 NSMutableArray *shuffleList;
35 }
36
37 - (id) init;
38
39 - (void) setDelegate: (id) object;
40 - (id) delegate;
41
42 - (void) addSong: (Song *) song;
43 - (void) addSongsInArray: (NSArray *) array;
44 - (void) insertSong: (Song *) song
45 atIndex: (unsigned int) index;
46
47 - (void) deleteSong: (Song *) song;
48 - (void) deleteAllSongs;
49 - (void) deleteAllSongsQuietly;
50 - (void) deleteSongsInArray: (NSArray *) array;
51 - (NSArray *) arrayOfInvalidSongs;
52
53 - (void) replaceSongsWithArray: (NSArray *) array;
54
•55 - (Song *) songAtIndex: (NSUInteger) index;
56 - (NSUInteger) indexOfSong: (Song *) song;
57
•58 - (NSUInteger) moveSongsAtIndexes: (NSArray *) indexes
59 toIndex: (NSUInteger) index;
60
61 - (Song *) firstSong;
62 - (Song *) lastSong;
63 - (Song *) firstValidSong;
64 - (Song *) lastValidSong;
65
66 - (Song *) songAfter: (Song *) song;
67 - (Song *) songBefore: (Song *) song;
68 - (Song *) validSongAfter: (Song *) song;
69 - (Song *) validSongBefore: (Song *) song;
70
•71 - (NSUInteger) numberOfSongs;
72
73 - (NSNumber *) duration;
74
75 - (void) loadFromFile: (NSString *) file;
76 - (void) saveToFile: (NSString *) file;
77
78 - (void) sortByPlaylistRepresentation: (BOOL) reverseOrder;
79 - (void) sortByDuration: (BOOL) reverseOrder;
80
81 - (void) setShuffle: (BOOL) shuffle;
82 - (BOOL) shuffle;
83 - (void) shuffleFromSong: (Song *) shuffle;
84
85 @end
86
87 #endif /* Playlist_H */