PageSourceSearch

https://bukun.net/static/f2elib/leaflet/leaflet.ChineseTmsProvider…60dfde5ee85847d091b39ea0a952f621e4b528eb09b

js bukun.net collected 2026-09-27 14:25:22 UTC 3,100 bytes, 73 lines download raw bytes

1L.TileLayer.ChinaProvider = L.TileLayer.extend({
2
3    initialize: function(type, options) { // (type, Object)
4        var providers = L.TileLayer.ChinaProvider.providers;
5
6        var parts = type.split('.');
7
8        var providerName = parts[0];
9        var mapName = parts[1];
10        var mapType = parts[2];
11
12        var url = providers[providerName][mapName][mapType];
13        options.subdomains = providers[providerName].Subdomains;
14
15        L.TileLayer.prototype.initialize.call(this, url, options);
16    }
17});
18
19L.TileLayer.ChinaProvider.providers = {
20    TianDiTu: {
21        Normal: {
22            Map: "http://t{s}.tianditu.gov.cn/DataServer?T=vec_w&X={x}&Y={y}&L={z}&tk=8843d1c1f4c8271a8cbdf40ec4cfae9a",
23            Annotion: "http://t{s}.tianditu.gov.cn/DataServer?T=cva_w&X={x}&Y={y}&L={z}&tk=8843d1c1f4c8271a8cbdf40ec4cfae9a"
24        },
25        Satellite: {
26            Map: "http://t{s}.tianditu.gov.cn/DataServer?T=img_w&X={x}&Y={y}&L={z}&tk=8843d1c1f4c8271a8cbdf40ec4cfae9a",
27            Annotion: "http://t{s}.tianditu.gov.cn/DataServer?T=cia_w&X={x}&Y={y}&L={z}&tk=8843d1c1f4c8271a8cbdf40ec4cfae9a"
28        },
29        Terrain: {
30            Map: "http://t{s}.tianditu.gov.cn/DataServer?T=ter_w&X={x}&Y={y}&L={z}&tk=8843d1c1f4c8271a8cbdf40ec4cfae9a",
31            Annotion: "http://t{s}.tianditu.gov.cn/DataServer?T=cta_w&X={x}&Y={y}&L={z}&tk=8843d1c1f4c8271a8cbdf40ec4cfae9a"
32        },
33        Subdomains: ['0', '1', '2', '3', '4', '5', '6', '7']
34    },
35
36    GaoDe: {
37        Normal: {
38            Map: 'http://webrd0{s}.is.autonavi.com/appmaptile?lang=zh_cn&size=1&scale=1&style=8&x={x}&y={y}&z={z}'
39        },
40        Satellite: {
41            Map: 'http://webst0{s}.is.autonavi.com/appmaptile?style=6&x={x}&y={y}&z={z}',
42            Annotion: 'http://webst0{s}.is.autonavi.com/appmaptile?style=8&x={x}&y={y}&z={z}'
43        },
44        Subdomains: ["1", "2", "3", "4"]
45    },
46
47    Google: {
48        Normal: {
49            Map: "http://www.google.cn/maps/vt?lyrs=m@189&gl=cn&x={x}&y={y}&z={z}"
50        },
51        Satellite: {
52            Map: "http://www.google.cn/maps/vt?lyrs=s@189&gl=cn&x={x}&y={y}&z={z}"
53        },
54        Subdomains: []
55    },
56
57    Geoq: {
58        Normal: {
59            Map: "http://map.geoq.cn/ArcGIS/rest/services/ChinaOnlineCommunity/MapServer/tile/{z}/{y}/{x}",
60            Color: "http://map.geoq.cn/ArcGIS/rest/services/ChinaOnlineStreetColor/MapServer/tile/{z}/{y}/{x}",
61            PurplishBlue: "http://map.geoq.cn/ArcGIS/rest/services/ChinaOnlineStreetPurplishBlue/MapServer/tile/{z}/{y}/{x}",
62            Gray: "http://map.geoq.cn/ArcGIS/rest/services/ChinaOnlineStreetGray/MapServer/tile/{z}/{y}/{x}",
63            Warm: "http://map.geoq.cn/ArcGIS/rest/services/ChinaOnlineStreetWarm/MapServer/tile/{z}/{y}/{x}",
64            Cold: "http://map.geoq.cn/ArcGIS/rest/services/ChinaOnlineStreetCold/MapServer/tile/{z}/{y}/{x}"
65        },
66        Subdomains: []
67
68    }
69};
70
71L.tileLayer.chinaProvider = function(type, options) {
72    return new L.TileLayer.ChinaProvider(type, options);
73};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.