File: Atk_TableAdapter.cs

package info (click to toggle)
gnome-subtitles 1.8-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 103,144 kB
  • sloc: xml: 406,395; cs: 364,495; ansic: 3,104; perl: 1,477; sh: 769; python: 545; javascript: 500; makefile: 49
file content (1005 lines) | stat: -rw-r--r-- 35,049 bytes parent folder | download
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
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
// This file was generated by the Gtk# code generator.
// Any changes made will be lost if regenerated.

namespace Atk {

	using System;
	using System.Runtime.InteropServices;

#region Autogenerated code
	public partial class TableAdapter : GLib.GInterfaceAdapter, Atk.ITable {

		[StructLayout (LayoutKind.Sequential)]
		struct AtkTableIface {
			public RefAtNativeDelegate RefAt;
			public GetIndexAtNativeDelegate GetIndexAt;
			public GetColumnAtIndexNativeDelegate GetColumnAtIndex;
			public GetRowAtIndexNativeDelegate GetRowAtIndex;
			public GetNColumnsNativeDelegate GetNColumns;
			public GetNRowsNativeDelegate GetNRows;
			public GetColumnExtentAtNativeDelegate GetColumnExtentAt;
			public GetRowExtentAtNativeDelegate GetRowExtentAt;
			public GetCaptionNativeDelegate GetCaption;
			public GetColumnDescriptionNativeDelegate GetColumnDescription;
			public GetColumnHeaderNativeDelegate GetColumnHeader;
			public GetRowDescriptionNativeDelegate GetRowDescription;
			public GetRowHeaderNativeDelegate GetRowHeader;
			public GetSummaryNativeDelegate GetSummary;
			public SetCaptionNativeDelegate SetCaption;
			public SetColumnDescriptionNativeDelegate SetColumnDescription;
			public SetColumnHeaderNativeDelegate SetColumnHeader;
			public SetRowDescriptionNativeDelegate SetRowDescription;
			public SetRowHeaderNativeDelegate SetRowHeader;
			public SetSummaryNativeDelegate SetSummary;
			public GetSelectedColumnsNativeDelegate GetSelectedColumns;
			public GetSelectedRowsNativeDelegate GetSelectedRows;
			public IsColumnSelectedNativeDelegate IsColumnSelected;
			public IsRowSelectedNativeDelegate IsRowSelected;
			public IsSelectedNativeDelegate IsSelected;
			public AddRowSelectionNativeDelegate AddRowSelection;
			public RemoveRowSelectionNativeDelegate RemoveRowSelection;
			public AddColumnSelectionNativeDelegate AddColumnSelection;
			public RemoveColumnSelectionNativeDelegate RemoveColumnSelection;
			IntPtr RowInserted;
			IntPtr ColumnInserted;
			IntPtr RowDeleted;
			IntPtr ColumnDeleted;
			IntPtr RowReordered;
			IntPtr ColumnReordered;
			IntPtr ModelChanged;
		}

		static AtkTableIface iface;

		static TableAdapter ()
		{
			GLib.GType.Register (_gtype, typeof (TableAdapter));
			iface.RefAt = new RefAtNativeDelegate (RefAt_cb);
			iface.GetIndexAt = new GetIndexAtNativeDelegate (GetIndexAt_cb);
			iface.GetColumnAtIndex = new GetColumnAtIndexNativeDelegate (GetColumnAtIndex_cb);
			iface.GetRowAtIndex = new GetRowAtIndexNativeDelegate (GetRowAtIndex_cb);
			iface.GetNColumns = new GetNColumnsNativeDelegate (GetNColumns_cb);
			iface.GetNRows = new GetNRowsNativeDelegate (GetNRows_cb);
			iface.GetColumnExtentAt = new GetColumnExtentAtNativeDelegate (GetColumnExtentAt_cb);
			iface.GetRowExtentAt = new GetRowExtentAtNativeDelegate (GetRowExtentAt_cb);
			iface.GetCaption = new GetCaptionNativeDelegate (GetCaption_cb);
			iface.GetColumnDescription = new GetColumnDescriptionNativeDelegate (GetColumnDescription_cb);
			iface.GetColumnHeader = new GetColumnHeaderNativeDelegate (GetColumnHeader_cb);
			iface.GetRowDescription = new GetRowDescriptionNativeDelegate (GetRowDescription_cb);
			iface.GetRowHeader = new GetRowHeaderNativeDelegate (GetRowHeader_cb);
			iface.GetSummary = new GetSummaryNativeDelegate (GetSummary_cb);
			iface.SetCaption = new SetCaptionNativeDelegate (SetCaption_cb);
			iface.SetColumnDescription = new SetColumnDescriptionNativeDelegate (SetColumnDescription_cb);
			iface.SetColumnHeader = new SetColumnHeaderNativeDelegate (SetColumnHeader_cb);
			iface.SetRowDescription = new SetRowDescriptionNativeDelegate (SetRowDescription_cb);
			iface.SetRowHeader = new SetRowHeaderNativeDelegate (SetRowHeader_cb);
			iface.SetSummary = new SetSummaryNativeDelegate (SetSummary_cb);
			iface.GetSelectedColumns = new GetSelectedColumnsNativeDelegate (GetSelectedColumns_cb);
			iface.GetSelectedRows = new GetSelectedRowsNativeDelegate (GetSelectedRows_cb);
			iface.IsColumnSelected = new IsColumnSelectedNativeDelegate (IsColumnSelected_cb);
			iface.IsRowSelected = new IsRowSelectedNativeDelegate (IsRowSelected_cb);
			iface.IsSelected = new IsSelectedNativeDelegate (IsSelected_cb);
			iface.AddRowSelection = new AddRowSelectionNativeDelegate (AddRowSelection_cb);
			iface.RemoveRowSelection = new RemoveRowSelectionNativeDelegate (RemoveRowSelection_cb);
			iface.AddColumnSelection = new AddColumnSelectionNativeDelegate (AddColumnSelection_cb);
			iface.RemoveColumnSelection = new RemoveColumnSelectionNativeDelegate (RemoveColumnSelection_cb);
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate IntPtr RefAtNativeDelegate (IntPtr inst, int row, int column);

		static IntPtr RefAt_cb (IntPtr inst, int row, int column)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				Atk.Object __result;
				__result = __obj.RefAt (row, column);
				return __result == null ? IntPtr.Zero : __result.OwnedHandle;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate int GetIndexAtNativeDelegate (IntPtr inst, int row, int column);

		static int GetIndexAt_cb (IntPtr inst, int row, int column)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				int __result;
				__result = __obj.GetIndexAt (row, column);
				return __result;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate int GetColumnAtIndexNativeDelegate (IntPtr inst, int index_);

		static int GetColumnAtIndex_cb (IntPtr inst, int index_)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				int __result;
				__result = __obj.GetColumnAtIndex (index_);
				return __result;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate int GetRowAtIndexNativeDelegate (IntPtr inst, int index_);

		static int GetRowAtIndex_cb (IntPtr inst, int index_)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				int __result;
				__result = __obj.GetRowAtIndex (index_);
				return __result;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate int GetNColumnsNativeDelegate (IntPtr inst);

		static int GetNColumns_cb (IntPtr inst)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				int __result;
				__result = __obj.NColumns;
				return __result;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate int GetNRowsNativeDelegate (IntPtr inst);

		static int GetNRows_cb (IntPtr inst)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				int __result;
				__result = __obj.NRows;
				return __result;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate int GetColumnExtentAtNativeDelegate (IntPtr inst, int row, int column);

		static int GetColumnExtentAt_cb (IntPtr inst, int row, int column)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				int __result;
				__result = __obj.GetColumnExtentAt (row, column);
				return __result;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate int GetRowExtentAtNativeDelegate (IntPtr inst, int row, int column);

		static int GetRowExtentAt_cb (IntPtr inst, int row, int column)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				int __result;
				__result = __obj.GetRowExtentAt (row, column);
				return __result;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate IntPtr GetCaptionNativeDelegate (IntPtr inst);

		static IntPtr GetCaption_cb (IntPtr inst)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				Atk.Object __result;
				__result = __obj.Caption;
				return __result == null ? IntPtr.Zero : __result.Handle;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate IntPtr GetColumnDescriptionNativeDelegate (IntPtr inst, int column);

		static IntPtr GetColumnDescription_cb (IntPtr inst, int column)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				string __result;
				__result = __obj.GetColumnDescription (column);
				return GLib.Marshaller.StringToPtrGStrdup(__result);
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate IntPtr GetColumnHeaderNativeDelegate (IntPtr inst, int column);

		static IntPtr GetColumnHeader_cb (IntPtr inst, int column)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				Atk.Object __result;
				__result = __obj.GetColumnHeader (column);
				return __result == null ? IntPtr.Zero : __result.Handle;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate IntPtr GetRowDescriptionNativeDelegate (IntPtr inst, int row);

		static IntPtr GetRowDescription_cb (IntPtr inst, int row)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				string __result;
				__result = __obj.GetRowDescription (row);
				return GLib.Marshaller.StringToPtrGStrdup(__result);
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate IntPtr GetRowHeaderNativeDelegate (IntPtr inst, int row);

		static IntPtr GetRowHeader_cb (IntPtr inst, int row)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				Atk.Object __result;
				__result = __obj.GetRowHeader (row);
				return __result == null ? IntPtr.Zero : __result.Handle;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate IntPtr GetSummaryNativeDelegate (IntPtr inst);

		static IntPtr GetSummary_cb (IntPtr inst)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				Atk.Object __result;
				__result = __obj.Summary;
				return __result == null ? IntPtr.Zero : __result.Handle;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate void SetCaptionNativeDelegate (IntPtr inst, IntPtr caption);

		static void SetCaption_cb (IntPtr inst, IntPtr caption)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				__obj.Caption = GLib.Object.GetObject(caption) as Atk.Object;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, false);
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate void SetColumnDescriptionNativeDelegate (IntPtr inst, int column, IntPtr description);

		static void SetColumnDescription_cb (IntPtr inst, int column, IntPtr description)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				__obj.SetColumnDescription (column, GLib.Marshaller.Utf8PtrToString (description));
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, false);
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate void SetColumnHeaderNativeDelegate (IntPtr inst, int column, IntPtr header);

		static void SetColumnHeader_cb (IntPtr inst, int column, IntPtr header)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				__obj.SetColumnHeader (column, GLib.Object.GetObject(header) as Atk.Object);
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, false);
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate void SetRowDescriptionNativeDelegate (IntPtr inst, int row, IntPtr description);

		static void SetRowDescription_cb (IntPtr inst, int row, IntPtr description)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				__obj.SetRowDescription (row, GLib.Marshaller.Utf8PtrToString (description));
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, false);
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate void SetRowHeaderNativeDelegate (IntPtr inst, int row, IntPtr header);

		static void SetRowHeader_cb (IntPtr inst, int row, IntPtr header)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				__obj.SetRowHeader (row, GLib.Object.GetObject(header) as Atk.Object);
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, false);
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate void SetSummaryNativeDelegate (IntPtr inst, IntPtr accessible);

		static void SetSummary_cb (IntPtr inst, IntPtr accessible)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				__obj.Summary = GLib.Object.GetObject(accessible) as Atk.Object;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, false);
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate int GetSelectedColumnsNativeDelegate (IntPtr inst, out int selected);

		static int GetSelectedColumns_cb (IntPtr inst, out int selected)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				int __result;
				__result = __obj.GetSelectedColumns (out selected);
				return __result;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate int GetSelectedRowsNativeDelegate (IntPtr inst, out int selected);

		static int GetSelectedRows_cb (IntPtr inst, out int selected)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				int __result;
				__result = __obj.GetSelectedRows (out selected);
				return __result;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate bool IsColumnSelectedNativeDelegate (IntPtr inst, int column);

		static bool IsColumnSelected_cb (IntPtr inst, int column)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				bool __result;
				__result = __obj.IsColumnSelected (column);
				return __result;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate bool IsRowSelectedNativeDelegate (IntPtr inst, int row);

		static bool IsRowSelected_cb (IntPtr inst, int row)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				bool __result;
				__result = __obj.IsRowSelected (row);
				return __result;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate bool IsSelectedNativeDelegate (IntPtr inst, int row, int column);

		static bool IsSelected_cb (IntPtr inst, int row, int column)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				bool __result;
				__result = __obj.IsSelected (row, column);
				return __result;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate bool AddRowSelectionNativeDelegate (IntPtr inst, int row);

		static bool AddRowSelection_cb (IntPtr inst, int row)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				bool __result;
				__result = __obj.AddRowSelection (row);
				return __result;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate bool RemoveRowSelectionNativeDelegate (IntPtr inst, int row);

		static bool RemoveRowSelection_cb (IntPtr inst, int row)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				bool __result;
				__result = __obj.RemoveRowSelection (row);
				return __result;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate bool AddColumnSelectionNativeDelegate (IntPtr inst, int column);

		static bool AddColumnSelection_cb (IntPtr inst, int column)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				bool __result;
				__result = __obj.AddColumnSelection (column);
				return __result;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate bool RemoveColumnSelectionNativeDelegate (IntPtr inst, int column);

		static bool RemoveColumnSelection_cb (IntPtr inst, int column)
		{
			try {
				ITableImplementor __obj = GLib.Object.GetObject (inst, false) as ITableImplementor;
				bool __result;
				__result = __obj.RemoveColumnSelection (column);
				return __result;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		static int class_offset = 2 * IntPtr.Size;

		static void Initialize (IntPtr ptr, IntPtr data)
		{
			IntPtr ifaceptr = new IntPtr (ptr.ToInt64 () + class_offset);
			AtkTableIface native_iface = (AtkTableIface) Marshal.PtrToStructure (ifaceptr, typeof (AtkTableIface));
			native_iface.RefAt = iface.RefAt;
			native_iface.GetIndexAt = iface.GetIndexAt;
			native_iface.GetColumnAtIndex = iface.GetColumnAtIndex;
			native_iface.GetRowAtIndex = iface.GetRowAtIndex;
			native_iface.GetNColumns = iface.GetNColumns;
			native_iface.GetNRows = iface.GetNRows;
			native_iface.GetColumnExtentAt = iface.GetColumnExtentAt;
			native_iface.GetRowExtentAt = iface.GetRowExtentAt;
			native_iface.GetCaption = iface.GetCaption;
			native_iface.GetColumnDescription = iface.GetColumnDescription;
			native_iface.GetColumnHeader = iface.GetColumnHeader;
			native_iface.GetRowDescription = iface.GetRowDescription;
			native_iface.GetRowHeader = iface.GetRowHeader;
			native_iface.GetSummary = iface.GetSummary;
			native_iface.SetCaption = iface.SetCaption;
			native_iface.SetColumnDescription = iface.SetColumnDescription;
			native_iface.SetColumnHeader = iface.SetColumnHeader;
			native_iface.SetRowDescription = iface.SetRowDescription;
			native_iface.SetRowHeader = iface.SetRowHeader;
			native_iface.SetSummary = iface.SetSummary;
			native_iface.GetSelectedColumns = iface.GetSelectedColumns;
			native_iface.GetSelectedRows = iface.GetSelectedRows;
			native_iface.IsColumnSelected = iface.IsColumnSelected;
			native_iface.IsRowSelected = iface.IsRowSelected;
			native_iface.IsSelected = iface.IsSelected;
			native_iface.AddRowSelection = iface.AddRowSelection;
			native_iface.RemoveRowSelection = iface.RemoveRowSelection;
			native_iface.AddColumnSelection = iface.AddColumnSelection;
			native_iface.RemoveColumnSelection = iface.RemoveColumnSelection;
			Marshal.StructureToPtr (native_iface, ifaceptr, false);
		}

		GLib.Object implementor;

		public TableAdapter ()
		{
			InitHandler = new GLib.GInterfaceInitHandler (Initialize);
		}

		public TableAdapter (ITableImplementor implementor)
		{
			if (implementor == null)
				throw new ArgumentNullException ("implementor");
			else if (!(implementor is GLib.Object))
				throw new ArgumentException ("implementor must be a subclass of GLib.Object");
			this.implementor = implementor as GLib.Object;
		}

		public TableAdapter (IntPtr handle)
		{
			if (!_gtype.IsInstance (handle))
				throw new ArgumentException ("The gobject doesn't implement the GInterface of this adapter", "handle");
			implementor = GLib.Object.GetObject (handle);
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern IntPtr atk_table_get_type();

		private static GLib.GType _gtype = new GLib.GType (atk_table_get_type ());

		public static GLib.GType GType {
			get {
				return _gtype;
			}
		}

		public override GLib.GType GInterfaceGType {
			get {
				return _gtype;
			}
		}

		public override IntPtr Handle {
			get {
				return implementor.Handle;
			}
		}

		public IntPtr OwnedHandle {
			get {
				return implementor.OwnedHandle;
			}
		}

		public static ITable GetObject (IntPtr handle, bool owned)
		{
			GLib.Object obj = GLib.Object.GetObject (handle, owned);
			return GetObject (obj);
		}

		public static ITable GetObject (GLib.Object obj)
		{
			if (obj == null)
				return null;
			else if (obj is ITableImplementor)
				return new TableAdapter (obj as ITableImplementor);
			else if (obj as ITable == null)
				return new TableAdapter (obj.Handle);
			else
				return obj as ITable;
		}

		public ITableImplementor Implementor {
			get {
				return implementor as ITableImplementor;
			}
		}

		[GLib.Signal("model_changed")]
		public event System.EventHandler ModelChanged {
			add {
				GLib.Object.GetObject (Handle).AddSignalHandler ("model_changed", value);
			}
			remove {
				GLib.Object.GetObject (Handle).RemoveSignalHandler ("model_changed", value);
			}
		}

		[GLib.Signal("column_reordered")]
		public event System.EventHandler ColumnReordered {
			add {
				GLib.Object.GetObject (Handle).AddSignalHandler ("column_reordered", value);
			}
			remove {
				GLib.Object.GetObject (Handle).RemoveSignalHandler ("column_reordered", value);
			}
		}

		[GLib.Signal("row_inserted")]
		public event Atk.RowInsertedHandler RowInserted {
			add {
				GLib.Object.GetObject (Handle).AddSignalHandler ("row_inserted", value, typeof (Atk.RowInsertedArgs));
			}
			remove {
				GLib.Object.GetObject (Handle).RemoveSignalHandler ("row_inserted", value);
			}
		}

		[GLib.Signal("row_deleted")]
		public event Atk.RowDeletedHandler RowDeleted {
			add {
				GLib.Object.GetObject (Handle).AddSignalHandler ("row_deleted", value, typeof (Atk.RowDeletedArgs));
			}
			remove {
				GLib.Object.GetObject (Handle).RemoveSignalHandler ("row_deleted", value);
			}
		}

		[GLib.Signal("row_reordered")]
		public event System.EventHandler RowReordered {
			add {
				GLib.Object.GetObject (Handle).AddSignalHandler ("row_reordered", value);
			}
			remove {
				GLib.Object.GetObject (Handle).RemoveSignalHandler ("row_reordered", value);
			}
		}

		[GLib.Signal("column_inserted")]
		public event Atk.ColumnInsertedHandler ColumnInserted {
			add {
				GLib.Object.GetObject (Handle).AddSignalHandler ("column_inserted", value, typeof (Atk.ColumnInsertedArgs));
			}
			remove {
				GLib.Object.GetObject (Handle).RemoveSignalHandler ("column_inserted", value);
			}
		}

		[GLib.Signal("column_deleted")]
		public event Atk.ColumnDeletedHandler ColumnDeleted {
			add {
				GLib.Object.GetObject (Handle).AddSignalHandler ("column_deleted", value, typeof (Atk.ColumnDeletedArgs));
			}
			remove {
				GLib.Object.GetObject (Handle).RemoveSignalHandler ("column_deleted", value);
			}
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern bool atk_table_add_column_selection(IntPtr raw, int column);

		public bool AddColumnSelection(int column) {
			bool raw_ret = atk_table_add_column_selection(Handle, column);
			bool ret = raw_ret;
			return ret;
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern bool atk_table_add_row_selection(IntPtr raw, int row);

		public bool AddRowSelection(int row) {
			bool raw_ret = atk_table_add_row_selection(Handle, row);
			bool ret = raw_ret;
			return ret;
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern IntPtr atk_table_get_caption(IntPtr raw);

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern void atk_table_set_caption(IntPtr raw, IntPtr caption);

		public Atk.Object Caption { 
			get {
				IntPtr raw_ret = atk_table_get_caption(Handle);
				Atk.Object ret = GLib.Object.GetObject(raw_ret) as Atk.Object;
				return ret;
			}
			set {
				atk_table_set_caption(Handle, value == null ? IntPtr.Zero : value.Handle);
			}
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern int atk_table_get_column_at_index(IntPtr raw, int index_);

		[Obsolete]
		public int GetColumnAtIndex(int index_) {
			int raw_ret = atk_table_get_column_at_index(Handle, index_);
			int ret = raw_ret;
			return ret;
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern IntPtr atk_table_get_column_description(IntPtr raw, int column);

		public string GetColumnDescription(int column) {
			IntPtr raw_ret = atk_table_get_column_description(Handle, column);
			string ret = GLib.Marshaller.Utf8PtrToString (raw_ret);
			return ret;
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern int atk_table_get_column_extent_at(IntPtr raw, int row, int column);

		public int GetColumnExtentAt(int row, int column) {
			int raw_ret = atk_table_get_column_extent_at(Handle, row, column);
			int ret = raw_ret;
			return ret;
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern IntPtr atk_table_get_column_header(IntPtr raw, int column);

		public Atk.Object GetColumnHeader(int column) {
			IntPtr raw_ret = atk_table_get_column_header(Handle, column);
			Atk.Object ret = GLib.Object.GetObject(raw_ret) as Atk.Object;
			return ret;
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern int atk_table_get_index_at(IntPtr raw, int row, int column);

		[Obsolete]
		public int GetIndexAt(int row, int column) {
			int raw_ret = atk_table_get_index_at(Handle, row, column);
			int ret = raw_ret;
			return ret;
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern int atk_table_get_n_columns(IntPtr raw);

		public int NColumns { 
			get {
				int raw_ret = atk_table_get_n_columns(Handle);
				int ret = raw_ret;
				return ret;
			}
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern int atk_table_get_n_rows(IntPtr raw);

		public int NRows { 
			get {
				int raw_ret = atk_table_get_n_rows(Handle);
				int ret = raw_ret;
				return ret;
			}
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern int atk_table_get_row_at_index(IntPtr raw, int index_);

		[Obsolete]
		public int GetRowAtIndex(int index_) {
			int raw_ret = atk_table_get_row_at_index(Handle, index_);
			int ret = raw_ret;
			return ret;
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern IntPtr atk_table_get_row_description(IntPtr raw, int row);

		public string GetRowDescription(int row) {
			IntPtr raw_ret = atk_table_get_row_description(Handle, row);
			string ret = GLib.Marshaller.Utf8PtrToString (raw_ret);
			return ret;
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern int atk_table_get_row_extent_at(IntPtr raw, int row, int column);

		public int GetRowExtentAt(int row, int column) {
			int raw_ret = atk_table_get_row_extent_at(Handle, row, column);
			int ret = raw_ret;
			return ret;
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern IntPtr atk_table_get_row_header(IntPtr raw, int row);

		public Atk.Object GetRowHeader(int row) {
			IntPtr raw_ret = atk_table_get_row_header(Handle, row);
			Atk.Object ret = GLib.Object.GetObject(raw_ret) as Atk.Object;
			return ret;
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern int atk_table_get_selected_columns(IntPtr raw, out int selected);

		public int GetSelectedColumns(out int selected) {
			int raw_ret = atk_table_get_selected_columns(Handle, out selected);
			int ret = raw_ret;
			return ret;
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern int atk_table_get_selected_rows(IntPtr raw, out int selected);

		public int GetSelectedRows(out int selected) {
			int raw_ret = atk_table_get_selected_rows(Handle, out selected);
			int ret = raw_ret;
			return ret;
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern IntPtr atk_table_get_summary(IntPtr raw);

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern void atk_table_set_summary(IntPtr raw, IntPtr accessible);

		public Atk.Object Summary { 
			get {
				IntPtr raw_ret = atk_table_get_summary(Handle);
				Atk.Object ret = GLib.Object.GetObject(raw_ret) as Atk.Object;
				return ret;
			}
			set {
				atk_table_set_summary(Handle, value == null ? IntPtr.Zero : value.Handle);
			}
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern bool atk_table_is_column_selected(IntPtr raw, int column);

		public bool IsColumnSelected(int column) {
			bool raw_ret = atk_table_is_column_selected(Handle, column);
			bool ret = raw_ret;
			return ret;
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern bool atk_table_is_row_selected(IntPtr raw, int row);

		public bool IsRowSelected(int row) {
			bool raw_ret = atk_table_is_row_selected(Handle, row);
			bool ret = raw_ret;
			return ret;
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern bool atk_table_is_selected(IntPtr raw, int row, int column);

		public bool IsSelected(int row, int column) {
			bool raw_ret = atk_table_is_selected(Handle, row, column);
			bool ret = raw_ret;
			return ret;
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern IntPtr atk_table_ref_at(IntPtr raw, int row, int column);

		public Atk.Object RefAt(int row, int column) {
			IntPtr raw_ret = atk_table_ref_at(Handle, row, column);
			Atk.Object ret = GLib.Object.GetObject(raw_ret, true) as Atk.Object;
			return ret;
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern bool atk_table_remove_column_selection(IntPtr raw, int column);

		public bool RemoveColumnSelection(int column) {
			bool raw_ret = atk_table_remove_column_selection(Handle, column);
			bool ret = raw_ret;
			return ret;
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern bool atk_table_remove_row_selection(IntPtr raw, int row);

		public bool RemoveRowSelection(int row) {
			bool raw_ret = atk_table_remove_row_selection(Handle, row);
			bool ret = raw_ret;
			return ret;
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern void atk_table_set_column_description(IntPtr raw, int column, IntPtr description);

		public void SetColumnDescription(int column, string description) {
			IntPtr native_description = GLib.Marshaller.StringToPtrGStrdup (description);
			atk_table_set_column_description(Handle, column, native_description);
			GLib.Marshaller.Free (native_description);
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern void atk_table_set_column_header(IntPtr raw, int column, IntPtr header);

		public void SetColumnHeader(int column, Atk.Object header) {
			atk_table_set_column_header(Handle, column, header == null ? IntPtr.Zero : header.Handle);
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern void atk_table_set_row_description(IntPtr raw, int row, IntPtr description);

		public void SetRowDescription(int row, string description) {
			IntPtr native_description = GLib.Marshaller.StringToPtrGStrdup (description);
			atk_table_set_row_description(Handle, row, native_description);
			GLib.Marshaller.Free (native_description);
		}

		[DllImport("atk-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern void atk_table_set_row_header(IntPtr raw, int row, IntPtr header);

		public void SetRowHeader(int row, Atk.Object header) {
			atk_table_set_row_header(Handle, row, header == null ? IntPtr.Zero : header.Handle);
		}

#endregion
	}
}