1
0
mirror of https://github.com/danog/Telegram.git synced 2024-12-03 09:57:46 +01:00
Telegram/Telegraph/TGBridgeServer.h

37 lines
1.1 KiB
C
Raw Normal View History

2015-10-01 18:19:52 +02:00
#import <SSignalKit/SSignalKit.h>
@class TGBridgeContext;
2016-02-25 01:03:51 +01:00
@class TGBridgeMessage;
2015-10-01 18:19:52 +02:00
@interface TGBridgeServer : NSObject
@property (nonatomic, readonly) NSURL *temporaryFilesURL;
@property (nonatomic, readonly) bool isWatchAppInstalled;
@property (nonatomic, readonly) bool isRunning;
- (void)startRunning;
- (void)startServices;
2016-02-25 01:03:51 +01:00
- (SSignal *)watchAppInstalledSignal;
2015-10-01 18:19:52 +02:00
- (void)setAuthorized:(bool)authorized userId:(int32_t)userId;
- (void)setPasscodeEnabled:(bool)passcodeEnabled passcodeEncrypted:(bool)passcodeEncrypted;
2016-02-25 01:03:51 +01:00
- (void)setMicAccessAllowed:(bool)allowed;
- (void)setCustomLocalizationEnabled:(bool)enabled;
- (void)setStartupData:(NSDictionary *)dataObject micAccessAllowed:(bool)micAccessAllowed;
2015-10-01 18:19:52 +02:00
2016-02-25 01:03:51 +01:00
- (void)sendFileWithURL:(NSURL *)url metadata:(NSDictionary *)metadata;
2015-10-01 18:19:52 +02:00
- (SSignal *)serviceSignalForKey:(NSString *)key producer:(SSignal *(^)())producer;
2016-02-25 01:03:51 +01:00
- (void)startSignalForKey:(NSString *)key producer:(SSignal *(^)())producer;
- (SSignal *)pipeForKey:(NSString *)key;
- (void)putNext:(id)next forKey:(NSString *)key;
2015-10-01 18:19:52 +02:00
- (NSInteger)wakeupNetwork;
- (void)suspendNetworkIfReady:(NSInteger)token;
+ (instancetype)instance;
@end