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
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
1926
1927
1928
1929
1930
1931
1932
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
2103
2104
2105
2106
2107
2108
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
2127
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
2144
2145
2146
2147
2148
2149
2150
2151
2152
2153
2154
2155
2156
2157
2158
2159
2160
2161
2162
2163
2164
2165
2166
2167
2168
2169
2170
2171
2172
2173
2174
2175
2176
2177
2178
2179
2180
2181
2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
2199
2200
2201
2202
2203
2204
2205
2206
2207
2208
2209
2210
2211
2212
2213
2214
2215
2216
2217
2218
2219
2220
2221
2222
2223
2224
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
2235
2236
2237
2238
2239
2240
2241
2242
2243
2244
2245
2246
2247
2248
2249
2250
2251
2252
2253
2254
2255
2256
2257
2258
2259
2260
2261
2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
2272
2273
2274
2275
2276
2277
2278
2279
2280
2281
2282
2283
2284
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312
2313
2314
2315
2316
2317
2318
2319
2320
2321
2322
2323
2324
2325
2326
2327
2328
2329
2330
2331
2332
2333
2334
2335
2336
2337
2338
2339
2340
2341
2342
2343
2344
2345
2346
2347
2348
2349
2350
2351
2352
2353
2354
2355
2356
2357
2358
2359
2360
2361
2362
2363
2364
2365
2366
2367
2368
2369
2370
2371
2372
2373
2374
2375
2376
2377
2378
2379
2380
2381
2382
2383
2384
2385
2386
2387
2388
2389
2390
2391
2392
2393
2394
2395
2396
2397
2398
2399
2400
2401
2402
2403
2404
2405
2406
2407
2408
2409
2410
2411
2412
2413
2414
2415
2416
2417
2418
2419
2420
2421
2422
2423
2424
2425
2426
2427
2428
2429
2430
2431
2432
2433
2434
2435
2436
2437
2438
2439
2440
2441
2442
2443
2444
2445
2446
2447
2448
2449
2450
2451
2452
2453
2454
2455
2456
2457
2458
2459
2460
2461
2462
2463
2464
2465
2466
2467
2468
2469
2470
2471
2472
2473
2474
2475
2476
2477
2478
2479
2480
2481
2482
2483
2484
2485
2486
2487
2488
2489
2490
2491
2492
2493
2494
2495
2496
2497
2498
2499
2500
2501
2502
2503
2504
2505
2506
2507
2508
2509
2510
2511
2512
2513
2514
2515
2516
2517
2518
2519
2520
2521
2522
2523
2524
2525
2526
2527
2528
2529
2530
2531
2532
2533
2534
2535
2536
2537
2538
2539
2540
2541
2542
2543
2544
2545
2546
2547
2548
2549
2550
2551
2552
2553
2554
2555
2556
2557
2558
2559
2560
2561
2562
2563
2564
2565
2566
2567
2568
2569
2570
2571
2572
2573
2574
2575
2576
2577
2578
2579
2580
2581
2582
2583
2584
2585
2586
2587
2588
2589
2590
2591
2592
2593
2594
2595
2596
2597
2598
2599
2600
2601
2602
2603
2604
2605
2606
2607
2608
2609
2610
2611
2612
2613
2614
2615
2616
2617
2618
2619
2620
2621
2622
2623
2624
2625
2626
2627
2628
2629
2630
2631
2632
2633
2634
2635
2636
2637
2638
2639
2640
2641
2642
2643
2644
2645
2646
2647
2648
2649
2650
2651
2652
2653
2654
2655
2656
2657
2658
2659
2660
2661
2662
2663
2664
2665
2666
2667
2668
2669
2670
2671
2672
2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
2689
2690
2691
2692
2693
2694
2695
2696
2697
2698
2699
2700
2701
2702
2703
2704
2705
2706
2707
2708
2709
2710
2711
2712
2713
2714
2715
2716
2717
2718
2719
2720
2721
2722
2723
2724
2725
2726
2727
2728
2729
2730
2731
2732
2733
2734
2735
2736
2737
2738
2739
2740
2741
2742
2743
2744
2745
2746
2747
2748
2749
2750
2751
2752
2753
2754
2755
2756
2757
2758
2759
2760
2761
2762
2763
2764
2765
2766
2767
2768
2769
2770
2771
2772
2773
2774
2775
2776
2777
2778
2779
2780
2781
2782
2783
2784
2785
2786
2787
2788
2789
2790
2791
2792
2793
2794
2795
2796
2797
2798
2799
2800
2801
2802
2803
2804
2805
2806
2807
2808
2809
2810
2811
2812
2813
2814
2815
2816
2817
2818
2819
2820
2821
2822
2823
2824
2825
2826
2827
2828
2829
2830
2831
2832
2833
2834
2835
2836
2837
2838
2839
2840
2841
2842
2843
2844
2845
2846
2847
2848
2849
2850
2851
2852
2853
2854
2855
2856
2857
2858
2859
2860
2861
2862
2863
2864
2865
2866
2867
2868
2869
2870
2871
2872
2873
2874
2875
2876
2877
2878
2879
2880
2881
2882
2883
2884
2885
2886
2887
2888
2889
2890
2891
2892
2893
2894
2895
2896
2897
2898
2899
2900
2901
2902
2903
2904
2905
2906
2907
2908
2909
2910
2911
2912
2913
2914
2915
2916
2917
2918
2919
2920
2921
2922
2923
2924
2925
2926
2927
2928
2929
2930
2931
2932
2933
2934
2935
2936
2937
2938
2939
2940
2941
2942
2943
2944
2945
2946
2947
2948
2949
2950
2951
2952
2953
2954
2955
2956
2957
2958
2959
2960
2961
2962
2963
2964
2965
2966
2967
2968
2969
2970
2971
2972
2973
2974
2975
2976
2977
2978
2979
2980
2981
2982
2983
2984
2985
2986
2987
2988
2989
2990
2991
2992
2993
2994
2995
2996
2997
2998
2999
3000
3001
3002
3003
3004
3005
3006
3007
3008
3009
3010
3011
3012
3013
3014
3015
3016
3017
3018
3019
3020
3021
3022
3023
3024
3025
3026
3027
3028
3029
3030
3031
3032
3033
3034
3035
3036
3037
3038
3039
3040
3041
3042
3043
3044
3045
3046
3047
3048
3049
3050
3051
3052
3053
3054
3055
3056
3057
3058
3059
3060
3061
3062
3063
3064
3065
3066
3067
3068
3069
3070
3071
3072
3073
3074
3075
3076
3077
3078
3079
3080
3081
3082
3083
3084
3085
3086
3087
3088
3089
3090
3091
3092
3093
3094
3095
3096
3097
3098
3099
3100
3101
3102
3103
3104
3105
3106
3107
3108
3109
3110
3111
3112
3113
3114
3115
3116
3117
3118
3119
3120
3121
3122
3123
3124
3125
3126
3127
3128
3129
3130
3131
3132
3133
3134
3135
3136
3137
3138
3139
3140
3141
3142
3143
3144
3145
3146
3147
3148
3149
3150
3151
3152
3153
3154
3155
3156
3157
3158
3159
3160
3161
3162
3163
3164
3165
3166
3167
3168
3169
3170
3171
3172
3173
3174
3175
3176
3177
3178
3179
3180
3181
3182
3183
3184
3185
3186
3187
3188
3189
3190
3191
3192
3193
3194
3195
3196
3197
3198
3199
3200
3201
3202
3203
3204
3205
3206
3207
3208
3209
3210
3211
3212
3213
3214
3215
3216
3217
3218
3219
3220
3221
3222
3223
3224
3225
3226
3227
3228
3229
3230
3231
3232
3233
3234
3235
3236
3237
3238
3239
3240
3241
3242
3243
3244
3245
3246
3247
3248
3249
3250
3251
3252
3253
3254
3255
3256
3257
3258
3259
3260
3261
3262
3263
3264
3265
3266
3267
3268
3269
3270
3271
3272
3273
3274
3275
3276
3277
3278
3279
3280
3281
3282
3283
3284
3285
3286
3287
3288
3289
3290
3291
3292
3293
3294
3295
3296
3297
3298
3299
3300
3301
3302
3303
3304
3305
3306
3307
3308
3309
3310
3311
3312
3313
3314
3315
3316
3317
3318
3319
3320
3321
3322
3323
3324
3325
3326
3327
3328
3329
3330
3331
3332
3333
3334
3335
3336
3337
3338
3339
3340
3341
3342
3343
3344
3345
3346
3347
3348
3349
3350
3351
3352
3353
3354
3355
3356
3357
3358
3359
3360
3361
3362
3363
3364
3365
3366
3367
3368
3369
3370
3371
3372
3373
3374
3375
3376
3377
3378
3379
3380
3381
3382
3383
3384
3385
3386
3387
3388
3389
3390
3391
3392
3393
3394
3395
3396
3397
3398
3399
3400
3401
3402
3403
3404
3405
3406
3407
3408
3409
3410
3411
3412
3413
3414
3415
3416
3417
3418
3419
3420
3421
3422
3423
3424
3425
3426
3427
3428
3429
3430
3431
3432
3433
3434
3435
3436
3437
3438
3439
3440
3441
3442
3443
3444
3445
3446
3447
3448
3449
3450
3451
3452
3453
3454
3455
3456
3457
3458
3459
3460
3461
3462
3463
3464
3465
3466
3467
3468
3469
3470
3471
3472
3473
3474
3475
3476
3477
3478
3479
3480
3481
3482
3483
3484
3485
3486
3487
3488
3489
3490
3491
3492
3493
3494
3495
3496
3497
3498
3499
3500
3501
3502
3503
3504
3505
3506
3507
3508
3509
3510
3511
3512
3513
3514
3515
3516
3517
3518
3519
3520
3521
3522
3523
3524
3525
3526
3527
3528
3529
3530
3531
3532
3533
3534
3535
3536
3537
3538
3539
3540
3541
3542
3543
3544
3545
3546
3547
3548
3549
3550
3551
3552
3553
3554
3555
3556
3557
3558
3559
3560
3561
3562
3563
3564
3565
3566
3567
3568
3569
3570
3571
3572
3573
3574
3575
3576
3577
3578
3579
3580
3581
3582
3583
3584
3585
3586
3587
3588
3589
3590
3591
3592
3593
3594
3595
3596
3597
3598
3599
3600
3601
3602
3603
3604
3605
3606
3607
3608
3609
3610
3611
3612
3613
3614
3615
3616
3617
3618
3619
3620
3621
3622
3623
3624
3625
3626
3627
3628
3629
3630
3631
3632
3633
3634
3635
3636
3637
3638
3639
3640
3641
3642
3643
3644
3645
3646
3647
3648
3649
3650
3651
3652
3653
3654
3655
3656
3657
3658
3659
3660
3661
3662
3663
3664
3665
3666
3667
3668
3669
3670
3671
3672
3673
3674
3675
3676
3677
3678
3679
3680
3681
3682
3683
3684
3685
3686
3687
3688
3689
3690
3691
3692
3693
3694
3695
3696
3697
//
// DO NOT EDIT.  THIS FILE IS GENERATED FROM ../../../dist/idl/nsIDocShell.idl
//


/// `interface nsIDocShell : nsIDocShellTreeItem`
///


// The actual type definition for the interface. This struct has methods
// declared on it which will call through its vtable. You never want to pass
// this type around by value, always pass it behind a reference.

#[repr(C)]
pub struct nsIDocShell {
    vtable: *const nsIDocShellVTable,

    /// This field is a phantomdata to ensure that the VTable type and any
    /// struct containing it is not safe to send across threads, as XPCOM is
    /// generally not threadsafe.
    ///
    /// XPCOM interfaces in general are not safe to send across threads.
    __nosync: ::std::marker::PhantomData<::std::rc::Rc<u8>>,
}

// Implementing XpCom for an interface exposes its IID, which allows for easy
// use of the `.query_interface<T>` helper method. This also defines that
// method for nsIDocShell.
unsafe impl XpCom for nsIDocShell {
    const IID: nsIID = nsID(0x049234fe, 0xda10, 0x478b,
        [0xbc, 0x5d, 0xbc, 0x6f, 0x9a, 0x1b, 0xa6, 0x3d]);
}

// We need to implement the RefCounted trait so we can be used with `RefPtr`.
// This trait teaches `RefPtr` how to manage our memory.
unsafe impl RefCounted for nsIDocShell {
    #[inline]
    unsafe fn addref(&self) {
        self.AddRef();
    }
    #[inline]
    unsafe fn release(&self) {
        self.Release();
    }
}

// This trait is implemented on all types which can be coerced to from nsIDocShell.
// It is used in the implementation of `fn coerce<T>`. We hide it from the
// documentation, because it clutters it up a lot.
#[doc(hidden)]
pub trait nsIDocShellCoerce {
    /// Cheaply cast a value of this type from a `nsIDocShell`.
    fn coerce_from(v: &nsIDocShell) -> &Self;
}

// The trivial implementation: We can obviously coerce ourselves to ourselves.
impl nsIDocShellCoerce for nsIDocShell {
    #[inline]
    fn coerce_from(v: &nsIDocShell) -> &Self {
        v
    }
}

impl nsIDocShell {
    /// Cast this `nsIDocShell` to one of its base interfaces.
    #[inline]
    pub fn coerce<T: nsIDocShellCoerce>(&self) -> &T {
        T::coerce_from(self)
    }
}

// Every interface struct type implements `Deref` to its base interface. This
// causes methods on the base interfaces to be directly avaliable on the
// object. For example, you can call `.AddRef` or `.QueryInterface` directly
// on any interface which inherits from `nsISupports`.
impl ::std::ops::Deref for nsIDocShell {
    type Target = nsIDocShellTreeItem;
    #[inline]
    fn deref(&self) -> &nsIDocShellTreeItem {
        unsafe {
            ::std::mem::transmute(self)
        }
    }
}

// Ensure we can use .coerce() to cast to our base types as well. Any type which
// our base interface can coerce from should be coercable from us as well.
impl<T: nsIDocShellTreeItemCoerce> nsIDocShellCoerce for T {
    #[inline]
    fn coerce_from(v: &nsIDocShell) -> &Self {
        T::coerce_from(v)
    }
}

// This struct represents the interface's VTable. A pointer to a statically
// allocated version of this struct is at the beginning of every nsIDocShell
// object. It contains one pointer field for each method in the interface. In
// the case where we can't generate a binding for a method, we include a void
// pointer.
#[doc(hidden)]
#[repr(C)]
pub struct nsIDocShellVTable {
    /// We need to include the members from the base interface's vtable at the start
    /// of the VTable definition.
    pub __base: nsIDocShellTreeItemVTable,

    /* [noscript] void loadURI (in nsIURI uri, in nsIDocShellLoadInfo loadInfo, in unsigned long aLoadFlags, in boolean firstParty); */
    pub LoadURI: unsafe extern "system" fn (this: *const nsIDocShell, uri: *const nsIURI, loadInfo: *const nsIDocShellLoadInfo, aLoadFlags: libc::uint32_t, firstParty: bool) -> nsresult,

    /* [noscript] void loadStream (in nsIInputStream aStream, in nsIURI aURI, in ACString aContentType, in ACString aContentCharset, in nsIDocShellLoadInfo aLoadInfo); */
    pub LoadStream: unsafe extern "system" fn (this: *const nsIDocShell, aStream: *const nsIInputStream, aURI: *const nsIURI, aContentType: &::nsstring::nsACString, aContentCharset: &::nsstring::nsACString, aLoadInfo: *const nsIDocShellLoadInfo) -> nsresult,

    /* [noscript] void internalLoad (in nsIURI aURI, in nsIURI aOriginalURI, [const] in MaybeURI aResultPrincipalURI, in boolean aLoadReplace, in nsIURI aReferrer, in unsigned long aReferrerPolicy, in nsIPrincipal aTriggeringPrincipal, in nsIPrincipal aPrincipalToInherit, in uint32_t aFlags, in AString aWindowTarget, in string aTypeHint, in AString aFileName, in nsIInputStream aPostDataStream, in long long aPostDataStreamLength, in nsIInputStream aHeadersStream, in unsigned long aLoadFlags, in nsISHEntry aSHEntry, in boolean aFirstParty, in AString aSrcdoc, in nsIDocShell aSourceDocShell, in nsIURI aBaseURI, in boolean aCheckForPrerender, out nsIDocShell aDocShell, out nsIRequest aRequest); */
    /// Unable to generate binding because `native type mozilla::Maybe<nsCOMPtr<nsIURI>> is unsupported`
    pub InternalLoad: *const ::libc::c_void,

    /* [implicit_jscontext] void addState (in jsval aData, in DOMString aTitle, in DOMString aURL, in boolean aReplace); */
    /// Unable to generate binding because `native type JS::Value is unsupported`
    pub AddState: *const ::libc::c_void,

    /* void createLoadInfo (out nsIDocShellLoadInfo loadInfo); */
    pub CreateLoadInfo: unsafe extern "system" fn (this: *const nsIDocShell, loadInfo: *mut *const nsIDocShellLoadInfo) -> nsresult,

    /* void prepareForNewContentModel (); */
    pub PrepareForNewContentModel: unsafe extern "system" fn (this: *const nsIDocShell) -> nsresult,

    /* void setCurrentURI (in nsIURI aURI); */
    pub SetCurrentURI: unsafe extern "system" fn (this: *const nsIDocShell, aURI: *const nsIURI) -> nsresult,

    /* [noscript] void firePageHideNotification (in boolean isUnload); */
    pub FirePageHideNotification: unsafe extern "system" fn (this: *const nsIDocShell, isUnload: bool) -> nsresult,

    /* [noscript] readonly attribute nsPresContext presContext; */
    /// Unable to generate binding because `native type nsPresContext is unsupported`
    pub GetPresContext: *const ::libc::c_void,

    /* [noscript,notxpcom] nsIPresShell GetPresShell (); */
    /// Unable to generate binding because `native type nsIPresShell is unsupported`
    pub GetPresShell: *const ::libc::c_void,

    /* [noscript] readonly attribute nsIPresShell eldestPresShell; */
    /// Unable to generate binding because `native type nsIPresShell is unsupported`
    pub GetEldestPresShell: *const ::libc::c_void,

    /* readonly attribute nsIContentViewer contentViewer; */
    pub GetContentViewer: unsafe extern "system" fn (this: *const nsIDocShell, aContentViewer: *mut *const nsIContentViewer) -> nsresult,

    /* attribute nsIDOMEventTarget chromeEventHandler; */
    pub GetChromeEventHandler: unsafe extern "system" fn (this: *const nsIDocShell, aChromeEventHandler: *mut *const nsIDOMEventTarget) -> nsresult,

    /* attribute nsIDOMEventTarget chromeEventHandler; */
    pub SetChromeEventHandler: unsafe extern "system" fn (this: *const nsIDocShell, aChromeEventHandler: *const nsIDOMEventTarget) -> nsresult,

    /* attribute DOMString customUserAgent; */
    pub GetCustomUserAgent: unsafe extern "system" fn (this: *const nsIDocShell, aCustomUserAgent: &mut ::nsstring::nsAString) -> nsresult,

    /* attribute DOMString customUserAgent; */
    pub SetCustomUserAgent: unsafe extern "system" fn (this: *const nsIDocShell, aCustomUserAgent: &::nsstring::nsAString) -> nsresult,

    /* attribute boolean allowPlugins; */
    pub GetAllowPlugins: unsafe extern "system" fn (this: *const nsIDocShell, aAllowPlugins: *mut bool) -> nsresult,

    /* attribute boolean allowPlugins; */
    pub SetAllowPlugins: unsafe extern "system" fn (this: *const nsIDocShell, aAllowPlugins: bool) -> nsresult,

    /* attribute boolean allowJavascript; */
    pub GetAllowJavascript: unsafe extern "system" fn (this: *const nsIDocShell, aAllowJavascript: *mut bool) -> nsresult,

    /* attribute boolean allowJavascript; */
    pub SetAllowJavascript: unsafe extern "system" fn (this: *const nsIDocShell, aAllowJavascript: bool) -> nsresult,

    /* attribute boolean allowMetaRedirects; */
    pub GetAllowMetaRedirects: unsafe extern "system" fn (this: *const nsIDocShell, aAllowMetaRedirects: *mut bool) -> nsresult,

    /* attribute boolean allowMetaRedirects; */
    pub SetAllowMetaRedirects: unsafe extern "system" fn (this: *const nsIDocShell, aAllowMetaRedirects: bool) -> nsresult,

    /* attribute boolean allowSubframes; */
    pub GetAllowSubframes: unsafe extern "system" fn (this: *const nsIDocShell, aAllowSubframes: *mut bool) -> nsresult,

    /* attribute boolean allowSubframes; */
    pub SetAllowSubframes: unsafe extern "system" fn (this: *const nsIDocShell, aAllowSubframes: bool) -> nsresult,

    /* attribute boolean allowImages; */
    pub GetAllowImages: unsafe extern "system" fn (this: *const nsIDocShell, aAllowImages: *mut bool) -> nsresult,

    /* attribute boolean allowImages; */
    pub SetAllowImages: unsafe extern "system" fn (this: *const nsIDocShell, aAllowImages: bool) -> nsresult,

    /* [infallible] attribute boolean allowMedia; */
    pub GetAllowMedia: unsafe extern "system" fn (this: *const nsIDocShell, aAllowMedia: *mut bool) -> nsresult,

    /* [infallible] attribute boolean allowMedia; */
    pub SetAllowMedia: unsafe extern "system" fn (this: *const nsIDocShell, aAllowMedia: bool) -> nsresult,

    /* attribute boolean allowDNSPrefetch; */
    pub GetAllowDNSPrefetch: unsafe extern "system" fn (this: *const nsIDocShell, aAllowDNSPrefetch: *mut bool) -> nsresult,

    /* attribute boolean allowDNSPrefetch; */
    pub SetAllowDNSPrefetch: unsafe extern "system" fn (this: *const nsIDocShell, aAllowDNSPrefetch: bool) -> nsresult,

    /* attribute boolean allowWindowControl; */
    pub GetAllowWindowControl: unsafe extern "system" fn (this: *const nsIDocShell, aAllowWindowControl: *mut bool) -> nsresult,

    /* attribute boolean allowWindowControl; */
    pub SetAllowWindowControl: unsafe extern "system" fn (this: *const nsIDocShell, aAllowWindowControl: bool) -> nsresult,

    /* [infallible] attribute boolean allowContentRetargeting; */
    pub GetAllowContentRetargeting: unsafe extern "system" fn (this: *const nsIDocShell, aAllowContentRetargeting: *mut bool) -> nsresult,

    /* [infallible] attribute boolean allowContentRetargeting; */
    pub SetAllowContentRetargeting: unsafe extern "system" fn (this: *const nsIDocShell, aAllowContentRetargeting: bool) -> nsresult,

    /* [infallible] attribute boolean allowContentRetargetingOnChildren; */
    pub GetAllowContentRetargetingOnChildren: unsafe extern "system" fn (this: *const nsIDocShell, aAllowContentRetargetingOnChildren: *mut bool) -> nsresult,

    /* [infallible] attribute boolean allowContentRetargetingOnChildren; */
    pub SetAllowContentRetargetingOnChildren: unsafe extern "system" fn (this: *const nsIDocShell, aAllowContentRetargetingOnChildren: bool) -> nsresult,

    /* [infallible] attribute boolean inheritPrivateBrowsingId; */
    pub GetInheritPrivateBrowsingId: unsafe extern "system" fn (this: *const nsIDocShell, aInheritPrivateBrowsingId: *mut bool) -> nsresult,

    /* [infallible] attribute boolean inheritPrivateBrowsingId; */
    pub SetInheritPrivateBrowsingId: unsafe extern "system" fn (this: *const nsIDocShell, aInheritPrivateBrowsingId: bool) -> nsresult,

    /* nsISimpleEnumerator getDocShellEnumerator (in long aItemType, in long aDirection); */
    pub GetDocShellEnumerator: unsafe extern "system" fn (this: *const nsIDocShell, aItemType: libc::int32_t, aDirection: libc::int32_t, _retval: *mut *const nsISimpleEnumerator) -> nsresult,

    /* attribute unsigned long appType; */
    pub GetAppType: unsafe extern "system" fn (this: *const nsIDocShell, aAppType: *mut libc::uint32_t) -> nsresult,

    /* attribute unsigned long appType; */
    pub SetAppType: unsafe extern "system" fn (this: *const nsIDocShell, aAppType: libc::uint32_t) -> nsresult,

    /* attribute boolean allowAuth; */
    pub GetAllowAuth: unsafe extern "system" fn (this: *const nsIDocShell, aAllowAuth: *mut bool) -> nsresult,

    /* attribute boolean allowAuth; */
    pub SetAllowAuth: unsafe extern "system" fn (this: *const nsIDocShell, aAllowAuth: bool) -> nsresult,

    /* attribute float zoom; */
    pub GetZoom: unsafe extern "system" fn (this: *const nsIDocShell, aZoom: *mut libc::c_float) -> nsresult,

    /* attribute float zoom; */
    pub SetZoom: unsafe extern "system" fn (this: *const nsIDocShell, aZoom: libc::c_float) -> nsresult,

    /* attribute long marginWidth; */
    pub GetMarginWidth: unsafe extern "system" fn (this: *const nsIDocShell, aMarginWidth: *mut libc::int32_t) -> nsresult,

    /* attribute long marginWidth; */
    pub SetMarginWidth: unsafe extern "system" fn (this: *const nsIDocShell, aMarginWidth: libc::int32_t) -> nsresult,

    /* attribute long marginHeight; */
    pub GetMarginHeight: unsafe extern "system" fn (this: *const nsIDocShell, aMarginHeight: *mut libc::int32_t) -> nsresult,

    /* attribute long marginHeight; */
    pub SetMarginHeight: unsafe extern "system" fn (this: *const nsIDocShell, aMarginHeight: libc::int32_t) -> nsresult,

    /* bool tabToTreeOwner (in boolean forward, in boolean forDocumentNavigation); */
    pub TabToTreeOwner: unsafe extern "system" fn (this: *const nsIDocShell, forward: bool, forDocumentNavigation: bool, _retval: *mut bool) -> nsresult,

    /* readonly attribute unsigned long busyFlags; */
    pub GetBusyFlags: unsafe extern "system" fn (this: *const nsIDocShell, aBusyFlags: *mut libc::uint32_t) -> nsresult,

    /* attribute unsigned long loadType; */
    pub GetLoadType: unsafe extern "system" fn (this: *const nsIDocShell, aLoadType: *mut libc::uint32_t) -> nsresult,

    /* attribute unsigned long loadType; */
    pub SetLoadType: unsafe extern "system" fn (this: *const nsIDocShell, aLoadType: libc::uint32_t) -> nsresult,

    /* attribute nsLoadFlags defaultLoadFlags; */
    pub GetDefaultLoadFlags: unsafe extern "system" fn (this: *const nsIDocShell, aDefaultLoadFlags: *mut nsLoadFlags) -> nsresult,

    /* attribute nsLoadFlags defaultLoadFlags; */
    pub SetDefaultLoadFlags: unsafe extern "system" fn (this: *const nsIDocShell, aDefaultLoadFlags: nsLoadFlags) -> nsresult,

    /* boolean isBeingDestroyed (); */
    pub IsBeingDestroyed: unsafe extern "system" fn (this: *const nsIDocShell, _retval: *mut bool) -> nsresult,

    /* readonly attribute boolean isExecutingOnLoadHandler; */
    pub GetIsExecutingOnLoadHandler: unsafe extern "system" fn (this: *const nsIDocShell, aIsExecutingOnLoadHandler: *mut bool) -> nsresult,

    /* attribute nsILayoutHistoryState layoutHistoryState; */
    pub GetLayoutHistoryState: unsafe extern "system" fn (this: *const nsIDocShell, aLayoutHistoryState: *mut *const nsILayoutHistoryState) -> nsresult,

    /* attribute nsILayoutHistoryState layoutHistoryState; */
    pub SetLayoutHistoryState: unsafe extern "system" fn (this: *const nsIDocShell, aLayoutHistoryState: *const nsILayoutHistoryState) -> nsresult,

    /* readonly attribute boolean shouldSaveLayoutState; */
    pub GetShouldSaveLayoutState: unsafe extern "system" fn (this: *const nsIDocShell, aShouldSaveLayoutState: *mut bool) -> nsresult,

    /* attribute nsISecureBrowserUI securityUI; */
    pub GetSecurityUI: unsafe extern "system" fn (this: *const nsIDocShell, aSecurityUI: *mut *const nsISecureBrowserUI) -> nsresult,

    /* attribute nsISecureBrowserUI securityUI; */
    pub SetSecurityUI: unsafe extern "system" fn (this: *const nsIDocShell, aSecurityUI: *const nsISecureBrowserUI) -> nsresult,

    /* attribute nsILoadURIDelegate loadURIDelegate; */
    pub GetLoadURIDelegate: unsafe extern "system" fn (this: *const nsIDocShell, aLoadURIDelegate: *mut *const nsILoadURIDelegate) -> nsresult,

    /* attribute nsILoadURIDelegate loadURIDelegate; */
    pub SetLoadURIDelegate: unsafe extern "system" fn (this: *const nsIDocShell, aLoadURIDelegate: *const nsILoadURIDelegate) -> nsresult,

    /* void suspendRefreshURIs (); */
    pub SuspendRefreshURIs: unsafe extern "system" fn (this: *const nsIDocShell) -> nsresult,

    /* void resumeRefreshURIs (); */
    pub ResumeRefreshURIs: unsafe extern "system" fn (this: *const nsIDocShell) -> nsresult,

    /* void beginRestore (in nsIContentViewer viewer, in boolean top); */
    pub BeginRestore: unsafe extern "system" fn (this: *const nsIDocShell, viewer: *const nsIContentViewer, top: bool) -> nsresult,

    /* void finishRestore (); */
    pub FinishRestore: unsafe extern "system" fn (this: *const nsIDocShell) -> nsresult,

    /* readonly attribute boolean restoringDocument; */
    pub GetRestoringDocument: unsafe extern "system" fn (this: *const nsIDocShell, aRestoringDocument: *mut bool) -> nsresult,

    /* attribute boolean useErrorPages; */
    pub GetUseErrorPages: unsafe extern "system" fn (this: *const nsIDocShell, aUseErrorPages: *mut bool) -> nsresult,

    /* attribute boolean useErrorPages; */
    pub SetUseErrorPages: unsafe extern "system" fn (this: *const nsIDocShell, aUseErrorPages: bool) -> nsresult,

    /* boolean displayLoadError (in nsresult aError, in nsIURI aURI, in wstring aURL, [optional] in nsIChannel aFailedChannel); */
    pub DisplayLoadError: unsafe extern "system" fn (this: *const nsIDocShell, aError: nsresult, aURI: *const nsIURI, aURL: *const libc::int16_t, aFailedChannel: *const nsIChannel, _retval: *mut bool) -> nsresult,

    /* readonly attribute nsIChannel failedChannel; */
    pub GetFailedChannel: unsafe extern "system" fn (this: *const nsIDocShell, aFailedChannel: *mut *const nsIChannel) -> nsresult,

    /* readonly attribute long previousTransIndex; */
    pub GetPreviousTransIndex: unsafe extern "system" fn (this: *const nsIDocShell, aPreviousTransIndex: *mut libc::int32_t) -> nsresult,

    /* readonly attribute long loadedTransIndex; */
    pub GetLoadedTransIndex: unsafe extern "system" fn (this: *const nsIDocShell, aLoadedTransIndex: *mut libc::int32_t) -> nsresult,

    /* void historyPurged (in long numEntries); */
    pub HistoryPurged: unsafe extern "system" fn (this: *const nsIDocShell, numEntries: libc::int32_t) -> nsresult,

    /* readonly attribute nsIChannel currentDocumentChannel; */
    pub GetCurrentDocumentChannel: unsafe extern "system" fn (this: *const nsIDocShell, aCurrentDocumentChannel: *mut *const nsIChannel) -> nsresult,

    /* [noscript] attribute long childOffset; */
    pub GetChildOffset: unsafe extern "system" fn (this: *const nsIDocShell, aChildOffset: *mut libc::int32_t) -> nsresult,

    /* [noscript] attribute long childOffset; */
    pub SetChildOffset: unsafe extern "system" fn (this: *const nsIDocShell, aChildOffset: libc::int32_t) -> nsresult,

    /* readonly attribute boolean isInUnload; */
    pub GetIsInUnload: unsafe extern "system" fn (this: *const nsIDocShell, aIsInUnload: *mut bool) -> nsresult,

    /* readonly attribute boolean channelIsUnsafe; */
    pub GetChannelIsUnsafe: unsafe extern "system" fn (this: *const nsIDocShell, aChannelIsUnsafe: *mut bool) -> nsresult,

    /* [infallible] readonly attribute boolean hasMixedActiveContentLoaded; */
    pub GetHasMixedActiveContentLoaded: unsafe extern "system" fn (this: *const nsIDocShell, aHasMixedActiveContentLoaded: *mut bool) -> nsresult,

    /* [infallible] readonly attribute boolean hasMixedActiveContentBlocked; */
    pub GetHasMixedActiveContentBlocked: unsafe extern "system" fn (this: *const nsIDocShell, aHasMixedActiveContentBlocked: *mut bool) -> nsresult,

    /* [infallible] readonly attribute boolean hasMixedDisplayContentLoaded; */
    pub GetHasMixedDisplayContentLoaded: unsafe extern "system" fn (this: *const nsIDocShell, aHasMixedDisplayContentLoaded: *mut bool) -> nsresult,

    /* [infallible] readonly attribute boolean hasMixedDisplayContentBlocked; */
    pub GetHasMixedDisplayContentBlocked: unsafe extern "system" fn (this: *const nsIDocShell, aHasMixedDisplayContentBlocked: *mut bool) -> nsresult,

    /* [infallible] readonly attribute boolean hasTrackingContentBlocked; */
    pub GetHasTrackingContentBlocked: unsafe extern "system" fn (this: *const nsIDocShell, aHasTrackingContentBlocked: *mut bool) -> nsresult,

    /* [infallible] readonly attribute boolean hasTrackingContentLoaded; */
    pub GetHasTrackingContentLoaded: unsafe extern "system" fn (this: *const nsIDocShell, aHasTrackingContentLoaded: *mut bool) -> nsresult,

    /* [noscript,notxpcom] void DetachEditorFromWindow (); */
    pub DetachEditorFromWindow: unsafe extern "system" fn (this: *const nsIDocShell) -> libc::c_void,

    /* attribute boolean isOffScreenBrowser; */
    pub GetIsOffScreenBrowser: unsafe extern "system" fn (this: *const nsIDocShell, aIsOffScreenBrowser: *mut bool) -> nsresult,

    /* attribute boolean isOffScreenBrowser; */
    pub SetIsOffScreenBrowser: unsafe extern "system" fn (this: *const nsIDocShell, aIsOffScreenBrowser: bool) -> nsresult,

    /* readonly attribute nsIWebBrowserPrint printPreview; */
    pub GetPrintPreview: unsafe extern "system" fn (this: *const nsIDocShell, aPrintPreview: *mut *const nsIWebBrowserPrint) -> nsresult,

    /* [infallible] readonly attribute boolean canExecuteScripts; */
    pub GetCanExecuteScripts: unsafe extern "system" fn (this: *const nsIDocShell, aCanExecuteScripts: *mut bool) -> nsresult,

    /* attribute boolean isActive; */
    pub GetIsActive: unsafe extern "system" fn (this: *const nsIDocShell, aIsActive: *mut bool) -> nsresult,

    /* attribute boolean isActive; */
    pub SetIsActive: unsafe extern "system" fn (this: *const nsIDocShell, aIsActive: bool) -> nsresult,

    /* [noscript] void SetIsPrerendered (); */
    pub SetIsPrerendered: unsafe extern "system" fn (this: *const nsIDocShell) -> nsresult,

    /* [infallible] readonly attribute boolean isPrerendered; */
    pub GetIsPrerendered: unsafe extern "system" fn (this: *const nsIDocShell, aIsPrerendered: *mut bool) -> nsresult,

    /* readonly attribute nsIDPtr historyID; */
    pub GetHistoryID: unsafe extern "system" fn (this: *const nsIDocShell, aHistoryID: *mut *mut nsID) -> nsresult,

    /* [noscript,notxpcom] nsID HistoryID (); */
    pub HistoryID: unsafe extern "system" fn (this: *const nsIDocShell) -> nsID,

    /* attribute boolean isAppTab; */
    pub GetIsAppTab: unsafe extern "system" fn (this: *const nsIDocShell, aIsAppTab: *mut bool) -> nsresult,

    /* attribute boolean isAppTab; */
    pub SetIsAppTab: unsafe extern "system" fn (this: *const nsIDocShell, aIsAppTab: bool) -> nsresult,

    /* void createAboutBlankContentViewer (in nsIPrincipal aPrincipal); */
    pub CreateAboutBlankContentViewer: unsafe extern "system" fn (this: *const nsIDocShell, aPrincipal: *const nsIPrincipal) -> nsresult,

    /* [noscript] void forceCreateAboutBlankContentViewer (in nsIPrincipal aPrincipal); */
    pub ForceCreateAboutBlankContentViewer: unsafe extern "system" fn (this: *const nsIDocShell, aPrincipal: *const nsIPrincipal) -> nsresult,

    /* attribute ACString charset; */
    pub GetCharset: unsafe extern "system" fn (this: *const nsIDocShell, aCharset: &mut ::nsstring::nsACString) -> nsresult,

    /* attribute ACString charset; */
    pub SetCharset: unsafe extern "system" fn (this: *const nsIDocShell, aCharset: &::nsstring::nsACString) -> nsresult,

    /* void gatherCharsetMenuTelemetry (); */
    pub GatherCharsetMenuTelemetry: unsafe extern "system" fn (this: *const nsIDocShell) -> nsresult,

    /* attribute ACString forcedCharset; */
    pub GetForcedCharset: unsafe extern "system" fn (this: *const nsIDocShell, aForcedCharset: &mut ::nsstring::nsACString) -> nsresult,

    /* attribute ACString forcedCharset; */
    pub SetForcedCharset: unsafe extern "system" fn (this: *const nsIDocShell, aForcedCharset: &::nsstring::nsACString) -> nsresult,

    /* [noscript,nostdcall,notxpcom] void setParentCharset (in Encoding parentCharset, in int32_t parentCharsetSource, in nsIPrincipal parentCharsetPrincipal); */
    /// Unable to generate binding because `native type const mozilla::Encoding* is unsupported`
    pub SetParentCharset: *const ::libc::c_void,

    /* [noscript,nostdcall,notxpcom] void getParentCharset (out Encoding parentCharset, out int32_t parentCharsetSource, out nsIPrincipal parentCharsetPrincipal); */
    /// Unable to generate binding because `native type const mozilla::Encoding* is unsupported`
    pub GetParentCharset: *const ::libc::c_void,

    /* [infallible] attribute boolean recordProfileTimelineMarkers; */
    pub GetRecordProfileTimelineMarkers: unsafe extern "system" fn (this: *const nsIDocShell, aRecordProfileTimelineMarkers: *mut bool) -> nsresult,

    /* [infallible] attribute boolean recordProfileTimelineMarkers; */
    pub SetRecordProfileTimelineMarkers: unsafe extern "system" fn (this: *const nsIDocShell, aRecordProfileTimelineMarkers: bool) -> nsresult,

    /* DOMHighResTimeStamp now (); */
    pub Now: unsafe extern "system" fn (this: *const nsIDocShell, _retval: *mut DOMHighResTimeStamp) -> nsresult,

    /* [implicit_jscontext] jsval popProfileTimelineMarkers (); */
    /// Unable to generate binding because `jscontext is unsupported`
    pub PopProfileTimelineMarkers: *const ::libc::c_void,

    /* void addWeakPrivacyTransitionObserver (in nsIPrivacyTransitionObserver obs); */
    pub AddWeakPrivacyTransitionObserver: unsafe extern "system" fn (this: *const nsIDocShell, obs: *const nsIPrivacyTransitionObserver) -> nsresult,

    /* void addWeakReflowObserver (in nsIReflowObserver obs); */
    pub AddWeakReflowObserver: unsafe extern "system" fn (this: *const nsIDocShell, obs: *const nsIReflowObserver) -> nsresult,

    /* void removeWeakReflowObserver (in nsIReflowObserver obs); */
    pub RemoveWeakReflowObserver: unsafe extern "system" fn (this: *const nsIDocShell, obs: *const nsIReflowObserver) -> nsresult,

    /* [noscript] void notifyReflowObservers (in bool interruptible, in DOMHighResTimeStamp start, in DOMHighResTimeStamp end); */
    pub NotifyReflowObservers: unsafe extern "system" fn (this: *const nsIDocShell, interruptible: bool, start: DOMHighResTimeStamp, end: DOMHighResTimeStamp) -> nsresult,

    /* [noscript] void addWeakScrollObserver (in nsIScrollObserver obs); */
    pub AddWeakScrollObserver: unsafe extern "system" fn (this: *const nsIDocShell, obs: *const nsIScrollObserver) -> nsresult,

    /* [noscript] void removeWeakScrollObserver (in nsIScrollObserver obs); */
    pub RemoveWeakScrollObserver: unsafe extern "system" fn (this: *const nsIDocShell, obs: *const nsIScrollObserver) -> nsresult,

    /* [noscript] void notifyScrollObservers (); */
    pub NotifyScrollObservers: unsafe extern "system" fn (this: *const nsIDocShell) -> nsresult,

    /* [infallible] attribute unsigned long frameType; */
    pub GetFrameType: unsafe extern "system" fn (this: *const nsIDocShell, aFrameType: *mut libc::uint32_t) -> nsresult,

    /* [infallible] attribute unsigned long frameType; */
    pub SetFrameType: unsafe extern "system" fn (this: *const nsIDocShell, aFrameType: libc::uint32_t) -> nsresult,

    /* [infallible] readonly attribute boolean isMozBrowser; */
    pub GetIsMozBrowser: unsafe extern "system" fn (this: *const nsIDocShell, aIsMozBrowser: *mut bool) -> nsresult,

    /* [infallible] readonly attribute boolean isIsolatedMozBrowserElement; */
    pub GetIsIsolatedMozBrowserElement: unsafe extern "system" fn (this: *const nsIDocShell, aIsIsolatedMozBrowserElement: *mut bool) -> nsresult,

    /* [infallible] readonly attribute boolean isInIsolatedMozBrowserElement; */
    pub GetIsInIsolatedMozBrowserElement: unsafe extern "system" fn (this: *const nsIDocShell, aIsInIsolatedMozBrowserElement: *mut bool) -> nsresult,

    /* [infallible] readonly attribute boolean isInMozBrowser; */
    pub GetIsInMozBrowser: unsafe extern "system" fn (this: *const nsIDocShell, aIsInMozBrowser: *mut bool) -> nsresult,

    /* [infallible] readonly attribute boolean isTopLevelContentDocShell; */
    pub GetIsTopLevelContentDocShell: unsafe extern "system" fn (this: *const nsIDocShell, aIsTopLevelContentDocShell: *mut bool) -> nsresult,

    /* nsIDocShell getSameTypeParentIgnoreBrowserBoundaries (); */
    pub GetSameTypeParentIgnoreBrowserBoundaries: unsafe extern "system" fn (this: *const nsIDocShell, _retval: *mut *const nsIDocShell) -> nsresult,

    /* nsIDocShell getSameTypeRootTreeItemIgnoreBrowserBoundaries (); */
    pub GetSameTypeRootTreeItemIgnoreBrowserBoundaries: unsafe extern "system" fn (this: *const nsIDocShell, _retval: *mut *const nsIDocShell) -> nsresult,

    /* readonly attribute bool asyncPanZoomEnabled; */
    pub GetAsyncPanZoomEnabled: unsafe extern "system" fn (this: *const nsIDocShell, aAsyncPanZoomEnabled: *mut bool) -> nsresult,

    /* attribute unsigned long sandboxFlags; */
    pub GetSandboxFlags: unsafe extern "system" fn (this: *const nsIDocShell, aSandboxFlags: *mut libc::uint32_t) -> nsresult,

    /* attribute unsigned long sandboxFlags; */
    pub SetSandboxFlags: unsafe extern "system" fn (this: *const nsIDocShell, aSandboxFlags: libc::uint32_t) -> nsresult,

    /* attribute nsIDocShell onePermittedSandboxedNavigator; */
    pub GetOnePermittedSandboxedNavigator: unsafe extern "system" fn (this: *const nsIDocShell, aOnePermittedSandboxedNavigator: *mut *const nsIDocShell) -> nsresult,

    /* attribute nsIDocShell onePermittedSandboxedNavigator; */
    pub SetOnePermittedSandboxedNavigator: unsafe extern "system" fn (this: *const nsIDocShell, aOnePermittedSandboxedNavigator: *const nsIDocShell) -> nsresult,

    /* [noscript,nostdcall,notxpcom] bool isSandboxedFrom (in nsIDocShell aTargetDocShell); */
    /// Unable to generate binding because `nostdcall is unsupported`
    pub IsSandboxedFrom: *const ::libc::c_void,

    /* attribute nsIChannel mixedContentChannel; */
    pub GetMixedContentChannel: unsafe extern "system" fn (this: *const nsIDocShell, aMixedContentChannel: *mut *const nsIChannel) -> nsresult,

    /* attribute nsIChannel mixedContentChannel; */
    pub SetMixedContentChannel: unsafe extern "system" fn (this: *const nsIDocShell, aMixedContentChannel: *const nsIChannel) -> nsresult,

    /* void GetAllowMixedContentAndConnectionData (out boolean rootHasSecureConnection, out boolean allowMixedContent, out boolean isRootDocShell); */
    pub GetAllowMixedContentAndConnectionData: unsafe extern "system" fn (this: *const nsIDocShell, rootHasSecureConnection: *mut bool, allowMixedContent: *mut bool, isRootDocShell: *mut bool) -> nsresult,

    /* [noscript,notxpcom] bool pluginsAllowedInCurrentDoc (); */
    pub PluginsAllowedInCurrentDoc: unsafe extern "system" fn (this: *const nsIDocShell) -> bool,

    /* [infallible] readonly attribute boolean fullscreenAllowed; */
    pub GetFullscreenAllowed: unsafe extern "system" fn (this: *const nsIDocShell, aFullscreenAllowed: *mut bool) -> nsresult,

    /* void setFullscreenAllowed (in boolean allowed); */
    pub SetFullscreenAllowed: unsafe extern "system" fn (this: *const nsIDocShell, allowed: bool) -> nsresult,

    /* [notxpcom] uint32_t orientationLock (); */
    pub OrientationLock: unsafe extern "system" fn (this: *const nsIDocShell) -> uint32_t,

    /* [notxpcom] void setOrientationLock (in uint32_t orientationLock); */
    pub SetOrientationLock: unsafe extern "system" fn (this: *const nsIDocShell, orientationLock: uint32_t) -> libc::c_void,

    /* [infallible,noscript] attribute boolean affectPrivateSessionLifetime; */
    pub GetAffectPrivateSessionLifetime: unsafe extern "system" fn (this: *const nsIDocShell, aAffectPrivateSessionLifetime: *mut bool) -> nsresult,

    /* [infallible,noscript] attribute boolean affectPrivateSessionLifetime; */
    pub SetAffectPrivateSessionLifetime: unsafe extern "system" fn (this: *const nsIDocShell, aAffectPrivateSessionLifetime: bool) -> nsresult,

    /* [infallible] readonly attribute boolean mayEnableCharacterEncodingMenu; */
    pub GetMayEnableCharacterEncodingMenu: unsafe extern "system" fn (this: *const nsIDocShell, aMayEnableCharacterEncodingMenu: *mut bool) -> nsresult,

    /* attribute nsIEditor editor; */
    pub GetEditor: unsafe extern "system" fn (this: *const nsIDocShell, aEditor: *mut *const nsIEditor) -> nsresult,

    /* attribute nsIEditor editor; */
    pub SetEditor: unsafe extern "system" fn (this: *const nsIDocShell, aEditor: *const nsIEditor) -> nsresult,

    /* readonly attribute boolean editable; */
    pub GetEditable: unsafe extern "system" fn (this: *const nsIDocShell, aEditable: *mut bool) -> nsresult,

    /* readonly attribute boolean hasEditingSession; */
    pub GetHasEditingSession: unsafe extern "system" fn (this: *const nsIDocShell, aHasEditingSession: *mut bool) -> nsresult,

    /* void makeEditable (in boolean inWaitForUriLoad); */
    pub MakeEditable: unsafe extern "system" fn (this: *const nsIDocShell, inWaitForUriLoad: bool) -> nsresult,

    /* nsISHEntry getChildSHEntry (in long aChildOffset); */
    pub GetChildSHEntry: unsafe extern "system" fn (this: *const nsIDocShell, aChildOffset: libc::int32_t, _retval: *mut *const nsISHEntry) -> nsresult,

    /* void addChildSHEntry (in nsISHEntry aCloneReference, in nsISHEntry aHistoryEntry, in long aChildOffset, in unsigned long aLoadType, in boolean aCloneChilden); */
    pub AddChildSHEntry: unsafe extern "system" fn (this: *const nsIDocShell, aCloneReference: *const nsISHEntry, aHistoryEntry: *const nsISHEntry, aChildOffset: libc::int32_t, aLoadType: libc::uint32_t, aCloneChilden: bool) -> nsresult,

    /* attribute boolean useGlobalHistory; */
    pub GetUseGlobalHistory: unsafe extern "system" fn (this: *const nsIDocShell, aUseGlobalHistory: *mut bool) -> nsresult,

    /* attribute boolean useGlobalHistory; */
    pub SetUseGlobalHistory: unsafe extern "system" fn (this: *const nsIDocShell, aUseGlobalHistory: bool) -> nsresult,

    /* void removeFromSessionHistory (); */
    pub RemoveFromSessionHistory: unsafe extern "system" fn (this: *const nsIDocShell) -> nsresult,

    /* attribute boolean createdDynamically; */
    pub GetCreatedDynamically: unsafe extern "system" fn (this: *const nsIDocShell, aCreatedDynamically: *mut bool) -> nsresult,

    /* attribute boolean createdDynamically; */
    pub SetCreatedDynamically: unsafe extern "system" fn (this: *const nsIDocShell, aCreatedDynamically: bool) -> nsresult,

    /* boolean getCurrentSHEntry (out nsISHEntry aEntry); */
    pub GetCurrentSHEntry: unsafe extern "system" fn (this: *const nsIDocShell, aEntry: *mut *const nsISHEntry, _retval: *mut bool) -> nsresult,

    /* boolean isCommandEnabled (in string command); */
    pub IsCommandEnabled: unsafe extern "system" fn (this: *const nsIDocShell, command: *const libc::c_char, _retval: *mut bool) -> nsresult,

    /* void doCommand (in string command); */
    pub DoCommand: unsafe extern "system" fn (this: *const nsIDocShell, command: *const libc::c_char) -> nsresult,

    /* void doCommandWithParams (in string command, in nsICommandParams aParams); */
    pub DoCommandWithParams: unsafe extern "system" fn (this: *const nsIDocShell, command: *const libc::c_char, aParams: *const nsICommandParams) -> nsresult,

    /* [noscript,notxpcom] bool IsInvisible (); */
    pub IsInvisible: unsafe extern "system" fn (this: *const nsIDocShell) -> bool,

    /* [noscript,notxpcom] void SetInvisible (in bool aIsInvisibleDochsell); */
    pub SetInvisible: unsafe extern "system" fn (this: *const nsIDocShell, aIsInvisibleDochsell: bool) -> libc::c_void,

    /* [noscript,nostdcall,notxpcom] nsIScriptGlobalObject GetScriptGlobalObject (); */
    /// Unable to generate binding because `nostdcall is unsupported`
    pub GetScriptGlobalObject: *const ::libc::c_void,

    /* [infallible] attribute boolean deviceSizeIsPageSize; */
    pub GetDeviceSizeIsPageSize: unsafe extern "system" fn (this: *const nsIDocShell, aDeviceSizeIsPageSize: *mut bool) -> nsresult,

    /* [infallible] attribute boolean deviceSizeIsPageSize; */
    pub SetDeviceSizeIsPageSize: unsafe extern "system" fn (this: *const nsIDocShell, aDeviceSizeIsPageSize: bool) -> nsresult,

    /* [noscript,nostdcall,notxpcom] void setOpener (in nsITabParent aOpener); */
    /// Unable to generate binding because `nostdcall is unsupported`
    pub SetOpener: *const ::libc::c_void,

    /* [noscript,nostdcall,notxpcom] nsITabParent getOpener (); */
    /// Unable to generate binding because `nostdcall is unsupported`
    pub GetOpener: *const ::libc::c_void,

    /* [noscript,nostdcall,notxpcom] void notifyJSRunToCompletionStart (in string aReason, in wstring functionName, in wstring fileName, in unsigned long lineNumber, in jsval asyncStack, in string asyncCause); */
    /// Unable to generate binding because `native type JS::Value is unsupported`
    pub NotifyJSRunToCompletionStart: *const ::libc::c_void,

    /* [noscript,nostdcall,notxpcom] void notifyJSRunToCompletionStop (); */
    /// Unable to generate binding because `nostdcall is unsupported`
    pub NotifyJSRunToCompletionStop: *const ::libc::c_void,

    /* [infallible] readonly attribute boolean hasLoadedNonBlankURI; */
    pub GetHasLoadedNonBlankURI: unsafe extern "system" fn (this: *const nsIDocShell, aHasLoadedNonBlankURI: *mut bool) -> nsresult,

    /* attribute boolean windowDraggingAllowed; */
    pub GetWindowDraggingAllowed: unsafe extern "system" fn (this: *const nsIDocShell, aWindowDraggingAllowed: *mut bool) -> nsresult,

    /* attribute boolean windowDraggingAllowed; */
    pub SetWindowDraggingAllowed: unsafe extern "system" fn (this: *const nsIDocShell, aWindowDraggingAllowed: bool) -> nsresult,

    /* attribute boolean currentScrollRestorationIsManual; */
    pub GetCurrentScrollRestorationIsManual: unsafe extern "system" fn (this: *const nsIDocShell, aCurrentScrollRestorationIsManual: *mut bool) -> nsresult,

    /* attribute boolean currentScrollRestorationIsManual; */
    pub SetCurrentScrollRestorationIsManual: unsafe extern "system" fn (this: *const nsIDocShell, aCurrentScrollRestorationIsManual: bool) -> nsresult,

    /* [implicit_jscontext] jsval getOriginAttributes (); */
    /// Unable to generate binding because `jscontext is unsupported`
    pub GetOriginAttributes: *const ::libc::c_void,

    /* [implicit_jscontext] void setOriginAttributes (in jsval aAttrs); */
    /// Unable to generate binding because `native type JS::Value is unsupported`
    pub SetOriginAttributes: *const ::libc::c_void,

    /* readonly attribute nsIEditingSession editingSession; */
    pub GetEditingSession: unsafe extern "system" fn (this: *const nsIDocShell, aEditingSession: *mut *const nsIEditingSession) -> nsresult,

    /* [binaryname(ScriptableTabChild)] readonly attribute nsITabChild tabChild; */
    pub GetScriptableTabChild: unsafe extern "system" fn (this: *const nsIDocShell, aTabChild: *mut *const nsITabChild) -> nsresult,

    /* [noscript,nostdcall,notxpcom] TabChildRef GetTabChild (); */
    /// Unable to generate binding because `nostdcall is unsupported`
    pub GetTabChild: *const ::libc::c_void,

    /* [noscript,nostdcall,notxpcom] nsICommandManager GetCommandManager (); */
    /// Unable to generate binding because `nostdcall is unsupported`
    pub GetCommandManager: *const ::libc::c_void,

    /* attribute unsigned long touchEventsOverride; */
    pub GetTouchEventsOverride: unsafe extern "system" fn (this: *const nsIDocShell, aTouchEventsOverride: *mut libc::uint32_t) -> nsresult,

    /* attribute unsigned long touchEventsOverride; */
    pub SetTouchEventsOverride: unsafe extern "system" fn (this: *const nsIDocShell, aTouchEventsOverride: libc::uint32_t) -> nsresult,

    /* [infallible] readonly attribute boolean isOnlyToplevelInTabGroup; */
    pub GetIsOnlyToplevelInTabGroup: unsafe extern "system" fn (this: *const nsIDocShell, aIsOnlyToplevelInTabGroup: *mut bool) -> nsresult,

    /* [infallible] readonly attribute boolean awaitingLargeAlloc; */
    pub GetAwaitingLargeAlloc: unsafe extern "system" fn (this: *const nsIDocShell, aAwaitingLargeAlloc: *mut bool) -> nsresult,

    /* attribute boolean useTrackingProtection; */
    pub GetUseTrackingProtection: unsafe extern "system" fn (this: *const nsIDocShell, aUseTrackingProtection: *mut bool) -> nsresult,

    /* attribute boolean useTrackingProtection; */
    pub SetUseTrackingProtection: unsafe extern "system" fn (this: *const nsIDocShell, aUseTrackingProtection: bool) -> nsresult,

    /* [noscript] void dispatchLocationChangeEvent (); */
    pub DispatchLocationChangeEvent: unsafe extern "system" fn (this: *const nsIDocShell) -> nsresult,

    /* [noscript,nostdcall,notxpcom] UniqueClientSource TakeInitialClientSource (); */
    /// Unable to generate binding because `nostdcall is unsupported`
    pub TakeInitialClientSource: *const ::libc::c_void,

    /* attribute unsigned long displayMode; */
    pub GetDisplayMode: unsafe extern "system" fn (this: *const nsIDocShell, aDisplayMode: *mut libc::uint32_t) -> nsresult,

    /* attribute unsigned long displayMode; */
    pub SetDisplayMode: unsafe extern "system" fn (this: *const nsIDocShell, aDisplayMode: libc::uint32_t) -> nsresult,
}


// The implementations of the function wrappers which are exposed to rust code.
// Call these methods rather than manually calling through the VTable struct.
impl nsIDocShell {

    pub const INTERNAL_LOAD_FLAGS_NONE: i64 = 0;


    pub const INTERNAL_LOAD_FLAGS_INHERIT_PRINCIPAL: i64 = 1;


    pub const INTERNAL_LOAD_FLAGS_DONT_SEND_REFERRER: i64 = 2;


    pub const INTERNAL_LOAD_FLAGS_ALLOW_THIRD_PARTY_FIXUP: i64 = 4;


    pub const INTERNAL_LOAD_FLAGS_FIRST_LOAD: i64 = 8;


    pub const INTERNAL_LOAD_FLAGS_BYPASS_CLASSIFIER: i64 = 16;


    pub const INTERNAL_LOAD_FLAGS_FORCE_ALLOW_COOKIES: i64 = 32;


    pub const INTERNAL_LOAD_FLAGS_IS_SRCDOC: i64 = 64;


    pub const INTERNAL_LOAD_FLAGS_NO_OPENER: i64 = 256;


    pub const INTERNAL_LOAD_FLAGS_FORCE_ALLOW_DATA_URI: i64 = 512;

    /// ```text
    /// /**
    ///    * Get an enumerator over this docShell and its children.
    ///    *
    ///    * @param aItemType  - Only include docShells of this type, or if typeAll,
    ///    *                     include all child shells.
    ///    *                     Uses types from nsIDocShellTreeItem.
    ///    * @param aDirection - Whether to enumerate forwards or backwards.
    ///    */
    /// ```
    ///

    pub const ENUMERATE_FORWARDS: i64 = 0;


    pub const ENUMERATE_BACKWARDS: i64 = 1;

    /// ```text
    /// /**
    ///    * The type of application that created this window
    ///    */
    /// ```
    ///

    pub const APP_TYPE_UNKNOWN: i64 = 0;


    pub const APP_TYPE_MAIL: i64 = 1;


    pub const APP_TYPE_EDITOR: i64 = 2;

    /// ```text
    /// /**
    ///    * Current busy state for DocShell
    ///    */
    /// ```
    ///

    pub const BUSY_FLAGS_NONE: i64 = 0;


    pub const BUSY_FLAGS_BUSY: i64 = 1;


    pub const BUSY_FLAGS_BEFORE_PAGE_LOAD: i64 = 2;


    pub const BUSY_FLAGS_PAGE_LOADING: i64 = 4;

    /// ```text
    /// /**
    ///    * Load commands for the document
    ///    */
    /// ```
    ///

    pub const LOAD_CMD_NORMAL: i64 = 1;


    pub const LOAD_CMD_RELOAD: i64 = 2;


    pub const LOAD_CMD_HISTORY: i64 = 4;


    pub const LOAD_CMD_PUSHSTATE: i64 = 8;

    /// ```text
    /// /**
    ///    * The type of iframe that this docshell lives.
    ///    */
    /// ```
    ///

    pub const FRAME_TYPE_REGULAR: i64 = 0;


    pub const FRAME_TYPE_BROWSER: i64 = 1;

    /// ```text
    /// /**
    ///    * Override platform/pref default behaviour and force-disable touch events.
    ///    */
    /// ```
    ///

    pub const TOUCHEVENTS_OVERRIDE_DISABLED: i64 = 0;

    /// ```text
    /// /**
    ///    * Override platform/pref default behaviour and force-enable touch events.
    ///    */
    /// ```
    ///

    pub const TOUCHEVENTS_OVERRIDE_ENABLED: i64 = 1;

    /// ```text
    /// /**
    ///    * Don't override the platform/pref default behaviour for touch events.
    ///    */
    /// ```
    ///

    pub const TOUCHEVENTS_OVERRIDE_NONE: i64 = 2;

    /// ```text
    /// /**
    ///    * Allowed CSS display modes. This needs to be kept in
    ///    * sync with similar values in nsStyleConsts.h
    ///    */
    /// ```
    ///

    pub const DISPLAY_MODE_BROWSER: i64 = 0;


    pub const DISPLAY_MODE_MINIMAL_UI: i64 = 1;


    pub const DISPLAY_MODE_STANDALONE: i64 = 2;


    pub const DISPLAY_MODE_FULLSCREEN: i64 = 3;

    /// ```text
    /// /**
    ///    * Loads a given URI.  This will give priority to loading the requested URI
    ///    * in the object implementing this interface.  If it can't be loaded here
    ///    * however, the URL dispatcher will go through its normal process of content
    ///    * loading.
    ///    *
    ///    * @param uri        - The URI to load.
    ///    * @param loadInfo   - This is the extended load info for this load.  This
    ///    *                     most often will be null, but if you need to do
    ///    *                     additional setup for this load you can get a loadInfo
    ///    *                     object by calling createLoadInfo.  Once you have this
    ///    *                     object you can set the needed properties on it and
    ///    *                     then pass it to loadURI.
    ///    * @param aLoadFlags - Flags to modify load behaviour. Flags are defined in
    ///    *                     nsIWebNavigation.  Note that using flags outside
    ///    *                     LOAD_FLAGS_MASK is only allowed if passing in a
    ///    *                     non-null loadInfo.  And even some of those might not
    ///    *                     be allowed.  Use at your own risk.
    ///    */
    /// ```
    ///

    /// `[noscript] void loadURI (in nsIURI uri, in nsIDocShellLoadInfo loadInfo, in unsigned long aLoadFlags, in boolean firstParty);`
    #[inline]
    pub unsafe fn LoadURI(&self, uri: *const nsIURI, loadInfo: *const nsIDocShellLoadInfo, aLoadFlags: libc::uint32_t, firstParty: bool) -> nsresult {
        ((*self.vtable).LoadURI)(self, uri, loadInfo, aLoadFlags, firstParty)
    }


    /// ```text
    /// /**
    ///    * Loads a given stream. This will give priority to loading the requested
    ///    * stream in the object implementing this interface. If it can't be loaded
    ///    * here however, the URL dispatched will go through its normal process of
    ///    * content loading.
    ///    *
    ///    * @param aStream         - The input stream that provides access to the data
    ///    *                          to be loaded.  This must be a blocking, threadsafe
    ///    *                          stream implementation.
    ///    * @param aURI            - The URI representing the stream, or null.
    ///    * @param aContentType    - The type (MIME) of data being loaded (empty if unknown).
    ///    * @param aContentCharset - The charset of the data being loaded (empty if unknown).
    ///    * @param aLoadInfo       - This is the extended load info for this load.  This
    ///    *                          most often will be null, but if you need to do
    ///    *                          additional setup for this load you can get a
    ///    *                          loadInfo object by calling createLoadInfo.  Once
    ///    *                          you have this object you can set the needed
    ///    *                          properties on it and then pass it to loadStream.
    ///    */
    /// ```
    ///

    /// `[noscript] void loadStream (in nsIInputStream aStream, in nsIURI aURI, in ACString aContentType, in ACString aContentCharset, in nsIDocShellLoadInfo aLoadInfo);`
    #[inline]
    pub unsafe fn LoadStream(&self, aStream: *const nsIInputStream, aURI: *const nsIURI, aContentType: &::nsstring::nsACString, aContentCharset: &::nsstring::nsACString, aLoadInfo: *const nsIDocShellLoadInfo) -> nsresult {
        ((*self.vtable).LoadStream)(self, aStream, aURI, aContentType, aContentCharset, aLoadInfo)
    }


    /// ```text
    /// /**
    ///    * Loads the given URI.  This method is identical to loadURI(...) except
    ///    * that its parameter list is broken out instead of being packaged inside
    ///    * of an nsIDocShellLoadInfo object...
    ///    *
    ///    * @param aURI                 - The URI to load.
    ///    * @param aOriginalURI         - The URI to set as the originalURI on the channel
    ///    *                               that does the load. If null, aURI will be set as
    ///    *                               the originalURI.
    ///    * @param aResultPrincipalURI  - The URI to be set to loadInfo.resultPrincipalURI
    ///    *                               When Nothing, there will be no change
    ///    *                               When Some, the principal URI will overwrite even
    ///    *                               with a null value.
    ///    * @param aLoadReplace         - If set LOAD_REPLACE flag will be set on the
    ///    *                               channel. aOriginalURI is null, this argument is
    ///    *                               ignored.
    ///    * @param aReferrer            - Referring URI
    ///    * @param aReferrerPolicy      - Referrer policy
    ///    * @param aTriggeringPrincipal - A non-null principal that initiated that load.
    ///    *                               Please note that this is the principal that is
    ///    *                               used for security checks. If the argument aURI
    ///    *                               is provided by the web, then please do not pass
    ///    *                               a SystemPrincipal as the triggeringPrincipal.
    ///    * @param aPrincipalToInherit  - Principal to be inherited for that load. If this
    ///    *                               argument is null then principalToInherit is
    ///    *                               computed as follows:
    ///    *                               a) If INTERNAL_LOAD_FLAGS_INHERIT_PRINCIPAL, and
///    *                                  aLoadType is not LOAD_NORMAL_EXTERNAL, and the
///    *                                  URI would normally inherit a principal, then
///    *                                  principalToInherit is set to the current
///    *                                  document's principal, or parent document if
///    *                                  there is not a current document.
///    *                               b) If principalToInherit is still null (e.g. if
///    *                                  some of the conditions of (a) were not satisfied),
///    *                                  then no inheritance of any sort will happen: the
///    *                                  load will just get a principal based on the URI
///    *                                  being loaded.
///    * @param aFlags               - Any of the load flags defined within above.
///    * @param aStopActiveDoc       - Flag indicating whether loading the current
///    *                               document should be stopped.
///    * @param aWindowTarget        - Window target for the load.
///    * @param aTypeHint            - A hint as to the content-type of the resulting
///    *                               data.  May be null or empty if no hint.
///    * @param aFileName            - Non-null when the link should be downloaded as
///                                    the given filename.
///    * @param aPostDataStream      - Post data stream (if POSTing)
///    * @param aPostDataStreamLength - Post data stream length. Use -1 if the length
///                                     of the stream is unknown.
///    * @param aHeadersStream       - Stream containing "extra" request headers...
///    * @param aLoadFlags           - Flags to modify load behaviour. Flags are defined
///    *                               in nsIWebNavigation.
///    * @param aSHEntry             - Active Session History entry (if loading from SH)
///    * @param aSrcdoc                When INTERNAL_LOAD_FLAGS_IS_SRCDOC is set, the
///    *                               contents of this parameter will be loaded instead
///    *                               of aURI.
///    * @param aSourceDocShell      - The source browsing context for the navigation.
///    * @param aBaseURI             - The base URI to be used for the load.  Set in
///    *                               srcdoc loads as it cannot otherwise be inferred
///    *                               in certain situations such as view-source.
///    */
/// ```
///

/// `[noscript] void internalLoad (in nsIURI aURI, in nsIURI aOriginalURI, [const] in MaybeURI aResultPrincipalURI, in boolean aLoadReplace, in nsIURI aReferrer, in unsigned long aReferrerPolicy, in nsIPrincipal aTriggeringPrincipal, in nsIPrincipal aPrincipalToInherit, in uint32_t aFlags, in AString aWindowTarget, in string aTypeHint, in AString aFileName, in nsIInputStream aPostDataStream, in long long aPostDataStreamLength, in nsIInputStream aHeadersStream, in unsigned long aLoadFlags, in nsISHEntry aSHEntry, in boolean aFirstParty, in AString aSrcdoc, in nsIDocShell aSourceDocShell, in nsIURI aBaseURI, in boolean aCheckForPrerender, out nsIDocShell aDocShell, out nsIRequest aRequest);`
const _InternalLoad: () = ();

/// ```text
/// /**
///    * Do either a history.pushState() or history.replaceState() operation,
///    * depending on the value of aReplace.
///    */
/// ```
///

/// `[implicit_jscontext] void addState (in jsval aData, in DOMString aTitle, in DOMString aURL, in boolean aReplace);`
const _AddState: () = ();

/// ```text
/// /**
///    * Creates a DocShellLoadInfo object that you can manipulate and then pass
///    * to loadURI.
///    */
/// ```
///

/// `void createLoadInfo (out nsIDocShellLoadInfo loadInfo);`
#[inline]
pub unsafe fn CreateLoadInfo(&self, loadInfo: *mut *const nsIDocShellLoadInfo) -> nsresult {
((*self.vtable).CreateLoadInfo)(self, loadInfo)
}


/// ```text
/// /**
///    * Reset state to a new content model within the current document and the document
///    * viewer.  Called by the document before initiating an out of band document.write().
///    */
/// ```
///

/// `void prepareForNewContentModel ();`
#[inline]
pub unsafe fn PrepareForNewContentModel(&self, ) -> nsresult {
((*self.vtable).PrepareForNewContentModel)(self, )
}


/// ```text
/// /**
///    * For editors and suchlike who wish to change the URI associated with the
///    * document. Note if you want to get the current URI, use the read-only
///    * property on nsIWebNavigation.
///    */
/// ```
///

/// `void setCurrentURI (in nsIURI aURI);`
#[inline]
pub unsafe fn SetCurrentURI(&self, aURI: *const nsIURI) -> nsresult {
((*self.vtable).SetCurrentURI)(self, aURI)
}


/// ```text
/// /**
///    * Notify the associated content viewer and all child docshells that they are
///    * about to be hidden.  If |isUnload| is true, then the document is being
///    * unloaded and all dynamic subframe history entries are removed as well.
///    *
///    * @param isUnload
///    *        True to fire the unload event in addition to the pagehide event,
///    *        and remove all dynamic subframe history entries.
///    */
/// ```
///

/// `[noscript] void firePageHideNotification (in boolean isUnload);`
#[inline]
pub unsafe fn FirePageHideNotification(&self, isUnload: bool) -> nsresult {
((*self.vtable).FirePageHideNotification)(self, isUnload)
}


/// ```text
/// /**
///    * Presentation context for the currently loaded document.  This may be null.
///    */
/// ```
///

/// `[noscript] readonly attribute nsPresContext presContext;`
const _GetPresContext: () = ();

/// ```text
/// /**
///    * Presentation shell for the currently loaded document.  This may be null.
///    */
/// ```
///

/// `[noscript,notxpcom] nsIPresShell GetPresShell ();`
const _GetPresShell: () = ();

/// ```text
/// /**
///    * Presentation shell for the oldest document, if this docshell is
///    * currently transitioning between documents.
///    */
/// ```
///

/// `[noscript] readonly attribute nsIPresShell eldestPresShell;`
const _GetEldestPresShell: () = ();

/// ```text
/// /**
///    * Content Viewer that is currently loaded for this DocShell.  This may
///    * change as the underlying content changes.
///    */
/// ```
///

/// `readonly attribute nsIContentViewer contentViewer;`
#[inline]
pub unsafe fn GetContentViewer(&self, aContentViewer: *mut *const nsIContentViewer) -> nsresult {
((*self.vtable).GetContentViewer)(self, aContentViewer)
}


/// ```text
/// /**
///    * This attribute allows chrome to tie in to handle DOM events that may
///    * be of interest to chrome.
///    */
/// ```
///

/// `attribute nsIDOMEventTarget chromeEventHandler;`
#[inline]
pub unsafe fn GetChromeEventHandler(&self, aChromeEventHandler: *mut *const nsIDOMEventTarget) -> nsresult {
((*self.vtable).GetChromeEventHandler)(self, aChromeEventHandler)
}


/// ```text
/// /**
///    * This attribute allows chrome to tie in to handle DOM events that may
///    * be of interest to chrome.
///    */
/// ```
///

/// `attribute nsIDOMEventTarget chromeEventHandler;`
#[inline]
pub unsafe fn SetChromeEventHandler(&self, aChromeEventHandler: *const nsIDOMEventTarget) -> nsresult {
((*self.vtable).SetChromeEventHandler)(self, aChromeEventHandler)
}


/// ```text
/// /**
///     * This allows chrome to set a custom User agent on a specific docshell
///     */
/// ```
///

/// `attribute DOMString customUserAgent;`
#[inline]
pub unsafe fn GetCustomUserAgent(&self, aCustomUserAgent: &mut ::nsstring::nsAString) -> nsresult {
((*self.vtable).GetCustomUserAgent)(self, aCustomUserAgent)
}


/// ```text
/// /**
///     * This allows chrome to set a custom User agent on a specific docshell
///     */
/// ```
///

/// `attribute DOMString customUserAgent;`
#[inline]
pub unsafe fn SetCustomUserAgent(&self, aCustomUserAgent: &::nsstring::nsAString) -> nsresult {
((*self.vtable).SetCustomUserAgent)(self, aCustomUserAgent)
}


/// ```text
/// /**
///    * Whether to allow plugin execution
///    */
/// ```
///

/// `attribute boolean allowPlugins;`
#[inline]
pub unsafe fn GetAllowPlugins(&self, aAllowPlugins: *mut bool) -> nsresult {
((*self.vtable).GetAllowPlugins)(self, aAllowPlugins)
}


/// ```text
/// /**
///    * Whether to allow plugin execution
///    */
/// ```
///

/// `attribute boolean allowPlugins;`
#[inline]
pub unsafe fn SetAllowPlugins(&self, aAllowPlugins: bool) -> nsresult {
((*self.vtable).SetAllowPlugins)(self, aAllowPlugins)
}


/// ```text
/// /**
///    * Whether to allow Javascript execution
///    */
/// ```
///

/// `attribute boolean allowJavascript;`
#[inline]
pub unsafe fn GetAllowJavascript(&self, aAllowJavascript: *mut bool) -> nsresult {
((*self.vtable).GetAllowJavascript)(self, aAllowJavascript)
}


/// ```text
/// /**
///    * Whether to allow Javascript execution
///    */
/// ```
///

/// `attribute boolean allowJavascript;`
#[inline]
pub unsafe fn SetAllowJavascript(&self, aAllowJavascript: bool) -> nsresult {
((*self.vtable).SetAllowJavascript)(self, aAllowJavascript)
}


/// ```text
/// /**
///    * Attribute stating if refresh based redirects can be allowed
///    */
/// ```
///

/// `attribute boolean allowMetaRedirects;`
#[inline]
pub unsafe fn GetAllowMetaRedirects(&self, aAllowMetaRedirects: *mut bool) -> nsresult {
((*self.vtable).GetAllowMetaRedirects)(self, aAllowMetaRedirects)
}


/// ```text
/// /**
///    * Attribute stating if refresh based redirects can be allowed
///    */
/// ```
///

/// `attribute boolean allowMetaRedirects;`
#[inline]
pub unsafe fn SetAllowMetaRedirects(&self, aAllowMetaRedirects: bool) -> nsresult {
((*self.vtable).SetAllowMetaRedirects)(self, aAllowMetaRedirects)
}


/// ```text
/// /**
///    * Attribute stating if it should allow subframes (framesets/iframes) or not
///    */
/// ```
///

/// `attribute boolean allowSubframes;`
#[inline]
pub unsafe fn GetAllowSubframes(&self, aAllowSubframes: *mut bool) -> nsresult {
((*self.vtable).GetAllowSubframes)(self, aAllowSubframes)
}


/// ```text
/// /**
///    * Attribute stating if it should allow subframes (framesets/iframes) or not
///    */
/// ```
///

/// `attribute boolean allowSubframes;`
#[inline]
pub unsafe fn SetAllowSubframes(&self, aAllowSubframes: bool) -> nsresult {
((*self.vtable).SetAllowSubframes)(self, aAllowSubframes)
}


/// ```text
/// /**
///    * Attribute stating whether or not images should be loaded.
///    */
/// ```
///

/// `attribute boolean allowImages;`
#[inline]
pub unsafe fn GetAllowImages(&self, aAllowImages: *mut bool) -> nsresult {
((*self.vtable).GetAllowImages)(self, aAllowImages)
}


/// ```text
/// /**
///    * Attribute stating whether or not images should be loaded.
///    */
/// ```
///

/// `attribute boolean allowImages;`
#[inline]
pub unsafe fn SetAllowImages(&self, aAllowImages: bool) -> nsresult {
((*self.vtable).SetAllowImages)(self, aAllowImages)
}


/// ```text
/// /**
///    * Attribute stating whether or not media (audio/video) should be loaded.
///    */
/// ```
///

/// `[infallible] attribute boolean allowMedia;`
#[inline]
pub unsafe fn GetAllowMedia(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetAllowMedia)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * Attribute stating whether or not media (audio/video) should be loaded.
///    */
/// ```
///

/// `[infallible] attribute boolean allowMedia;`
#[inline]
pub unsafe fn SetAllowMedia(&self, aAllowMedia: bool) -> nsresult {
((*self.vtable).SetAllowMedia)(self, aAllowMedia)
}


/// ```text
/// /**
///    * Attribute that determines whether DNS prefetch is allowed for this subtree
///    * of the docshell tree.  Defaults to true.  Setting this will make it take
///    * effect starting with the next document loaded in the docshell.
///    */
/// ```
///

/// `attribute boolean allowDNSPrefetch;`
#[inline]
pub unsafe fn GetAllowDNSPrefetch(&self, aAllowDNSPrefetch: *mut bool) -> nsresult {
((*self.vtable).GetAllowDNSPrefetch)(self, aAllowDNSPrefetch)
}


/// ```text
/// /**
///    * Attribute that determines whether DNS prefetch is allowed for this subtree
///    * of the docshell tree.  Defaults to true.  Setting this will make it take
///    * effect starting with the next document loaded in the docshell.
///    */
/// ```
///

/// `attribute boolean allowDNSPrefetch;`
#[inline]
pub unsafe fn SetAllowDNSPrefetch(&self, aAllowDNSPrefetch: bool) -> nsresult {
((*self.vtable).SetAllowDNSPrefetch)(self, aAllowDNSPrefetch)
}


/// ```text
/// /**
///    * Attribute that determines whether window control (move/resize) is allowed.
///    */
/// ```
///

/// `attribute boolean allowWindowControl;`
#[inline]
pub unsafe fn GetAllowWindowControl(&self, aAllowWindowControl: *mut bool) -> nsresult {
((*self.vtable).GetAllowWindowControl)(self, aAllowWindowControl)
}


/// ```text
/// /**
///    * Attribute that determines whether window control (move/resize) is allowed.
///    */
/// ```
///

/// `attribute boolean allowWindowControl;`
#[inline]
pub unsafe fn SetAllowWindowControl(&self, aAllowWindowControl: bool) -> nsresult {
((*self.vtable).SetAllowWindowControl)(self, aAllowWindowControl)
}


/// ```text
/// /**
///    * True if the docshell allows its content to be handled by a content listener
///    * other than the docshell itself, including the external helper app service,
///    * and false otherwise.  Defaults to true.
///    */
/// ```
///

/// `[infallible] attribute boolean allowContentRetargeting;`
#[inline]
pub unsafe fn GetAllowContentRetargeting(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetAllowContentRetargeting)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * True if the docshell allows its content to be handled by a content listener
///    * other than the docshell itself, including the external helper app service,
///    * and false otherwise.  Defaults to true.
///    */
/// ```
///

/// `[infallible] attribute boolean allowContentRetargeting;`
#[inline]
pub unsafe fn SetAllowContentRetargeting(&self, aAllowContentRetargeting: bool) -> nsresult {
((*self.vtable).SetAllowContentRetargeting)(self, aAllowContentRetargeting)
}


/// ```text
/// /**
///    * True if new child docshells should allow content retargeting.
///    * Setting allowContentRetargeting also overwrites this value.
///    */
/// ```
///

/// `[infallible] attribute boolean allowContentRetargetingOnChildren;`
#[inline]
pub unsafe fn GetAllowContentRetargetingOnChildren(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetAllowContentRetargetingOnChildren)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * True if new child docshells should allow content retargeting.
///    * Setting allowContentRetargeting also overwrites this value.
///    */
/// ```
///

/// `[infallible] attribute boolean allowContentRetargetingOnChildren;`
#[inline]
pub unsafe fn SetAllowContentRetargetingOnChildren(&self, aAllowContentRetargetingOnChildren: bool) -> nsresult {
((*self.vtable).SetAllowContentRetargetingOnChildren)(self, aAllowContentRetargetingOnChildren)
}


/// ```text
/// /**
///    * True if this docShell should inherit the private browsing ID from
///    * its parent when reparented.
///    *
///    * NOTE: This should *not* be set false in new code, or for docShells
///    * inserted anywhere other than as children of panels.
///    */
/// ```
///

/// `[infallible] attribute boolean inheritPrivateBrowsingId;`
#[inline]
pub unsafe fn GetInheritPrivateBrowsingId(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetInheritPrivateBrowsingId)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * True if this docShell should inherit the private browsing ID from
///    * its parent when reparented.
///    *
///    * NOTE: This should *not* be set false in new code, or for docShells
///    * inserted anywhere other than as children of panels.
///    */
/// ```
///

/// `[infallible] attribute boolean inheritPrivateBrowsingId;`
#[inline]
pub unsafe fn SetInheritPrivateBrowsingId(&self, aInheritPrivateBrowsingId: bool) -> nsresult {
((*self.vtable).SetInheritPrivateBrowsingId)(self, aInheritPrivateBrowsingId)
}



/// `nsISimpleEnumerator getDocShellEnumerator (in long aItemType, in long aDirection);`
#[inline]
pub unsafe fn GetDocShellEnumerator(&self, aItemType: libc::int32_t, aDirection: libc::int32_t, _retval: *mut *const nsISimpleEnumerator) -> nsresult {
((*self.vtable).GetDocShellEnumerator)(self, aItemType, aDirection, _retval)
}



/// `attribute unsigned long appType;`
#[inline]
pub unsafe fn GetAppType(&self, aAppType: *mut libc::uint32_t) -> nsresult {
((*self.vtable).GetAppType)(self, aAppType)
}



/// `attribute unsigned long appType;`
#[inline]
pub unsafe fn SetAppType(&self, aAppType: libc::uint32_t) -> nsresult {
((*self.vtable).SetAppType)(self, aAppType)
}


/// ```text
/// /**
///    * certain dochshells (like the message pane)
///    * should not throw up auth dialogs
///    * because it can act as a password trojan
///    */
/// ```
///

/// `attribute boolean allowAuth;`
#[inline]
pub unsafe fn GetAllowAuth(&self, aAllowAuth: *mut bool) -> nsresult {
((*self.vtable).GetAllowAuth)(self, aAllowAuth)
}


/// ```text
/// /**
///    * certain dochshells (like the message pane)
///    * should not throw up auth dialogs
///    * because it can act as a password trojan
///    */
/// ```
///

/// `attribute boolean allowAuth;`
#[inline]
pub unsafe fn SetAllowAuth(&self, aAllowAuth: bool) -> nsresult {
((*self.vtable).SetAllowAuth)(self, aAllowAuth)
}


/// ```text
/// /**
///    * Set/Get the document scale factor.  When setting this attribute, a
///    * NS_ERROR_NOT_IMPLEMENTED error may be returned by implementations
///    * not supporting zoom.  Implementations not supporting zoom should return
///    * 1.0 all the time for the Get operation.  1.0 by the way is the default
///    * of zoom.  This means 100% of normal scaling or in other words normal size
///    * no zoom.
///    */
/// ```
///

/// `attribute float zoom;`
#[inline]
pub unsafe fn GetZoom(&self, aZoom: *mut libc::c_float) -> nsresult {
((*self.vtable).GetZoom)(self, aZoom)
}


/// ```text
/// /**
///    * Set/Get the document scale factor.  When setting this attribute, a
///    * NS_ERROR_NOT_IMPLEMENTED error may be returned by implementations
///    * not supporting zoom.  Implementations not supporting zoom should return
///    * 1.0 all the time for the Get operation.  1.0 by the way is the default
///    * of zoom.  This means 100% of normal scaling or in other words normal size
///    * no zoom.
///    */
/// ```
///

/// `attribute float zoom;`
#[inline]
pub unsafe fn SetZoom(&self, aZoom: libc::c_float) -> nsresult {
((*self.vtable).SetZoom)(self, aZoom)
}



/// `attribute long marginWidth;`
#[inline]
pub unsafe fn GetMarginWidth(&self, aMarginWidth: *mut libc::int32_t) -> nsresult {
((*self.vtable).GetMarginWidth)(self, aMarginWidth)
}



/// `attribute long marginWidth;`
#[inline]
pub unsafe fn SetMarginWidth(&self, aMarginWidth: libc::int32_t) -> nsresult {
((*self.vtable).SetMarginWidth)(self, aMarginWidth)
}



/// `attribute long marginHeight;`
#[inline]
pub unsafe fn GetMarginHeight(&self, aMarginHeight: *mut libc::int32_t) -> nsresult {
((*self.vtable).GetMarginHeight)(self, aMarginHeight)
}



/// `attribute long marginHeight;`
#[inline]
pub unsafe fn SetMarginHeight(&self, aMarginHeight: libc::int32_t) -> nsresult {
((*self.vtable).SetMarginHeight)(self, aMarginHeight)
}



/// `bool tabToTreeOwner (in boolean forward, in boolean forDocumentNavigation);`
#[inline]
pub unsafe fn TabToTreeOwner(&self, forward: bool, forDocumentNavigation: bool, _retval: *mut bool) -> nsresult {
((*self.vtable).TabToTreeOwner)(self, forward, forDocumentNavigation, _retval)
}



/// `readonly attribute unsigned long busyFlags;`
#[inline]
pub unsafe fn GetBusyFlags(&self, aBusyFlags: *mut libc::uint32_t) -> nsresult {
((*self.vtable).GetBusyFlags)(self, aBusyFlags)
}



/// `attribute unsigned long loadType;`
#[inline]
pub unsafe fn GetLoadType(&self, aLoadType: *mut libc::uint32_t) -> nsresult {
((*self.vtable).GetLoadType)(self, aLoadType)
}



/// `attribute unsigned long loadType;`
#[inline]
pub unsafe fn SetLoadType(&self, aLoadType: libc::uint32_t) -> nsresult {
((*self.vtable).SetLoadType)(self, aLoadType)
}



/// `attribute nsLoadFlags defaultLoadFlags;`
#[inline]
pub unsafe fn GetDefaultLoadFlags(&self, aDefaultLoadFlags: *mut nsLoadFlags) -> nsresult {
((*self.vtable).GetDefaultLoadFlags)(self, aDefaultLoadFlags)
}



/// `attribute nsLoadFlags defaultLoadFlags;`
#[inline]
pub unsafe fn SetDefaultLoadFlags(&self, aDefaultLoadFlags: nsLoadFlags) -> nsresult {
((*self.vtable).SetDefaultLoadFlags)(self, aDefaultLoadFlags)
}



/// `boolean isBeingDestroyed ();`
#[inline]
pub unsafe fn IsBeingDestroyed(&self, _retval: *mut bool) -> nsresult {
((*self.vtable).IsBeingDestroyed)(self, _retval)
}



/// `readonly attribute boolean isExecutingOnLoadHandler;`
#[inline]
pub unsafe fn GetIsExecutingOnLoadHandler(&self, aIsExecutingOnLoadHandler: *mut bool) -> nsresult {
((*self.vtable).GetIsExecutingOnLoadHandler)(self, aIsExecutingOnLoadHandler)
}



/// `attribute nsILayoutHistoryState layoutHistoryState;`
#[inline]
pub unsafe fn GetLayoutHistoryState(&self, aLayoutHistoryState: *mut *const nsILayoutHistoryState) -> nsresult {
((*self.vtable).GetLayoutHistoryState)(self, aLayoutHistoryState)
}



/// `attribute nsILayoutHistoryState layoutHistoryState;`
#[inline]
pub unsafe fn SetLayoutHistoryState(&self, aLayoutHistoryState: *const nsILayoutHistoryState) -> nsresult {
((*self.vtable).SetLayoutHistoryState)(self, aLayoutHistoryState)
}



/// `readonly attribute boolean shouldSaveLayoutState;`
#[inline]
pub unsafe fn GetShouldSaveLayoutState(&self, aShouldSaveLayoutState: *mut bool) -> nsresult {
((*self.vtable).GetShouldSaveLayoutState)(self, aShouldSaveLayoutState)
}


/// ```text
/// /**
///    * The SecureBrowserUI object for this docshell.  This is set by XUL
///    * <browser> or nsWebBrowser for their root docshell.
///    */
/// ```
///

/// `attribute nsISecureBrowserUI securityUI;`
#[inline]
pub unsafe fn GetSecurityUI(&self, aSecurityUI: *mut *const nsISecureBrowserUI) -> nsresult {
((*self.vtable).GetSecurityUI)(self, aSecurityUI)
}


/// ```text
/// /**
///    * The SecureBrowserUI object for this docshell.  This is set by XUL
///    * <browser> or nsWebBrowser for their root docshell.
///    */
/// ```
///

/// `attribute nsISecureBrowserUI securityUI;`
#[inline]
pub unsafe fn SetSecurityUI(&self, aSecurityUI: *const nsISecureBrowserUI) -> nsresult {
((*self.vtable).SetSecurityUI)(self, aSecurityUI)
}


/// ```text
/// /**
///    * Object used to delegate URI loading to an upper context.
///    * Currently only set for GeckoView to allow handling of load requests
///    * at the application level.
///    */
/// ```
///

/// `attribute nsILoadURIDelegate loadURIDelegate;`
#[inline]
pub unsafe fn GetLoadURIDelegate(&self, aLoadURIDelegate: *mut *const nsILoadURIDelegate) -> nsresult {
((*self.vtable).GetLoadURIDelegate)(self, aLoadURIDelegate)
}


/// ```text
/// /**
///    * Object used to delegate URI loading to an upper context.
///    * Currently only set for GeckoView to allow handling of load requests
///    * at the application level.
///    */
/// ```
///

/// `attribute nsILoadURIDelegate loadURIDelegate;`
#[inline]
pub unsafe fn SetLoadURIDelegate(&self, aLoadURIDelegate: *const nsILoadURIDelegate) -> nsresult {
((*self.vtable).SetLoadURIDelegate)(self, aLoadURIDelegate)
}


/// ```text
/// /**
///    * Cancel the XPCOM timers for each meta-refresh URI in this docshell,
///    * and this docshell's children, recursively. The meta-refresh timers can be
///    * restarted using resumeRefreshURIs().  If the timers are already suspended,
///    * this has no effect.
///    */
/// ```
///

/// `void suspendRefreshURIs ();`
#[inline]
pub unsafe fn SuspendRefreshURIs(&self, ) -> nsresult {
((*self.vtable).SuspendRefreshURIs)(self, )
}


/// ```text
/// /**
///    * Restart the XPCOM timers for each meta-refresh URI in this docshell,
///    * and this docshell's children, recursively.  If the timers are already
///    * running, this has no effect.
///    */
/// ```
///

/// `void resumeRefreshURIs ();`
#[inline]
pub unsafe fn ResumeRefreshURIs(&self, ) -> nsresult {
((*self.vtable).ResumeRefreshURIs)(self, )
}


/// ```text
/// /**
///    * Begin firing WebProgressListener notifications for restoring a page
///    * presentation. |viewer| is the content viewer whose document we are
///    * starting to load.  If null, it defaults to the docshell's current content
///    * viewer, creating one if necessary.  |top| should be true for the toplevel
///    * docshell that is being restored; it will be set to false when this method
///    * is called for child docshells.  This method will post an event to
///    * complete the simulated load after returning to the event loop.
///    */
/// ```
///

/// `void beginRestore (in nsIContentViewer viewer, in boolean top);`
#[inline]
pub unsafe fn BeginRestore(&self, viewer: *const nsIContentViewer, top: bool) -> nsresult {
((*self.vtable).BeginRestore)(self, viewer, top)
}


/// ```text
/// /**
///    * Finish firing WebProgressListener notifications and DOM events for
///    * restoring a page presentation.  This should only be called via
///    * beginRestore().
///    */
/// ```
///

/// `void finishRestore ();`
#[inline]
pub unsafe fn FinishRestore(&self, ) -> nsresult {
((*self.vtable).FinishRestore)(self, )
}



/// `readonly attribute boolean restoringDocument;`
#[inline]
pub unsafe fn GetRestoringDocument(&self, aRestoringDocument: *mut bool) -> nsresult {
((*self.vtable).GetRestoringDocument)(self, aRestoringDocument)
}



/// `attribute boolean useErrorPages;`
#[inline]
pub unsafe fn GetUseErrorPages(&self, aUseErrorPages: *mut bool) -> nsresult {
((*self.vtable).GetUseErrorPages)(self, aUseErrorPages)
}



/// `attribute boolean useErrorPages;`
#[inline]
pub unsafe fn SetUseErrorPages(&self, aUseErrorPages: bool) -> nsresult {
((*self.vtable).SetUseErrorPages)(self, aUseErrorPages)
}


/// ```text
/// /**
///    * Display a load error in a frame while keeping that frame's currentURI
///    * pointing correctly to the page where the error ocurred, rather than to
///    * the error document page. You must provide either the aURI or aURL parameter.
///    *
///    * @param  aError         The error code to be displayed
///    * @param  aURI           nsIURI of the page where the error happened
///    * @param  aURL           wstring of the page where the error happened
///    * @param  aFailedChannel The channel related to this error
///    *
///    * Returns whether or not we displayed an error page (note: will always
///    * return false if in-content error pages are disabled!)
///    */
/// ```
///

/// `boolean displayLoadError (in nsresult aError, in nsIURI aURI, in wstring aURL, [optional] in nsIChannel aFailedChannel);`
#[inline]
pub unsafe fn DisplayLoadError(&self, aError: nsresult, aURI: *const nsIURI, aURL: *const libc::int16_t, aFailedChannel: *const nsIChannel, _retval: *mut bool) -> nsresult {
((*self.vtable).DisplayLoadError)(self, aError, aURI, aURL, aFailedChannel, _retval)
}


/// ```text
/// /**
///    * The channel that failed to load and resulted in an error page.
///    * May be null. Relevant only to error pages.
///    */
/// ```
///

/// `readonly attribute nsIChannel failedChannel;`
#[inline]
pub unsafe fn GetFailedChannel(&self, aFailedChannel: *mut *const nsIChannel) -> nsresult {
((*self.vtable).GetFailedChannel)(self, aFailedChannel)
}


/// ```text
/// /**
///    * Keeps track of the previous SHTransaction index and the current
///    * SHTransaction index at the time that the doc shell begins to load.
///    * Used for ContentViewer eviction.
///    */
/// ```
///

/// `readonly attribute long previousTransIndex;`
#[inline]
pub unsafe fn GetPreviousTransIndex(&self, aPreviousTransIndex: *mut libc::int32_t) -> nsresult {
((*self.vtable).GetPreviousTransIndex)(self, aPreviousTransIndex)
}



/// `readonly attribute long loadedTransIndex;`
#[inline]
pub unsafe fn GetLoadedTransIndex(&self, aLoadedTransIndex: *mut libc::int32_t) -> nsresult {
((*self.vtable).GetLoadedTransIndex)(self, aLoadedTransIndex)
}


/// ```text
/// /**
///    * Notification that entries have been removed from the beginning of a
///    * nsSHistory which has this as its rootDocShell.
///    *
///    * @param numEntries - The number of entries removed
///    */
/// ```
///

/// `void historyPurged (in long numEntries);`
#[inline]
pub unsafe fn HistoryPurged(&self, numEntries: libc::int32_t) -> nsresult {
((*self.vtable).HistoryPurged)(self, numEntries)
}


/// ```text
/// /**
///    * Gets the channel for the currently loaded document, if any.
///    * For a new document load, this will be the channel of the previous document
///    * until after OnLocationChange fires.
///    */
/// ```
///

/// `readonly attribute nsIChannel currentDocumentChannel;`
#[inline]
pub unsafe fn GetCurrentDocumentChannel(&self, aCurrentDocumentChannel: *mut *const nsIChannel) -> nsresult {
((*self.vtable).GetCurrentDocumentChannel)(self, aCurrentDocumentChannel)
}


/// ```text
/// /**
///    * The original offset of this child in its container. This property is -1 for
///    * dynamically added docShells.
///    */
/// ```
///

/// `[noscript] attribute long childOffset;`
#[inline]
pub unsafe fn GetChildOffset(&self, aChildOffset: *mut libc::int32_t) -> nsresult {
((*self.vtable).GetChildOffset)(self, aChildOffset)
}


/// ```text
/// /**
///    * The original offset of this child in its container. This property is -1 for
///    * dynamically added docShells.
///    */
/// ```
///

/// `[noscript] attribute long childOffset;`
#[inline]
pub unsafe fn SetChildOffset(&self, aChildOffset: libc::int32_t) -> nsresult {
((*self.vtable).SetChildOffset)(self, aChildOffset)
}


/// ```text
/// /**
///    * Find out whether the docshell is currently in the middle of a page
///    * transition. This is set just before the pagehide/unload events fire.
///    */
/// ```
///

/// `readonly attribute boolean isInUnload;`
#[inline]
pub unsafe fn GetIsInUnload(&self, aIsInUnload: *mut bool) -> nsresult {
((*self.vtable).GetIsInUnload)(self, aIsInUnload)
}


/// ```text
/// /**
///    * Find out if the currently loaded document came from a suspicious channel
///    * (such as a JAR channel where the server-returned content type isn't a
///    * known JAR type).
///    */
/// ```
///

/// `readonly attribute boolean channelIsUnsafe;`
#[inline]
pub unsafe fn GetChannelIsUnsafe(&self, aChannelIsUnsafe: *mut bool) -> nsresult {
((*self.vtable).GetChannelIsUnsafe)(self, aChannelIsUnsafe)
}


/// ```text
/// /**
///    * This attribute determines whether Mixed Active Content is loaded on the
///    * document. When it is true, mixed active content was not blocked and has
///    * loaded (or is about to load) on the page. When it is false, mixed active content
///    * has not loaded on the page, either because there was no mixed active content
///    * requests on the page or such requests were blocked by nsMixedContentBlocker.
///    * This boolean is set to true in nsMixedContentBlocker if Mixed Active Content
///    * is allowed (either explicitly on the page by the user or when the about:config
///    * setting security.mixed_content.block_active_content is set to false).
///    */
/// ```
///

/// `[infallible] readonly attribute boolean hasMixedActiveContentLoaded;`
#[inline]
pub unsafe fn GetHasMixedActiveContentLoaded(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetHasMixedActiveContentLoaded)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * This attribute determines whether a document has Mixed Active Content
///    * that has been blocked from loading. When it is true, there is definitely
///    * mixed active content on a page that has been blocked by
///    * nsMixedContentBlocker.  When it is false, there may or may not be mixed
///    * active content on a page, but if there is, it will load. Note that if the
///    * about:config setting security.mixed_content.block_active_content is set
///    * false, this boolean will be false, since blocking active content has been
///    * disabled.
///    */
/// ```
///

/// `[infallible] readonly attribute boolean hasMixedActiveContentBlocked;`
#[inline]
pub unsafe fn GetHasMixedActiveContentBlocked(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetHasMixedActiveContentBlocked)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * This attribute determines whether Mixed Display Content is loaded on the
///    * document. When it is true, mixed display content was not blocked and has
///    * loaded (or is about to load) on the page. Similar behavior to
///    * hasMixedActiveContentLoaded.
///    */
/// ```
///

/// `[infallible] readonly attribute boolean hasMixedDisplayContentLoaded;`
#[inline]
pub unsafe fn GetHasMixedDisplayContentLoaded(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetHasMixedDisplayContentLoaded)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * This attribute determines whether a document has Mixed Display Content
///    * that has been blocked from loading. Similar behavior to
///    * hasMixedActiveContentBlocked.
///    */
/// ```
///

/// `[infallible] readonly attribute boolean hasMixedDisplayContentBlocked;`
#[inline]
pub unsafe fn GetHasMixedDisplayContentBlocked(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetHasMixedDisplayContentBlocked)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * This attribute determines whether a document has Tracking Content
///    * that has been blocked from loading.
///    */
/// ```
///

/// `[infallible] readonly attribute boolean hasTrackingContentBlocked;`
#[inline]
pub unsafe fn GetHasTrackingContentBlocked(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetHasTrackingContentBlocked)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * This attribute determines whether Tracking Content is loaded on the
///    * document. When it is true, tracking content was not blocked and has
///    * loaded (or is about to load) on the page.
///    */
/// ```
///

/// `[infallible] readonly attribute boolean hasTrackingContentLoaded;`
#[inline]
pub unsafe fn GetHasTrackingContentLoaded(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetHasTrackingContentLoaded)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * Disconnects this docshell's editor from its window, and stores the
///    * editor data in the open document's session history entry.  This
///    * should be called only during page transitions.
///    */
/// ```
///

/// `[noscript,notxpcom] void DetachEditorFromWindow ();`
#[inline]
pub unsafe fn DetachEditorFromWindow(&self, ) -> libc::c_void {
((*self.vtable).DetachEditorFromWindow)(self, )
}


/// ```text
/// /**
///    * If true, this browser is not visible in the traditional sense, but
///    * is actively being rendered to the screen (ex. painted on a canvas)
///    * and should be treated accordingly.
///    **/
/// ```
///

/// `attribute boolean isOffScreenBrowser;`
#[inline]
pub unsafe fn GetIsOffScreenBrowser(&self, aIsOffScreenBrowser: *mut bool) -> nsresult {
((*self.vtable).GetIsOffScreenBrowser)(self, aIsOffScreenBrowser)
}


/// ```text
/// /**
///    * If true, this browser is not visible in the traditional sense, but
///    * is actively being rendered to the screen (ex. painted on a canvas)
///    * and should be treated accordingly.
///    **/
/// ```
///

/// `attribute boolean isOffScreenBrowser;`
#[inline]
pub unsafe fn SetIsOffScreenBrowser(&self, aIsOffScreenBrowser: bool) -> nsresult {
((*self.vtable).SetIsOffScreenBrowser)(self, aIsOffScreenBrowser)
}


/// ```text
/// /**
///    * If the current content viewer isn't initialized for print preview,
///    * it is replaced with one which is and to which an about:blank document
///    * is loaded.
///    */
/// ```
///

/// `readonly attribute nsIWebBrowserPrint printPreview;`
#[inline]
pub unsafe fn GetPrintPreview(&self, aPrintPreview: *mut *const nsIWebBrowserPrint) -> nsresult {
((*self.vtable).GetPrintPreview)(self, aPrintPreview)
}


/// ```text
/// /**
///    * Whether this docshell can execute scripts based on its hierarchy.
///    * The rule of thumb here is that we disable js if this docshell or any
///    * of its parents disallow scripting.
///    */
/// ```
///

/// `[infallible] readonly attribute boolean canExecuteScripts;`
#[inline]
pub unsafe fn GetCanExecuteScripts(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetCanExecuteScripts)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * Sets whether a docshell is active. An active docshell is one that is
///    * visible, and thus is not a good candidate for certain optimizations
///    * like image frame discarding. Docshells are active unless told otherwise.
///    */
/// ```
///

/// `attribute boolean isActive;`
#[inline]
pub unsafe fn GetIsActive(&self, aIsActive: *mut bool) -> nsresult {
((*self.vtable).GetIsActive)(self, aIsActive)
}


/// ```text
/// /**
///    * Sets whether a docshell is active. An active docshell is one that is
///    * visible, and thus is not a good candidate for certain optimizations
///    * like image frame discarding. Docshells are active unless told otherwise.
///    */
/// ```
///

/// `attribute boolean isActive;`
#[inline]
pub unsafe fn SetIsActive(&self, aIsActive: bool) -> nsresult {
((*self.vtable).SetIsActive)(self, aIsActive)
}


/// ```text
/// /**
///    * Puts the docshell in prerendering mode. noscript because we want only
///    * native code to be able to put a docshell in prerendering.
///    */
/// ```
///

/// `[noscript] void SetIsPrerendered ();`
#[inline]
pub unsafe fn SetIsPrerendered(&self, ) -> nsresult {
((*self.vtable).SetIsPrerendered)(self, )
}


/// ```text
/// /**
///    * Whether this docshell is in prerender mode.
///    */
/// ```
///

/// `[infallible] readonly attribute boolean isPrerendered;`
#[inline]
pub unsafe fn GetIsPrerendered(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetIsPrerendered)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * The ID of the docshell in the session history.
///    */
/// ```
///

/// `readonly attribute nsIDPtr historyID;`
#[inline]
pub unsafe fn GetHistoryID(&self, aHistoryID: *mut *mut nsID) -> nsresult {
((*self.vtable).GetHistoryID)(self, aHistoryID)
}


/// ```text
/// /**
///    * Helper method for accessing this value from C++
///    */
/// ```
///

/// `[noscript,notxpcom] nsID HistoryID ();`
#[inline]
pub unsafe fn HistoryID(&self, ) -> nsID {
((*self.vtable).HistoryID)(self, )
}


/// ```text
/// /**
///    * Sets whether a docshell is an app tab. An app tab docshell may behave
///    * differently than a non-app tab docshell in some cases, such as when
///    * handling link clicks. Docshells are not app tabs unless told otherwise.
///    */
/// ```
///

/// `attribute boolean isAppTab;`
#[inline]
pub unsafe fn GetIsAppTab(&self, aIsAppTab: *mut bool) -> nsresult {
((*self.vtable).GetIsAppTab)(self, aIsAppTab)
}


/// ```text
/// /**
///    * Sets whether a docshell is an app tab. An app tab docshell may behave
///    * differently than a non-app tab docshell in some cases, such as when
///    * handling link clicks. Docshells are not app tabs unless told otherwise.
///    */
/// ```
///

/// `attribute boolean isAppTab;`
#[inline]
pub unsafe fn SetIsAppTab(&self, aIsAppTab: bool) -> nsresult {
((*self.vtable).SetIsAppTab)(self, aIsAppTab)
}


/// ```text
/// /**
///    * Create a new about:blank document and content viewer.
///    * @param aPrincipal the principal to use for the new document.
///    */
/// ```
///

/// `void createAboutBlankContentViewer (in nsIPrincipal aPrincipal);`
#[inline]
pub unsafe fn CreateAboutBlankContentViewer(&self, aPrincipal: *const nsIPrincipal) -> nsresult {
((*self.vtable).CreateAboutBlankContentViewer)(self, aPrincipal)
}


/// ```text
/// /**
///    * Like createAboutBlankContentViewer, but don't check for permit unload.
///    * Only used by special session history operation.
///    * @param aPrincipal the principal to use for the new document.
///    */
/// ```
///

/// `[noscript] void forceCreateAboutBlankContentViewer (in nsIPrincipal aPrincipal);`
#[inline]
pub unsafe fn ForceCreateAboutBlankContentViewer(&self, aPrincipal: *const nsIPrincipal) -> nsresult {
((*self.vtable).ForceCreateAboutBlankContentViewer)(self, aPrincipal)
}


/// ```text
/// /**
///    * Upon getting, returns the canonical encoding label of the document
///    * currently loaded into this docshell.
///    *
///    * Upon setting, sets forcedCharset for compatibility with legacy callers.
///    */
/// ```
///

/// `attribute ACString charset;`
#[inline]
pub unsafe fn GetCharset(&self, aCharset: &mut ::nsstring::nsACString) -> nsresult {
((*self.vtable).GetCharset)(self, aCharset)
}


/// ```text
/// /**
///    * Upon getting, returns the canonical encoding label of the document
///    * currently loaded into this docshell.
///    *
///    * Upon setting, sets forcedCharset for compatibility with legacy callers.
///    */
/// ```
///

/// `attribute ACString charset;`
#[inline]
pub unsafe fn SetCharset(&self, aCharset: &::nsstring::nsACString) -> nsresult {
((*self.vtable).SetCharset)(self, aCharset)
}


/// ```text
/// /**
///    * Called when the user chose an encoding override from the character
///    * encoding menu. Separate from the setter for the charset property to avoid
///    * extensions adding noise to the data.
///    */
/// ```
///

/// `void gatherCharsetMenuTelemetry ();`
#[inline]
pub unsafe fn GatherCharsetMenuTelemetry(&self, ) -> nsresult {
((*self.vtable).GatherCharsetMenuTelemetry)(self, )
}


/// ```text
/// /**
///    * The charset forced by the user.
///    */
/// ```
///

/// `attribute ACString forcedCharset;`
#[inline]
pub unsafe fn GetForcedCharset(&self, aForcedCharset: &mut ::nsstring::nsACString) -> nsresult {
((*self.vtable).GetForcedCharset)(self, aForcedCharset)
}


/// ```text
/// /**
///    * The charset forced by the user.
///    */
/// ```
///

/// `attribute ACString forcedCharset;`
#[inline]
pub unsafe fn SetForcedCharset(&self, aForcedCharset: &::nsstring::nsACString) -> nsresult {
((*self.vtable).SetForcedCharset)(self, aForcedCharset)
}


/// ```text
/// /**
///    * In a child docshell, this is the charset of the parent docshell
///    */
/// ```
///

/// `[noscript,nostdcall,notxpcom] void setParentCharset (in Encoding parentCharset, in int32_t parentCharsetSource, in nsIPrincipal parentCharsetPrincipal);`
const _SetParentCharset: () = ();


/// `[noscript,nostdcall,notxpcom] void getParentCharset (out Encoding parentCharset, out int32_t parentCharsetSource, out nsIPrincipal parentCharsetPrincipal);`
const _GetParentCharset: () = ();

/// ```text
/// /**
///    * Whether the docShell records profile timeline markers at the moment
///    */
/// ```
///

/// `[infallible] attribute boolean recordProfileTimelineMarkers;`
#[inline]
pub unsafe fn GetRecordProfileTimelineMarkers(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetRecordProfileTimelineMarkers)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * Whether the docShell records profile timeline markers at the moment
///    */
/// ```
///

/// `[infallible] attribute boolean recordProfileTimelineMarkers;`
#[inline]
pub unsafe fn SetRecordProfileTimelineMarkers(&self, aRecordProfileTimelineMarkers: bool) -> nsresult {
((*self.vtable).SetRecordProfileTimelineMarkers)(self, aRecordProfileTimelineMarkers)
}


/// ```text
/// /**
///    * Return a DOMHighResTimeStamp representing the number of
///    * milliseconds from an arbitrary point in time.  The reference
///    * point is shared by all DocShells and is also used by timestamps
///    * on markers.
///    */
/// ```
///

/// `DOMHighResTimeStamp now ();`
#[inline]
pub unsafe fn Now(&self, _retval: *mut DOMHighResTimeStamp) -> nsresult {
((*self.vtable).Now)(self, _retval)
}


/// ```text
/// /**
///    * Returns and flushes the profile timeline markers gathered by the docShell
///    */
/// ```
///

/// `[implicit_jscontext] jsval popProfileTimelineMarkers ();`
const _PopProfileTimelineMarkers: () = ();

/// ```text
/// /**
///    * Add an observer to the list of parties to be notified when this docshell's
///    * private browsing status is changed. |obs| must support weak references.
///    */
/// ```
///

/// `void addWeakPrivacyTransitionObserver (in nsIPrivacyTransitionObserver obs);`
#[inline]
pub unsafe fn AddWeakPrivacyTransitionObserver(&self, obs: *const nsIPrivacyTransitionObserver) -> nsresult {
((*self.vtable).AddWeakPrivacyTransitionObserver)(self, obs)
}


/// ```text
/// /**
///    * Add an observer to the list of parties to be notified when reflows are
///    * occurring. |obs| must support weak references.
///    */
/// ```
///

/// `void addWeakReflowObserver (in nsIReflowObserver obs);`
#[inline]
pub unsafe fn AddWeakReflowObserver(&self, obs: *const nsIReflowObserver) -> nsresult {
((*self.vtable).AddWeakReflowObserver)(self, obs)
}


/// ```text
/// /**
///    * Remove an observer from the list of parties to be notified about reflows.
///    */
/// ```
///

/// `void removeWeakReflowObserver (in nsIReflowObserver obs);`
#[inline]
pub unsafe fn RemoveWeakReflowObserver(&self, obs: *const nsIReflowObserver) -> nsresult {
((*self.vtable).RemoveWeakReflowObserver)(self, obs)
}


/// ```text
/// /**
///    * Notify all attached observers that a reflow has just occurred.
///    *
///    * @param interruptible if true, the reflow was interruptible.
///    * @param start         timestamp when reflow started, in milliseconds since
///    *                      navigationStart (accurate to 1/1000 of a ms)
///    * @param end           timestamp when reflow ended, in milliseconds since
///    *                      navigationStart (accurate to 1/1000 of a ms)
///    */
/// ```
///

/// `[noscript] void notifyReflowObservers (in bool interruptible, in DOMHighResTimeStamp start, in DOMHighResTimeStamp end);`
#[inline]
pub unsafe fn NotifyReflowObservers(&self, interruptible: bool, start: DOMHighResTimeStamp, end: DOMHighResTimeStamp) -> nsresult {
((*self.vtable).NotifyReflowObservers)(self, interruptible, start, end)
}


/// ```text
/// /**
///    * Add an observer to the list of parties to be notified when scroll position
///    * of some elements is changed.
///    */
/// ```
///

/// `[noscript] void addWeakScrollObserver (in nsIScrollObserver obs);`
#[inline]
pub unsafe fn AddWeakScrollObserver(&self, obs: *const nsIScrollObserver) -> nsresult {
((*self.vtable).AddWeakScrollObserver)(self, obs)
}


/// ```text
/// /**
///    * Add an observer to the list of parties to be notified when scroll position
///    * of some elements is changed.
///    */
/// ```
///

/// `[noscript] void removeWeakScrollObserver (in nsIScrollObserver obs);`
#[inline]
pub unsafe fn RemoveWeakScrollObserver(&self, obs: *const nsIScrollObserver) -> nsresult {
((*self.vtable).RemoveWeakScrollObserver)(self, obs)
}


/// ```text
/// /**
///    * Notify all attached observers that the scroll position of some element
///    * has changed.
///    */
/// ```
///

/// `[noscript] void notifyScrollObservers ();`
#[inline]
pub unsafe fn NotifyScrollObservers(&self, ) -> nsresult {
((*self.vtable).NotifyScrollObservers)(self, )
}



/// `[infallible] attribute unsigned long frameType;`
#[inline]
pub unsafe fn GetFrameType(&self) -> libc::uint32_t {
let mut result = <libc::uint32_t as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetFrameType)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}



/// `[infallible] attribute unsigned long frameType;`
#[inline]
pub unsafe fn SetFrameType(&self, aFrameType: libc::uint32_t) -> nsresult {
((*self.vtable).SetFrameType)(self, aFrameType)
}


/// ```text
/// /**
///    * Returns true if this docshell corresponds to an <iframe mozbrowser>.
///    * <xul:browser> returns false here.
///    */
/// ```
///

/// `[infallible] readonly attribute boolean isMozBrowser;`
#[inline]
pub unsafe fn GetIsMozBrowser(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetIsMozBrowser)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * Returns true if this docshell corresponds to an isolated <iframe
///    * mozbrowser>.
///    *
///    * <xul:browser> is not considered to be a mozbrowser element.
///    * <iframe mozbrowser noisolation> does not count as isolated since
///    * isolation is disabled.  Isolation can only be disabled if the
///    * containing document is chrome.
///    */
/// ```
///

/// `[infallible] readonly attribute boolean isIsolatedMozBrowserElement;`
#[inline]
pub unsafe fn GetIsIsolatedMozBrowserElement(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetIsIsolatedMozBrowserElement)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * Returns true if this docshell corresponds to an isolated <iframe
///    * mozbrowser> or if the docshell is contained in an isolated <iframe
///    * mozbrowser>.
///    *
///    * <xul:browser> is not considered to be a mozbrowser element. <iframe
///    * mozbrowser noisolation> does not count as isolated since isolation is
///    * disabled.  Isolation can only be disabled if the containing document is
///    * chrome.
///    *
///    * Our notion here of "contained in" means: Walk up the docshell hierarchy in
///    * this process until we hit an <iframe mozbrowser> (or until the hierarchy
///    * ends).  Return true iff the docshell we stopped on has
///    * isIsolatedMozBrowserElement == true.
///    */
/// ```
///

/// `[infallible] readonly attribute boolean isInIsolatedMozBrowserElement;`
#[inline]
pub unsafe fn GetIsInIsolatedMozBrowserElement(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetIsInIsolatedMozBrowserElement)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * Returns true if this docshell corresponds to an <iframe mozbrowser>, or
///    * if this docshell is contained in an <iframe mozbrowser>. <xul:browser>
///    * returns false here.
///    *
///    * To compute this value, we walk up the docshell hierarchy.  If we encounter
///    * a docshell with isMozBrowser before we hit the end of the hierarchy,
///    * we return true.  Otherwise, we return false.
///    */
/// ```
///

/// `[infallible] readonly attribute boolean isInMozBrowser;`
#[inline]
pub unsafe fn GetIsInMozBrowser(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetIsInMozBrowser)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * Returns true if this docshell is the top level content docshell.
///    */
/// ```
///

/// `[infallible] readonly attribute boolean isTopLevelContentDocShell;`
#[inline]
pub unsafe fn GetIsTopLevelContentDocShell(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetIsTopLevelContentDocShell)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * Like nsIDocShellTreeItem::GetSameTypeParent, except this ignores <iframe
///    * mozbrowser> boundaries.
///    */
/// ```
///

/// `nsIDocShell getSameTypeParentIgnoreBrowserBoundaries ();`
#[inline]
pub unsafe fn GetSameTypeParentIgnoreBrowserBoundaries(&self, _retval: *mut *const nsIDocShell) -> nsresult {
((*self.vtable).GetSameTypeParentIgnoreBrowserBoundaries)(self, _retval)
}


/// ```text
/// /**
///    * Like nsIDocShellTreeItem::GetSameTypeRootTreeItem, except this ignores
///    * <iframe mozbrowser> boundaries.
///    */
/// ```
///

/// `nsIDocShell getSameTypeRootTreeItemIgnoreBrowserBoundaries ();`
#[inline]
pub unsafe fn GetSameTypeRootTreeItemIgnoreBrowserBoundaries(&self, _retval: *mut *const nsIDocShell) -> nsresult {
((*self.vtable).GetSameTypeRootTreeItemIgnoreBrowserBoundaries)(self, _retval)
}


/// ```text
/// /**
///    * True iff asynchronous panning and zooming is enabled for this
///    * docshell.
///    */
/// ```
///

/// `readonly attribute bool asyncPanZoomEnabled;`
#[inline]
pub unsafe fn GetAsyncPanZoomEnabled(&self, aAsyncPanZoomEnabled: *mut bool) -> nsresult {
((*self.vtable).GetAsyncPanZoomEnabled)(self, aAsyncPanZoomEnabled)
}


/// ```text
/// /**
///    * The sandbox flags on the docshell. These reflect the value of the sandbox
///    * attribute of the associated IFRAME or CSP-protectable content, if
///    * existent. See the HTML5 spec for more details.
///    * These flags on the docshell reflect the current state of the sandbox
///    * attribute, which is modifiable. They are only used when loading new
///    * content, sandbox flags are also immutably set on the document when it is
///    * loaded.
///    * The sandbox flags of a document depend on the sandbox flags on its
///    * docshell and of its parent document, if any.
///    * See nsSandboxFlags.h for the possible flags.
///    */
/// ```
///

/// `attribute unsigned long sandboxFlags;`
#[inline]
pub unsafe fn GetSandboxFlags(&self, aSandboxFlags: *mut libc::uint32_t) -> nsresult {
((*self.vtable).GetSandboxFlags)(self, aSandboxFlags)
}


/// ```text
/// /**
///    * The sandbox flags on the docshell. These reflect the value of the sandbox
///    * attribute of the associated IFRAME or CSP-protectable content, if
///    * existent. See the HTML5 spec for more details.
///    * These flags on the docshell reflect the current state of the sandbox
///    * attribute, which is modifiable. They are only used when loading new
///    * content, sandbox flags are also immutably set on the document when it is
///    * loaded.
///    * The sandbox flags of a document depend on the sandbox flags on its
///    * docshell and of its parent document, if any.
///    * See nsSandboxFlags.h for the possible flags.
///    */
/// ```
///

/// `attribute unsigned long sandboxFlags;`
#[inline]
pub unsafe fn SetSandboxFlags(&self, aSandboxFlags: libc::uint32_t) -> nsresult {
((*self.vtable).SetSandboxFlags)(self, aSandboxFlags)
}


/// ```text
/// /**
///    * When a new browsing context is opened by a sandboxed document, it needs to
///    * keep track of the browsing context that opened it, so that it can be
///    * navigated by it.  This is the "one permitted sandboxed navigator".
///    */
/// ```
///

/// `attribute nsIDocShell onePermittedSandboxedNavigator;`
#[inline]
pub unsafe fn GetOnePermittedSandboxedNavigator(&self, aOnePermittedSandboxedNavigator: *mut *const nsIDocShell) -> nsresult {
((*self.vtable).GetOnePermittedSandboxedNavigator)(self, aOnePermittedSandboxedNavigator)
}


/// ```text
/// /**
///    * When a new browsing context is opened by a sandboxed document, it needs to
///    * keep track of the browsing context that opened it, so that it can be
///    * navigated by it.  This is the "one permitted sandboxed navigator".
///    */
/// ```
///

/// `attribute nsIDocShell onePermittedSandboxedNavigator;`
#[inline]
pub unsafe fn SetOnePermittedSandboxedNavigator(&self, aOnePermittedSandboxedNavigator: *const nsIDocShell) -> nsresult {
((*self.vtable).SetOnePermittedSandboxedNavigator)(self, aOnePermittedSandboxedNavigator)
}


/// ```text
/// /**
///    * Returns true if we are sandboxed from aTargetDocShell.
///    * aTargetDocShell - the browsing context we are attempting to navigate.
///    */
/// ```
///

/// `[noscript,nostdcall,notxpcom] bool isSandboxedFrom (in nsIDocShell aTargetDocShell);`
const _IsSandboxedFrom: () = ();

/// ```text
/// /**
///    * This member variable determines whether a document has Mixed Active Content that
///    * was initially blocked from loading, but the user has choosen to override the
///    * block and allow the content to load. mMixedContentChannel is set to the document's
///    * channel when the user allows mixed content. The nsMixedContentBlocker content policy
///    * checks if the document's root channel matches the mMixedContentChannel.  If it matches,
///    * then Mixed Content is loaded.  If it does match, mixed content is blocked.
///    *
///    * A match implies that there is definitely mixed active content on a page that was
///    * initially blocked by nsMixedContentBlocker and then allowed and loaded by the user.
///    * A miss imples that IF there is mixed active content on the page AND it was
///    * blocked by nsMixedContentBlocker.cpp, the user has not choosen to override
///    * the block. Note that if the about:config setting
///    * security.mixed_content.block_active_content is set to false, this boolean
///    * will be false, mMixedContentChannel will remain null since blocking active content has
///    * been disabled and hence mMixedContentChannel will never be set.
///    */
/// ```
///

/// `attribute nsIChannel mixedContentChannel;`
#[inline]
pub unsafe fn GetMixedContentChannel(&self, aMixedContentChannel: *mut *const nsIChannel) -> nsresult {
((*self.vtable).GetMixedContentChannel)(self, aMixedContentChannel)
}


/// ```text
/// /**
///    * This member variable determines whether a document has Mixed Active Content that
///    * was initially blocked from loading, but the user has choosen to override the
///    * block and allow the content to load. mMixedContentChannel is set to the document's
///    * channel when the user allows mixed content. The nsMixedContentBlocker content policy
///    * checks if the document's root channel matches the mMixedContentChannel.  If it matches,
///    * then Mixed Content is loaded.  If it does match, mixed content is blocked.
///    *
///    * A match implies that there is definitely mixed active content on a page that was
///    * initially blocked by nsMixedContentBlocker and then allowed and loaded by the user.
///    * A miss imples that IF there is mixed active content on the page AND it was
///    * blocked by nsMixedContentBlocker.cpp, the user has not choosen to override
///    * the block. Note that if the about:config setting
///    * security.mixed_content.block_active_content is set to false, this boolean
///    * will be false, mMixedContentChannel will remain null since blocking active content has
///    * been disabled and hence mMixedContentChannel will never be set.
///    */
/// ```
///

/// `attribute nsIChannel mixedContentChannel;`
#[inline]
pub unsafe fn SetMixedContentChannel(&self, aMixedContentChannel: *const nsIChannel) -> nsresult {
((*self.vtable).SetMixedContentChannel)(self, aMixedContentChannel)
}


/// ```text
/// /**
///    * Checks whether the channel associated with the root docShell is equal to
///    * mMixedContentChannel. If they are the same, allowMixedContent is set to true.
///    * Checks if the root document has a secure connection. If it is, sets
///    * rootHasSecureConnection to true. If the docShell is the root doc shell,
///    * isRootDocShell is set to true.
///    */
/// ```
///

/// `void GetAllowMixedContentAndConnectionData (out boolean rootHasSecureConnection, out boolean allowMixedContent, out boolean isRootDocShell);`
#[inline]
pub unsafe fn GetAllowMixedContentAndConnectionData(&self, rootHasSecureConnection: *mut bool, allowMixedContent: *mut bool, isRootDocShell: *mut bool) -> nsresult {
((*self.vtable).GetAllowMixedContentAndConnectionData)(self, rootHasSecureConnection, allowMixedContent, isRootDocShell)
}


/// ```text
/// /**
///    * Are plugins allowed in the current document loaded in this docshell ?
///    * (if there is one). This depends on whether plugins are allowed by this
///    * docshell itself or if the document is sandboxed and hence plugins should
///    * not be allowed.
///    */
/// ```
///

/// `[noscript,notxpcom] bool pluginsAllowedInCurrentDoc ();`
#[inline]
pub unsafe fn PluginsAllowedInCurrentDoc(&self, ) -> bool {
((*self.vtable).PluginsAllowedInCurrentDoc)(self, )
}


/// ```text
/// /**
///    * Attribute that determines whether fullscreen is allowed to be entered for
///    * this subtree of the docshell tree. This is true when all iframes containing
///    * this docshell have their "allowfullscreen" attribute set to "true".
///    * fullscreenAllowed is only writable at content boundaries, where it is used
///    * to propagate the value of the cross process parent's iframe's
///    * "allowfullscreen" attribute to the child process. Setting
///    * fullscreenAllowed on docshells which aren't content boundaries throws an
///    * exception.
///    */
/// ```
///

/// `[infallible] readonly attribute boolean fullscreenAllowed;`
#[inline]
pub unsafe fn GetFullscreenAllowed(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetFullscreenAllowed)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}



/// `void setFullscreenAllowed (in boolean allowed);`
#[inline]
pub unsafe fn SetFullscreenAllowed(&self, allowed: bool) -> nsresult {
((*self.vtable).SetFullscreenAllowed)(self, allowed)
}



/// `[notxpcom] uint32_t orientationLock ();`
#[inline]
pub unsafe fn OrientationLock(&self, ) -> uint32_t {
((*self.vtable).OrientationLock)(self, )
}



/// `[notxpcom] void setOrientationLock (in uint32_t orientationLock);`
#[inline]
pub unsafe fn SetOrientationLock(&self, orientationLock: uint32_t) -> libc::c_void {
((*self.vtable).SetOrientationLock)(self, orientationLock)
}



/// `[infallible,noscript] attribute boolean affectPrivateSessionLifetime;`
#[inline]
pub unsafe fn GetAffectPrivateSessionLifetime(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetAffectPrivateSessionLifetime)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}



/// `[infallible,noscript] attribute boolean affectPrivateSessionLifetime;`
#[inline]
pub unsafe fn SetAffectPrivateSessionLifetime(&self, aAffectPrivateSessionLifetime: bool) -> nsresult {
((*self.vtable).SetAffectPrivateSessionLifetime)(self, aAffectPrivateSessionLifetime)
}


/// ```text
/// /**
///    * Indicates whether the UI may enable the character encoding menu. The UI
///    * must disable the menu when this property is false.
///    */
/// ```
///

/// `[infallible] readonly attribute boolean mayEnableCharacterEncodingMenu;`
#[inline]
pub unsafe fn GetMayEnableCharacterEncodingMenu(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetMayEnableCharacterEncodingMenu)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}



/// `attribute nsIEditor editor;`
#[inline]
pub unsafe fn GetEditor(&self, aEditor: *mut *const nsIEditor) -> nsresult {
((*self.vtable).GetEditor)(self, aEditor)
}



/// `attribute nsIEditor editor;`
#[inline]
pub unsafe fn SetEditor(&self, aEditor: *const nsIEditor) -> nsresult {
((*self.vtable).SetEditor)(self, aEditor)
}



/// `readonly attribute boolean editable;`
#[inline]
pub unsafe fn GetEditable(&self, aEditable: *mut bool) -> nsresult {
((*self.vtable).GetEditable)(self, aEditable)
}



/// `readonly attribute boolean hasEditingSession;`
#[inline]
pub unsafe fn GetHasEditingSession(&self, aHasEditingSession: *mut bool) -> nsresult {
((*self.vtable).GetHasEditingSession)(self, aHasEditingSession)
}


/// ```text
/// /**
///    * Make this docShell editable, setting a flag that causes
///    * an editor to get created, either immediately, or after
///    * a url has been loaded.
///    *      @param  inWaitForUriLoad    true to wait for a URI before
///    *                                  creating the editor.
///    */
/// ```
///

/// `void makeEditable (in boolean inWaitForUriLoad);`
#[inline]
pub unsafe fn MakeEditable(&self, inWaitForUriLoad: bool) -> nsresult {
((*self.vtable).MakeEditable)(self, inWaitForUriLoad)
}


/// ```text
/// /**
///    * Get the SHEntry associated with a child docshell
///    */
/// ```
///

/// `nsISHEntry getChildSHEntry (in long aChildOffset);`
#[inline]
pub unsafe fn GetChildSHEntry(&self, aChildOffset: libc::int32_t, _retval: *mut *const nsISHEntry) -> nsresult {
((*self.vtable).GetChildSHEntry)(self, aChildOffset, _retval)
}


/// ```text
/// /**
///    * Add a Child SHEntry for a frameset page, given the child's loadtype.
///    * If aCloneChildren is true, then aCloneReference's children will be
///    * cloned onto aHistoryEntry.
///    */
/// ```
///

/// `void addChildSHEntry (in nsISHEntry aCloneReference, in nsISHEntry aHistoryEntry, in long aChildOffset, in unsigned long aLoadType, in boolean aCloneChilden);`
#[inline]
pub unsafe fn AddChildSHEntry(&self, aCloneReference: *const nsISHEntry, aHistoryEntry: *const nsISHEntry, aChildOffset: libc::int32_t, aLoadType: libc::uint32_t, aCloneChilden: bool) -> nsresult {
((*self.vtable).AddChildSHEntry)(self, aCloneReference, aHistoryEntry, aChildOffset, aLoadType, aCloneChilden)
}


/// ```text
/// /**
///    * Whether this docshell should save entries in global history.
///    */
/// ```
///

/// `attribute boolean useGlobalHistory;`
#[inline]
pub unsafe fn GetUseGlobalHistory(&self, aUseGlobalHistory: *mut bool) -> nsresult {
((*self.vtable).GetUseGlobalHistory)(self, aUseGlobalHistory)
}


/// ```text
/// /**
///    * Whether this docshell should save entries in global history.
///    */
/// ```
///

/// `attribute boolean useGlobalHistory;`
#[inline]
pub unsafe fn SetUseGlobalHistory(&self, aUseGlobalHistory: bool) -> nsresult {
((*self.vtable).SetUseGlobalHistory)(self, aUseGlobalHistory)
}


/// ```text
/// /**
///    * Removes nsISHEntry objects related to this docshell from session history.
///    * Use this only with subdocuments, like iframes.
///    */
/// ```
///

/// `void removeFromSessionHistory ();`
#[inline]
pub unsafe fn RemoveFromSessionHistory(&self, ) -> nsresult {
((*self.vtable).RemoveFromSessionHistory)(self, )
}


/// ```text
/// /**
///    * Set when an iframe/frame is added dynamically.
///    */
/// ```
///

/// `attribute boolean createdDynamically;`
#[inline]
pub unsafe fn GetCreatedDynamically(&self, aCreatedDynamically: *mut bool) -> nsresult {
((*self.vtable).GetCreatedDynamically)(self, aCreatedDynamically)
}


/// ```text
/// /**
///    * Set when an iframe/frame is added dynamically.
///    */
/// ```
///

/// `attribute boolean createdDynamically;`
#[inline]
pub unsafe fn SetCreatedDynamically(&self, aCreatedDynamically: bool) -> nsresult {
((*self.vtable).SetCreatedDynamically)(self, aCreatedDynamically)
}


/// ```text
/// /**
///    * Returns false for mLSHE, true for mOSHE
///    */
/// ```
///

/// `boolean getCurrentSHEntry (out nsISHEntry aEntry);`
#[inline]
pub unsafe fn GetCurrentSHEntry(&self, aEntry: *mut *const nsISHEntry, _retval: *mut bool) -> nsresult {
((*self.vtable).GetCurrentSHEntry)(self, aEntry, _retval)
}


/// ```text
/// /**
///     * Cherry picked parts of nsIController.
///     * They are here, because we want to call these functions
///     * from JS.
///     */
/// ```
///

/// `boolean isCommandEnabled (in string command);`
#[inline]
pub unsafe fn IsCommandEnabled(&self, command: *const libc::c_char, _retval: *mut bool) -> nsresult {
((*self.vtable).IsCommandEnabled)(self, command, _retval)
}



/// `void doCommand (in string command);`
#[inline]
pub unsafe fn DoCommand(&self, command: *const libc::c_char) -> nsresult {
((*self.vtable).DoCommand)(self, command)
}



/// `void doCommandWithParams (in string command, in nsICommandParams aParams);`
#[inline]
pub unsafe fn DoCommandWithParams(&self, command: *const libc::c_char, aParams: *const nsICommandParams) -> nsresult {
((*self.vtable).DoCommandWithParams)(self, command, aParams)
}


/// ```text
/// /**
///    * Invisible DocShell are dummy construct to simulate DOM windows
///    * without any actual visual representation. They have to be marked
///    * at construction time, to avoid any painting activity.
///    */
/// ```
///

/// `[noscript,notxpcom] bool IsInvisible ();`
#[inline]
pub unsafe fn IsInvisible(&self, ) -> bool {
((*self.vtable).IsInvisible)(self, )
}



/// `[noscript,notxpcom] void SetInvisible (in bool aIsInvisibleDochsell);`
#[inline]
pub unsafe fn SetInvisible(&self, aIsInvisibleDochsell: bool) -> libc::c_void {
((*self.vtable).SetInvisible)(self, aIsInvisibleDochsell)
}


/// ```text
/// /**
///  * Get the script global for the document in this docshell.
/// */
/// ```
///

/// `[noscript,nostdcall,notxpcom] nsIScriptGlobalObject GetScriptGlobalObject ();`
const _GetScriptGlobalObject: () = ();

/// ```text
/// /**
///    * If deviceSizeIsPageSize is set to true, device-width/height media queries
///    * will be calculated from the page size, not the device size.
///    *
///    * Used by the Responsive Design Mode and B2G Simulator.
///    *
///    * Default is False.
///    * Default value can be overriden with
///    * docshell.device_size_is_page_size pref.
///    */
/// ```
///

/// `[infallible] attribute boolean deviceSizeIsPageSize;`
#[inline]
pub unsafe fn GetDeviceSizeIsPageSize(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetDeviceSizeIsPageSize)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * If deviceSizeIsPageSize is set to true, device-width/height media queries
///    * will be calculated from the page size, not the device size.
///    *
///    * Used by the Responsive Design Mode and B2G Simulator.
///    *
///    * Default is False.
///    * Default value can be overriden with
///    * docshell.device_size_is_page_size pref.
///    */
/// ```
///

/// `[infallible] attribute boolean deviceSizeIsPageSize;`
#[inline]
pub unsafe fn SetDeviceSizeIsPageSize(&self, aDeviceSizeIsPageSize: bool) -> nsresult {
((*self.vtable).SetDeviceSizeIsPageSize)(self, aDeviceSizeIsPageSize)
}


/// ```text
/// /**
///    * Regarding setOpener / getOpener - We can't use XPIDL's "attribute"
///    * for notxpcom, so we're relegated to using explicit gets / sets. This
///    * should be fine, considering that these methods should only ever be
///    * called from native code.
///    */
/// ```
///

/// `[noscript,nostdcall,notxpcom] void setOpener (in nsITabParent aOpener);`
const _SetOpener: () = ();


/// `[noscript,nostdcall,notxpcom] nsITabParent getOpener ();`
const _GetOpener: () = ();

/// ```text
/// /**
///    * Notify DocShell when the browser is about to start executing JS, and after
///    * that execution has stopped.  This only occurs when the Timeline devtool
///    * is collecting information.
///    */
/// ```
///

/// `[noscript,nostdcall,notxpcom] void notifyJSRunToCompletionStart (in string aReason, in wstring functionName, in wstring fileName, in unsigned long lineNumber, in jsval asyncStack, in string asyncCause);`
const _NotifyJSRunToCompletionStart: () = ();


/// `[noscript,nostdcall,notxpcom] void notifyJSRunToCompletionStop ();`
const _NotifyJSRunToCompletionStop: () = ();

/// ```text
/// /**
///    * This attribute determines whether a document which is not about:blank has
///    * already be loaded by this docShell.
///    */
/// ```
///

/// `[infallible] readonly attribute boolean hasLoadedNonBlankURI;`
#[inline]
pub unsafe fn GetHasLoadedNonBlankURI(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetHasLoadedNonBlankURI)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * Allow usage of -moz-window-dragging:drag for content docshells.
///    * True for top level chrome docshells. Throws if set to false with
///    * top level chrome docshell.
///    */
/// ```
///

/// `attribute boolean windowDraggingAllowed;`
#[inline]
pub unsafe fn GetWindowDraggingAllowed(&self, aWindowDraggingAllowed: *mut bool) -> nsresult {
((*self.vtable).GetWindowDraggingAllowed)(self, aWindowDraggingAllowed)
}


/// ```text
/// /**
///    * Allow usage of -moz-window-dragging:drag for content docshells.
///    * True for top level chrome docshells. Throws if set to false with
///    * top level chrome docshell.
///    */
/// ```
///

/// `attribute boolean windowDraggingAllowed;`
#[inline]
pub unsafe fn SetWindowDraggingAllowed(&self, aWindowDraggingAllowed: bool) -> nsresult {
((*self.vtable).SetWindowDraggingAllowed)(self, aWindowDraggingAllowed)
}


/// ```text
/// /**
///    * Sets/gets the current scroll restoration mode.
///    * @see https://html.spec.whatwg.org/#dom-history-scroll-restoration
///    */
/// ```
///

/// `attribute boolean currentScrollRestorationIsManual;`
#[inline]
pub unsafe fn GetCurrentScrollRestorationIsManual(&self, aCurrentScrollRestorationIsManual: *mut bool) -> nsresult {
((*self.vtable).GetCurrentScrollRestorationIsManual)(self, aCurrentScrollRestorationIsManual)
}


/// ```text
/// /**
///    * Sets/gets the current scroll restoration mode.
///    * @see https://html.spec.whatwg.org/#dom-history-scroll-restoration
///    */
/// ```
///

/// `attribute boolean currentScrollRestorationIsManual;`
#[inline]
pub unsafe fn SetCurrentScrollRestorationIsManual(&self, aCurrentScrollRestorationIsManual: bool) -> nsresult {
((*self.vtable).SetCurrentScrollRestorationIsManual)(self, aCurrentScrollRestorationIsManual)
}


/// ```text
/// /**
///    * Setter and getter for the origin attributes living on this docshell.
///    */
/// ```
///

/// `[implicit_jscontext] jsval getOriginAttributes ();`
const _GetOriginAttributes: () = ();


/// `[implicit_jscontext] void setOriginAttributes (in jsval aAttrs);`
const _SetOriginAttributes: () = ();

/// ```text
/// /**
///    * The editing session for this docshell.
///    */
/// ```
///

/// `readonly attribute nsIEditingSession editingSession;`
#[inline]
pub unsafe fn GetEditingSession(&self, aEditingSession: *mut *const nsIEditingSession) -> nsresult {
((*self.vtable).GetEditingSession)(self, aEditingSession)
}


/// ```text
/// /**
///    * The tab child for this docshell.
///    */
/// ```
///

/// `[binaryname(ScriptableTabChild)] readonly attribute nsITabChild tabChild;`
#[inline]
pub unsafe fn GetScriptableTabChild(&self, aTabChild: *mut *const nsITabChild) -> nsresult {
((*self.vtable).GetScriptableTabChild)(self, aTabChild)
}



/// `[noscript,nostdcall,notxpcom] TabChildRef GetTabChild ();`
const _GetTabChild: () = ();


/// `[noscript,nostdcall,notxpcom] nsICommandManager GetCommandManager ();`
const _GetCommandManager: () = ();

/// ```text
/// /**
///    * This allows chrome to override the default choice of whether touch events
///    * are available on a specific docshell. Possible values are listed below.
///    */
/// ```
///

/// `attribute unsigned long touchEventsOverride;`
#[inline]
pub unsafe fn GetTouchEventsOverride(&self, aTouchEventsOverride: *mut libc::uint32_t) -> nsresult {
((*self.vtable).GetTouchEventsOverride)(self, aTouchEventsOverride)
}


/// ```text
/// /**
///    * This allows chrome to override the default choice of whether touch events
///    * are available on a specific docshell. Possible values are listed below.
///    */
/// ```
///

/// `attribute unsigned long touchEventsOverride;`
#[inline]
pub unsafe fn SetTouchEventsOverride(&self, aTouchEventsOverride: libc::uint32_t) -> nsresult {
((*self.vtable).SetTouchEventsOverride)(self, aTouchEventsOverride)
}


/// ```text
/// /**
///    * This value is `true` if its corresponding unit of related browsing contexts
///    * (TabGroup) contains only 1 toplevel window, and that window is the outer
///    * window corresponding to this docshell.
///    *
///    * The value is `false` otherwise. This is the case if the docshell is an
///    * iframe, has window.opener set, or another window with window.opener
///    * referring to this window exists.
///    *
///    * If this value is `false`, it would be web content visible for a load
///    * occuring in this docshell to be performed within a different docshell.
///    */
/// ```
///

/// `[infallible] readonly attribute boolean isOnlyToplevelInTabGroup;`
#[inline]
pub unsafe fn GetIsOnlyToplevelInTabGroup(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetIsOnlyToplevelInTabGroup)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * Returns `true` if this docshell was created due to a Large-Allocation
///    * header, and has not seen the initiating load yet.
///    */
/// ```
///

/// `[infallible] readonly attribute boolean awaitingLargeAlloc;`
#[inline]
pub unsafe fn GetAwaitingLargeAlloc(&self) -> bool {
let mut result = <bool as ::std::default::Default>::default();
let _rv = ((*self.vtable).GetAwaitingLargeAlloc)(self, &mut result);
debug_assert!(::nserror::NsresultExt::succeeded(_rv));
result
}


/// ```text
/// /**
///    * Attribute that determines whether tracking protection is enabled.
///    */
/// ```
///

/// `attribute boolean useTrackingProtection;`
#[inline]
pub unsafe fn GetUseTrackingProtection(&self, aUseTrackingProtection: *mut bool) -> nsresult {
((*self.vtable).GetUseTrackingProtection)(self, aUseTrackingProtection)
}


/// ```text
/// /**
///    * Attribute that determines whether tracking protection is enabled.
///    */
/// ```
///

/// `attribute boolean useTrackingProtection;`
#[inline]
pub unsafe fn SetUseTrackingProtection(&self, aUseTrackingProtection: bool) -> nsresult {
((*self.vtable).SetUseTrackingProtection)(self, aUseTrackingProtection)
}


/// ```text
/// /**
///   * Fire a dummy location change event asynchronously.
///   */
/// ```
///

/// `[noscript] void dispatchLocationChangeEvent ();`
#[inline]
pub unsafe fn DispatchLocationChangeEvent(&self, ) -> nsresult {
((*self.vtable).DispatchLocationChangeEvent)(self, )
}


/// ```text
/// /**
///    * Take ownership of the ClientSource representing an initial about:blank
///    * document that was never needed.  As an optimization we avoid creating
///    * this document if no code calls GetDocument(), but we still need a
///    * ClientSource object to represent the about:blank window.  This may return
///    * nullptr; for example if the docshell has created a real window and document
///    * already.
///    */
/// ```
///

/// `[noscript,nostdcall,notxpcom] UniqueClientSource TakeInitialClientSource ();`
const _TakeInitialClientSource: () = ();

/// ```text
/// /**
///    * Display mode for this docshell. Defaults to DISPLAY_MODE_BROWSER.
///    * Media queries only look at the value in the top-most docshell.
///    */
/// ```
///

/// `attribute unsigned long displayMode;`
#[inline]
pub unsafe fn GetDisplayMode(&self, aDisplayMode: *mut libc::uint32_t) -> nsresult {
((*self.vtable).GetDisplayMode)(self, aDisplayMode)
}


/// ```text
/// /**
///    * Display mode for this docshell. Defaults to DISPLAY_MODE_BROWSER.
///    * Media queries only look at the value in the top-most docshell.
///    */
/// ```
///

/// `attribute unsigned long displayMode;`
#[inline]
pub unsafe fn SetDisplayMode(&self, aDisplayMode: libc::uint32_t) -> nsresult {
((*self.vtable).SetDisplayMode)(self, aDisplayMode)
}


}