/* This file is part of the HandBrake source code.
Homepage: .
It may be used under the terms of the GNU General Public License. */
#import
NS_ASSUME_NONNULL_BEGIN
typedef NS_ENUM(NSUInteger, HBRedirectType) {
HBRedirectTypeOutput,
HBRedirectTypeError
};
@protocol HBOutputRedirectListening
- (void)redirect:(NSString *)text type:(HBRedirectType)type;
@end
@interface HBRedirect : NSObject
+ (instancetype)stdoutRedirect;
+ (instancetype)stderrRedirect;
- (void)addListener:(id )aListener queue:(dispatch_queue_t)queue;
- (void)removeListener:(id )aListener;
// Methods to subclass
- (instancetype)initWithType:(HBRedirectType)type;
- (void)forwardOutput:(NSString *)text;
- (void)startRedirect;
- (void)stopRedirect;
@end
NS_ASSUME_NONNULL_END