aboutsummaryrefslogtreecommitdiff
path: root/VKPC/Playlist.h
blob: 9a36bab1a03d42772ebc84107e2603150a4e60e4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
//
//  Playlist.h
//  VKPC
//
//  Created by Evgeny on 12/4/13.
//  Copyright (c) 2013-2014 Eugene Z. All rights reserved.
//

#import <Foundation/Foundation.h>

@protocol PlaylistDelegate <NSObject>
- (void)playlistIDChanged:(NSInteger)playlistID;
+ (void)playlistIDChanged:(NSInteger)playlistID;
@end

@interface Playlist : NSObject

@property (strong, nonatomic) NSMutableArray *tracks;

@property (strong, nonatomic) NSString *title;
@property (strong, nonatomic) NSString *lastTitle;

@property (assign, nonatomic) NSInteger playlistID;
@property (assign) NSInteger lastPlaylistID;

@property (assign) NSInteger lastTracksCount;

@property (assign) PlayingTrackStatus playing;
@property (assign) PlayingTrackStatus lastPlaying;

@property (strong) NSString *browser; // TODO delete
@property (strong) id<PlaylistDelegate> delegate;

- (void)replaceWithDataFromPlaylist:(Playlist *)pl;
- (int)trackIndexById:(NSString *)_id;
- (void)setPlayingStatus:(PlayingStatus)status;
- (void)setPlayingIndex:(NSInteger)index;
- (void)clear;
- (BOOL)changed;
- (BOOL)empty;

@end