VLCMediaDiscoverer.h 2.91 KB
Newer Older
1
/*****************************************************************************
2
 * VLCMediaDiscoverer.h: VLCKit.framework VLCMediaDiscoverer header
3 4
 *****************************************************************************
 * Copyright (C) 2007 Pierre d'Herbemont
5 6
 * Copyright (C) 2015 Felix Paul Kühne
 * Copyright (C) 2007, 2015 VLC authors and VideoLAN
7 8 9
 * $Id$
 *
 * Authors: Pierre d'Herbemont <pdherbemont # videolan.org>
10
 *          Felix Paul Kühne <fkuehne # videolan.org>
11
 *
12 13 14
 * This program is free software; you can redistribute it and/or modify it
 * under the terms of the GNU Lesser General Public License as published by
 * the Free Software Foundation; either version 2.1 of the License, or
15 16 17 18
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
19 20
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 * GNU Lesser General Public License for more details.
21
 *
22 23 24
 * You should have received a copy of the GNU Lesser General Public License
 * along with this program; if not, write to the Free Software Foundation,
 * Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
25 26
 *****************************************************************************/

Pierre's avatar
Pierre committed
27 28
#import <Foundation/Foundation.h>
#import "VLCMediaList.h"
29

30
@class VLCMediaList;
31
@class VLCMediaDiscoverer;
32

33
/**
34
 * VLCMediaDiscovererDelegate
35
 */
36 37 38 39

@protocol VLCMediaDiscovererDelegate <NSObject>
@optional

40 41 42 43 44
/**
 * delegate method triggered when a discoverer was started
 *
 * \param the discoverer that was started
 */
45
- (void)discovererStarted:(VLCMediaDiscoverer *)theDiscoverer;
46 47 48 49 50 51

/**
 * delegate method triggered when a discoverer was stopped
 *
 * \param the discoverer that was stopped
 */
52 53 54 55
- (void)discovererStopped:(VLCMediaDiscoverer *)theDiscoverer;

@end

56 57 58 59
/**
 * VLCMediaDiscoverer
 */

60
@interface VLCMediaDiscoverer : NSObject
61

62 63 64
/**
 * delegate property to listen to start/stop events
 */
65 66
@property (weak, readwrite) id<VLCMediaDiscovererDelegate> delegate;

67 68 69 70 71
/**
 * Maintains a list of available media discoverers.  This list is populated as new media
 * discoverers are created.
 * \return A list of available media discoverers.
 */
72
+ (NSArray *)availableMediaDiscoverer;
73

74 75 76
/* Initializers */
/**
 * Initializes new object with specified name.
77
 * \param aServiceName Name of the service for this VLCMediaDiscoverer object.
78 79
 * \returns Newly created media discoverer.
 */
80
- (instancetype)initWithName:(NSString *)aServiceName;
81

82
/**
83
 * a read-only property to retrieve the list of discovered media items
84
 */
85
@property (weak, readonly) VLCMediaList *discoveredMedia;
86

87
/**
88
 * returns the localized name of the discovery module if available, otherwise in US English
89
 */
90
@property (readonly, copy) NSString *localizedName;
91

92
/**
93 94
 * read-only property to check if the discovery service is active
 * \return boolean value
95 96
 */
@property (readonly) BOOL isRunning;
97
@end