-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathApiDefinition.cs
890 lines (607 loc) · 26.9 KB
/
ApiDefinition.cs
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
using System;
using MonoTouch.Foundation;
using MonoTouch.UIKit;
namespace ChromeCast {
public enum GCKPlayerState {
Unknown = -1,
Idle = 0,
Stopped = 1,
Playing = 2
}
public enum GCKMediaTrackType {
Unknown = 0,
Subtitles = 1,
Captions = 2,
Audio = 3,
Video = 4
}
[BaseType (typeof (NSObject))]
public partial interface GCKApplicationChannel {
[Export ("delegate")]
GCKApplicationChannelDelegate Delegate { get; set; }
[Export ("sendBufferAvailableBytes")]
int SendBufferAvailableBytes { get; }
[Export ("sendBufferPendingBytes")]
int SendBufferPendingBytes { get; }
[Export ("initWithBufferSize:pingInterval:")]
IntPtr Constructor (int bufferSize, double pingInterval);
[Export ("connectTo:")]
bool ConnectTo (NSUrl url);
[Export ("disconnect")]
void Disconnect ();
[Export ("attachMessageStream:")]
bool AttachMessageStream (GCKMessageStream stream);
[Export ("detachMessageStream:")]
bool DetachMessageStream (GCKMessageStream stream);
[Export ("detachAllMessageStreams")]
void DetachAllMessageStreams ();
}
[Category, BaseType (typeof (GCKApplicationChannel))]
public partial interface UnitTestSupport_GCKApplicationChannel {
[Export ("dispatchMessage:")]
void DispatchMessage (string message);
[Export ("sendMessageWithNamespace:message:")]
bool SendMessageWithNamespace (string nameSpace, NSObject message);
}
[Model, BaseType (typeof (NSObject))]
public partial interface GCKApplicationChannelDelegate {
[Export ("applicationChannelDidConnect:")]
void DidConnect(GCKApplicationChannel channel);
[Export ("applicationChannel:connectionDidFailWithError:")]
void ConnectionDidFailWithError (GCKApplicationChannel channel, GCKError error);
[Export ("applicationChannel:didDisconnectWithError:")]
void DidDisconnectWithError (GCKApplicationChannel channel, GCKError error);
}
[BaseType (typeof (NSObject))]
public partial interface GCKApplicationMetadata {
[Export ("name")]
string Name { get; }
[Export ("title")]
string Title { get; }
[Export ("publisher")]
string Publisher { get; }
[Export ("version")]
string Version { get; }
[Export ("secondScreenLaunchInfo")]
string SecondScreenLaunchInfo { get; }
[Export ("iconURL")]
NSUrl IconURL { get; }
[Export ("initWithName:title:publisher:version:secondScreenLaunchInfo:iconURL:supportedProtocols:")]
IntPtr Constructor (string name, string title, string publisher, string version, string launchInfo, NSUrl iconURL, NSObject [] supportedProtocols);
[Export ("doesSupportProtocol:")]
bool DoesSupportProtocol (string protocol);
}
public partial interface GCKMimeData {
[Field ("kGCKApplicationSessionMinBufferSize", "__Internal")]
int GCKApplicationSessionMinBufferSize { get; }
[Field ("kGCKApplicationSessionDefaultBufferSize", "__Internal")]
int GCKApplicationSessionDefaultBufferSize { get; }
}
[BaseType (typeof (NSObject))]
public partial interface GCKApplicationSession : GCKApplicationChannelDelegate {
[Export ("delegate")]
GCKApplicationSessionDelegate Delegate { get; set; }
[Export ("applicationInfo")]
GCKApplicationMetadata ApplicationInfo { get; }
[Export ("channel")]
GCKApplicationChannel Channel { get; }
[Export ("hasStarted")]
bool HasStarted { get; }
[Export ("bufferSize")]
int BufferSize { get; }
[Export ("stopApplicationWhenSessionEnds")]
bool StopApplicationWhenSessionEnds { get; set; }
[Export ("initWithContext:device:bufferSize:")]
IntPtr Constructor (GCKContext context, GCKDevice device, int bufferSize);
[Export ("initWithContext:device:")]
IntPtr Constructor (GCKContext context, GCKDevice device);
[Export ("startSession")]
bool StartSession { get; }
[Export ("startSessionWithApplication:")]
bool StartSessionWithApplication (string applicationName);
[Export ("startSessionWithApplication:argument:")]
bool StartSessionWithApplication (string applicationName, GCKMimeData argument);
[Export ("endSession")]
bool EndSession { get; }
[Export ("resumeSession")]
bool ResumeSession { get; }
}
[Model, BaseType(typeof(NSObject))]
public partial interface GCKApplicationSessionDelegate {
[Export ("applicationSessionDidStart")]
void ApplicationSessionDidStart ();
[Export ("applicationSessionDidFailToStartWithError:")]
void ApplicationSessionDidFailToStart (GCKApplicationSessionError error);
[Export ("applicationSessionDidEndWithError:")]
void ApplicationSessionDidEnd(GCKApplicationSessionError error);
[Field ("kGCKApplicationSessionErrorDomain", "__Internal")]
NSString GCKApplicationSessionErrorDomain { get; }
}
[BaseType (typeof (NSError))]
public partial interface GCKError {
[Export ("causedByError")]
NSError CausedByError { get; }
[Export ("initWithDomain:code:causedByError:")]
IntPtr Constructor (string domain, int code, NSError error);
[Export ("initWithDomain:code:causedByError:additionalUserInfo:")]
IntPtr Constructor (string domain, int code, NSError error, NSDictionary additionalUserInfo);
[Static, Export ("localizedDescriptionForCode:")]
string LocalizedDescriptionForCode (int code);
[Field ("kGCKApplicationSessionErrorCodeFailedToStartApplication", "__Internal")]
int GCKApplicationSessionErrorCodeFailedToStartApplication { get; }
[Field ("kGCKApplicationSessionErrorCodeFailedToQueryApplication", "__Internal")]
int GCKApplicationSessionErrorCodeFailedToQueryApplication { get; }
[Field ("kGCKApplicationSessionErrorCodeApplicationStopped", "__Internal")]
int GCKApplicationSessionErrorCodeApplicationStopped { get; }
[Field ("kGCKApplicationSessionErrorCodeFailedToCreateChannel", "__Internal")]
int GCKApplicationSessionErrorCodeFailedToCreateChannel { get; }
[Field ("kGCKApplicationSessionErrorCodeFailedToConnectChannel", "__Internal")]
int GCKApplicationSessionErrorCodeFailedToConnectChannel { get; }
[Field ("kGCKApplicationSessionErrorCodeChannelDisconnected", "__Internal")]
int GCKApplicationSessionErrorCodeChannelDisconnected { get; }
[Field ("kGCKApplicationSessionErrorCodeFailedToStopApplication", "__Internal")]
int GCKApplicationSessionErrorCodeFailedToStopApplication { get; }
[Field ("kGCKApplicationSessionErrorCodeUnknownError", "__Internal")]
int GCKApplicationSessionErrorCodeUnknownError { get; }
}
[BaseType (typeof (GCKError))]
public partial interface GCKApplicationSessionError {
[Export ("initWithCode:causedByError:")]
IntPtr Constructor (int code, NSError error);
[Static, Export ("localizedDescriptionForCode:")]
string LocalizedDescriptionForCode (int code);
}
[BaseType (typeof (NSObject))]
public partial interface GCKDeviceManager {
[Export ("devices")]
NSObject [] Devices { get; }
[Export ("hasDiscoveredDevices")]
bool HasDiscoveredDevices { get; }
[Export ("context")]
GCKContext Context { get; }
[Export ("scanning")]
bool Scanning { get; }
[Export ("initWithContext:")]
IntPtr Constructor (GCKContext context);
[Export ("startScan")]
void StartScan ();
[Export ("stopScan")]
void StopScan ();
[Export ("addListener:")]
void AddListener (GCKDeviceManagerListener listener);
[Export ("removeListener:")]
void RemoveListener (GCKDeviceManagerListener listener);
}
[Model, BaseType (typeof (NSObject))]
public partial interface GCKDeviceManagerListener {
[Export ("scanStarted")]
void ScanStarted ();
[Export ("scanStopped")]
void ScanStopped ();
[Export ("deviceDidComeOnline:")]
void DeviceDidComeOnline (GCKDevice device);
[Export ("deviceDidGoOffline:")]
void DeviceDidGoOffline (GCKDevice device);
}
[BaseType (typeof (NSObject))]
public partial interface GCKApplicationSupportFilterListener : GCKDeviceManagerListener {
[Export ("initWithContext:applicationName:protocols:downstreamListener:")]
IntPtr Constructor (GCKContext context, string applicationName, NSObject [] protocols, GCKDeviceManagerListener listener);
// [Export ("scanStarted")]
// void ScanStarted ();
//
// [Export ("deviceDidComeOnline:")]
// void DeviceDidComeOnline (GCKDevice device);
//
// [Export ("deviceDidGoOffline:")]
// void DeviceDidGoOffline (GCKDevice device);
//
// [Export ("scanStopped")]
// void ScanStopped ();
}
[Category, BaseType (typeof (NSData))]
public partial interface GCKBase64_NSData {
[Export ("gck_dataWithBase64EncodedString:")]
NSData Gck_dataWithBase64EncodedString (string str);
[Export ("gck_base64EncodedString")]
string GetGck_base64EncodedString();
[Export ("gck_base64EncodedStringWithWrapWidth:")]
string Gck_base64EncodedStringWithWrapWidth (int width);
}
[Category, BaseType (typeof (NSString))]
public partial interface GCKBase64_NSString {
[Export ("gck_stringWithBase64EncodedString:")]
string Gck_stringWithBase64EncodedString (string str);
[Static, Export ("gck_base64EncodedString")]
string GetGck_base64EncodedString();
[Export ("gck_base64EncodedStringWithWrapWidth:")]
string Gck_base64EncodedStringWithWrapWidth (int wrapWidth);
[Export ("gck_base64DecodedString")]
string GetGck_base64DecodedString();
[Export ("gck_base64DecodedData")]
NSData GetGck_base64DecodedData();
}
[BaseType (typeof (NSObject))]
public partial interface GCKContentMetadata {
[Export ("title")]
string Title { get; set; }
[Export ("imageURL")]
NSUrl ImageURL { get; set; }
[Export ("contentInfo")]
NSDictionary ContentInfo { get; set; }
[Export ("initWithTitle:imageURL:contentInfo:")]
IntPtr Constructor (string title, NSUrl imageURL, NSDictionary contentInfo);
[Field ("kGCKVersion", "__Internal")]
NSString GCKVersion { get; }
}
[BaseType (typeof (NSObject))]
public partial interface GCKContext {
[Export ("userAgent")]
string UserAgent { get; }
[Export ("initWithUserAgent:")]
IntPtr Constructor (string userAgent);
}
[BaseType (typeof (NSObject))]
public partial interface GCKDevice {
[Export ("ipAddress")]
string IpAddress { get; }
[Export ("deviceID")]
string DeviceID { get; set; }
[Export ("friendlyName")]
string FriendlyName { get; set; }
[Export ("manufacturer")]
string Manufacturer { get; set; }
[Export ("modelName")]
string ModelName { get; set; }
[Export ("applicationURL")]
NSUrl ApplicationURL { get; set; }
[Export ("icons")]
NSObject [] Icons { get; set; }
[Export ("initWithIPAddress:")]
IntPtr Constructor (string ipAddress);
}
[BaseType (typeof (NSObject))]
public partial interface GCKDeviceIcon {
[Export ("width")]
int Width { get; }
[Export ("height")]
int Height { get; }
[Export ("depth")]
int Depth { get; }
[Export ("url")]
NSUrl Url { get; }
[Export ("initWithWidth:height:depth:url:")]
IntPtr Constructor (int width, int height, int depth, NSUrl url);
}
[BaseType (typeof (GCKError))]
public partial interface GCKNetworkRequestError {
[Export ("initWithCode:causedByError:")]
IntPtr Constructor (int code, NSError error);
[Static, Export ("localizedDescriptionForCode:")]
string LocalizedDescriptionForCode (int code);
}
public partial interface GCKMimeData {
[Field ("kGCKNetworkRequestDefaultTimeout", "__Internal")]
double GCKNetworkRequestDefaultTimeout { get; }
[Field ("kGCKNetworkRequestHTTPOriginValue", "__Internal")]
NSString GCKNetworkRequestHTTPOriginValue { get; }
}
[Model, BaseType (typeof (NSObject))]
public partial interface GCKNetworkRequestDelegate {
[Export ("networkRequestDidComplete:")]
void DidComplete(GCKNetworkRequest request);
[Export ("networkRequest:didFailWithError:")]
void DidFailWithError (GCKNetworkRequest request, GCKNetworkRequestError error);
[Export ("networkRequestWasCancelled:")]
void WasCancelled(GCKNetworkRequest request);
}
[BaseType (typeof (NSObject))]
public partial interface GCKNetworkRequest {
[Export ("delegate")]
GCKNetworkRequestDelegate Delegate { get; set; }
[Export ("responseEncoding")]
NSStringEncoding ResponseEncoding { get; set; }
[Export ("initWithContext:")]
IntPtr Constructor (GCKContext context);
[Export ("execute")]
void Execute ();
[Export ("cancel")]
void Cancel ();
[Export ("performHTTPGet:timeout:")]
void PerformHTTPGet (NSUrl url, double timeout);
[Export ("performHTTPPost:data:timeout:")]
void PerformHTTPPost (NSUrl url, GCKMimeData data, double timeout);
[Export ("performHTTPDelete:timeout:")]
void PerformHTTPDelete (NSUrl url, double timeout);
[Export ("processResponseWithStatus:finalURL:headers:data:")]
int ProcessResponseWithStatus (int status, NSUrl finalURL, NSDictionary headers, GCKMimeData data);
[Export ("parseJson:")]
NSObject ParseJson (string json);
[Export ("writeJson:")]
string WriteJson (NSObject obj);
[Export ("didComplete")]
void DidComplete ();
[Export ("didFailWithError:")]
void DidFailWithError (GCKError error);
}
[BaseType (typeof (GCKNetworkRequest))]
public partial interface GCKFetchImageRequest {
[Export ("image")]
UIImage Image { get; }
[Export ("initWithContext:url:preferredWidth:preferredHeight:")]
IntPtr Constructor (GCKContext context, NSUrl url, int width, int height);
[Export ("initWithContext:url:")]
IntPtr Constructor (GCKContext context, NSUrl url);
}
[BaseType (typeof (NSObject))]
public partial interface GCKJsonUtils {
[Static, Export ("parseJson:")]
NSObject ParseJson (string json);
[Static, Export ("writeJson:")]
string WriteJson (NSObject obj);
[Static, Export ("isJsonString:equivalentTo:")]
bool IsJsonString (string actual, string expected);
[Field ("kGCKMediaProtocolCommandTypeInfo", "__Internal")]
NSString GCKMediaProtocolCommandTypeInfo { get; }
[Field ("kGCKMediaProtocolCommandTypeLoad", "__Internal")]
NSString GCKMediaProtocolCommandTypeLoad { get; }
[Field ("kGCKMediaProtocolCommandTypePlay", "__Internal")]
NSString GCKMediaProtocolCommandTypePlay { get; }
[Field ("kGCKMediaProtocolCommandTypeStop", "__Internal")]
NSString GCKMediaProtocolCommandTypeStop { get; }
[Field ("kGCKMediaProtocolCommandTypeVolume", "__Internal")]
NSString GCKMediaProtocolCommandTypeVolume { get; }
[Field ("kGCKMediaProtocolCommandTypeSelectTracks", "__Internal")]
NSString GCKMediaProtocolCommandTypeSelectTracks { get; }
[Field ("kGCKMediaProtocolErrorDomain", "__Internal")]
NSString GCKMediaProtocolErrorDomain { get; }
[Field ("kGCKMediaProtocolErrorInvalidPlayerState", "__Internal")]
int GCKMediaProtocolErrorInvalidPlayerState { get; }
[Field ("kGCKMediaProtocolErrorFailedToLoadMedia", "__Internal")]
int GCKMediaProtocolErrorFailedToLoadMedia { get; }
[Field ("kGCKMediaProtocolErrorMediaLoadCancelled", "__Internal")]
int GCKMediaProtocolErrorMediaLoadCancelled { get; }
[Field ("kGCKMediaProtocolErrorInvalidRequest", "__Internal")]
int GCKMediaProtocolErrorInvalidRequest { get; }
}
[BaseType (typeof (NSObject))]
public partial interface GCKMediaProtocolCommand {
[Export ("delegate")]
GCKMediaProtocolCommandDelegate Delegate { get; set; }
[Export ("sequenceNumber")]
int SequenceNumber { get; }
[Export ("type")]
string Type { get; }
[Export ("cancelled")]
bool Cancelled { get; }
[Export ("completed")]
bool Completed { get; }
[Export ("hasError")]
bool HasError { get; set; }
[Export ("errorDomain")]
string ErrorDomain { get; set; }
[Export ("errorCode")]
int ErrorCode { get; set; }
[Export ("errorInfo")]
NSDictionary ErrorInfo { get; set; }
[Export ("initWithSequenceNumber:type:")]
IntPtr Constructor (int sequenceNumber, string type);
[Export ("complete")]
void Complete ();
[Export ("cancel")]
void Cancel ();
}
[Model, BaseType (typeof (NSObject))]
public partial interface GCKMediaProtocolCommandDelegate {
[Export ("mediaProtocolCommandDidComplete:")]
void DidComplete(GCKMediaProtocolCommand command);
[Export ("mediaProtocolCommandWasCancelled:")]
void WasCancelled(GCKMediaProtocolCommand command);
}
[BaseType (typeof (NSObject))]
public partial interface GCKMessageStream {
[Export ("namespace")]
string Namespace { get; }
// [Export ("messageSink")]
// GCKMessageSink MessageSink { get; set; }
[Export ("initWithNamespace:")]
IntPtr Constructor (string nameSpace);
[Export ("didAttach")]
void DidAttach ();
[Export ("didDetach")]
void DidDetach ();
[Export ("didReceiveMessage:")]
void DidReceiveMessage (NSObject message);
[Export ("sendMessage:")]
bool SendMessage (NSObject message);
}
[BaseType (typeof (GCKMessageStream))]
public partial interface GCKMediaProtocolMessageStream {
[Export ("delegate")]
GCKMediaProtocolMessageStreamDelegate Delegate { get; set; }
[Export ("contentID")]
string ContentID { get; }
[Export ("contentInfo")]
NSDictionary ContentInfo { get; }
[Export ("playerState")]
ChromeCast.GCKPlayerState PlayerState { get; }
[Export ("streamPosition")]
double StreamPosition { get; }
[Export ("streamDuration")]
double StreamDuration { get; }
[Export ("mediaTitle")]
string MediaTitle { get; }
[Export ("mediaImageURL")]
NSUrl MediaImageURL { get; }
[Export ("volume")]
double Volume { get; }
[Export ("muted")]
bool Muted { get; }
[Export ("mediaTracks")]
NSMutableArray MediaTracks { get; }
// [Export ("init")]
// IntPtr Constructor ();
[Export ("loadMediaWithContentID:contentMetadata:")]
GCKMediaProtocolCommand LoadMediaWithContentID (string contentID, GCKContentMetadata metadata);
[Export ("loadMediaWithContentID:contentMetadata:autoplay:")]
GCKMediaProtocolCommand LoadMediaWithContentID (string contentID, GCKContentMetadata metadata, bool autoplay);
[Export ("resumeStream")]
GCKMediaProtocolCommand ResumeStream { get; }
[Export ("playStream")]
GCKMediaProtocolCommand PlayStream { get; }
[Export ("playStreamFrom:")]
GCKMediaProtocolCommand PlayStreamFrom (double position);
[Export ("stopStream")]
bool StopStream { get; }
[Export ("setStreamVolume:")]
GCKMediaProtocolCommand SetStreamVolume (double volume);
[Export ("setStreamMuted:")]
GCKMediaProtocolCommand SetStreamMuted (bool muted);
[Export ("selectTracksToEnable:andDisable:")]
GCKMediaProtocolCommand SelectTracksToEnable (NSObject [] tracksToEnable, NSObject [] tracksToDisable);
[Export ("requestStatus")]
GCKMediaProtocolCommand RequestStatus { get; }
[Export ("sendKeyResponseForRequestID:withTokens:")]
bool SendKeyResponseForRequestID (int requestID, NSObject [] tokens);
[Export ("cancelCommand:")]
bool CancelCommand (GCKMediaProtocolCommand command);
[Export ("keyRequestWasReceivedWithRequestID:method:requests:")]
void KeyRequestWasReceivedWithRequestID (int requestID, string method, NSObject [] requests);
[Export ("didReceiveMessage:")]
void DidReceiveMessage (NSObject message);
[Export ("didDetach")]
void DidDetach ();
}
[Model, BaseType (typeof (NSObject))]
public partial interface GCKMediaProtocolMessageStreamDelegate {
[Export ("mediaProtocolMessageStreamDidReceiveStatusUpdate:")]
void DidReceiveStatusUpdate(GCKMediaProtocolMessageStream stream);
[Export ("mediaProtocolMessageStreamDidUpdateTrackList:")]
void DidUpdateTrackList(GCKMediaProtocolMessageStream stream);
[Export ("mediaProtocolMessageStream:didReceiveErrorWithDomain:code:errorInfo:")]
void DidReceiveErrorWithDomain (GCKMediaProtocolMessageStream stream, string domain, int code, NSDictionary errorInfo);
}
[BaseType (typeof (NSObject))]
public partial interface GCKMediaTrack {
[Export ("initWithIdentifier:type:name:languageCode:enabled:")]
IntPtr Constructor (int identifier, GCKMediaTrackType type, string name, string languageCode, bool enabled);
[Export ("identifier")]
int Identifier { get; }
[Export ("type")]
GCKMediaTrackType Type { get; }
[Export ("name")]
string Name { get; }
[Export ("languageCode")]
string LanguageCode { get; }
[Export ("enabled")]
bool Enabled { get; set; }
}
[BaseType (typeof (NSObject))]
public partial interface GCKMimeData {
[Export ("type")]
string Type { get; }
[Export ("data")]
NSData Data { get; }
[Export ("textData")]
string TextData { get; }
[Export ("initWithData:type:")]
IntPtr Constructor (NSData data, string type);
[Export ("initWithTextData:type:")]
IntPtr Constructor (string data, string type);
[Static, Export ("mimeDataWithJsonObject:")]
GCKMimeData MimeDataWithJsonObject (NSObject json);
[Static, Export ("mimeDataWithURL:")]
GCKMimeData MimeDataWithURL (NSUrl url);
}
[Category, BaseType (typeof (NSDictionary))]
public partial interface GCKTypedValueLookup_NSDictionary {
[Export ("gck_stringForKey:withDefaultValue:")]
string Gck_stringForKey (string key, string defaultValue);
[Export ("gck_stringForKey:")]
string Gck_stringForKey (string key);
[Export ("gck_integerForKey:withDefaultValue:")]
int Gck_integerForKey (string key, int defaultValue);
[Export ("gck_integerForKey:")]
int Gck_integerForKey (string key);
[Export ("gck_doubleForKey:withDefaultValue:")]
double Gck_doubleForKey (string key, double defaultValue);
[Export ("gck_doubleForKey:")]
double Gck_doubleForKey (string key);
[Export ("gck_boolForKey:withDefaultValue:")]
bool Gck_boolForKey (string key, bool defaultValue);
[Export ("gck_boolForKey:")]
bool Gck_boolForKey (string key);
[Export ("gck_setStringValue:forKey:")]
void Gck_setStringValue (string value, string key);
[Export ("gck_setIntegerValue:forKey:")]
void Gck_setIntegerValue (int value, string key);
[Export ("gck_setDoubleValue:forKey:")]
void Gck_setDoubleValue (double value, string key);
[Export ("gck_setBoolValue:forKey:")]
void Gck_setBoolValue (bool value, string key);
}
[Category, BaseType (typeof (NSString))]
public partial interface GCKPatternMatching_NSString {
[Export ("gck_matchesPattern:")]
bool Gck_matchesPattern (string regexPattern);
}
public partial interface GCKMimeData {
[Field ("kGCKHTTPStatusOK", "__Internal")]
int GCKHTTPStatusOK { get; }
[Field ("kGCKHTTPStatusCreated", "__Internal")]
int GCKHTTPStatusCreated { get; }
[Field ("kGCKHTTPStatusNoContent", "__Internal")]
int GCKHTTPStatusNoContent { get; }
[Field ("kGCKHTTPStatusForbidden", "__Internal")]
int GCKHTTPStatusForbidden { get; }
[Field ("kGCKHTTPStatusNotFound", "__Internal")]
int GCKHTTPStatusNotFound { get; }
[Field ("kGCKHTTPStatusNotImplemented", "__Internal")]
int GCKHTTPStatusNotImplemented { get; }
[Field ("kGCKHTTPStatusServiceUnavailable", "__Internal")]
int GCKHTTPStatusServiceUnavailable { get; }
[Field ("kGCKHTTPHeaderLocation", "__Internal")]
NSString GCKHTTPHeaderLocation { get; }
}
[BaseType (typeof (NSObject))]
public partial interface GCKSimpleHTTPRequest {
[Export ("delegate")]
GCKSimpleHTTPRequestDelegate Delegate { get; set; }
[Export ("timeout")]
double Timeout { get; set; }
[Export ("url")]
NSUrl Url { get; }
[Export ("finalUrl")]
NSUrl FinalUrl { get; }
[Export ("responseHeaders")]
NSDictionary ResponseHeaders { get; }
// [Export ("init")]
// IntPtr Constructor ();
[Export ("startGetRequest:")]
void StartGetRequest (NSUrl url);
[Export ("startPostRequest:data:")]
void StartPostRequest (NSUrl url, GCKMimeData data);
[Export ("setValue:forHTTPHeaderField:")]
void SetValue (string value, string field);
[Export ("startDeleteRequest:")]
void StartDeleteRequest (NSUrl url);
[Export ("cancel")]
void Cancel ();
}
[Model, BaseType (typeof (NSObject))]
public partial interface GCKSimpleHTTPRequestDelegate {
// [Export ("configureURLRequest:forSimpleHTTPRequest:")]
// void ForSimpleHTTPRequest (NSMutableURLRequest request, GCKSimpleHTTPRequest simpleRequest);
[Export ("httpRequest:didCompleteWithStatusCode:finalURL:headers:data:")]
void DidCompleteWithStatusCode (GCKSimpleHTTPRequest request, int status, NSUrl finalURL, NSDictionary headers, GCKMimeData data);
[Export ("httpRequest:didFailWithError:")]
void DidFailWithError (GCKSimpleHTTPRequest request, NSError error);
}
[BaseType (typeof (GCKError))]
public partial interface GCKWebSocketError {
[Export ("initWithCode:")]
IntPtr Constructor (int code);
[Static, Export ("localizedDescriptionForCode:")]
string LocalizedDescriptionForCode (int code);
}
}