monagree-locs 1.0.7 → 1.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/classes.js CHANGED
@@ -1 +1,23 @@
1
- 'use strict';function a0_0x292f(_0x31f85b,_0x113b25){var _0x33aced=a0_0x33ac();return a0_0x292f=function(_0x292ff4,_0x43ff35){_0x292ff4=_0x292ff4-0x15c;var _0x4003c9=_0x33aced[_0x292ff4];return _0x4003c9;},a0_0x292f(_0x31f85b,_0x113b25);}var a0_0x5401d7=a0_0x292f;(function(_0x8b4c2d,_0x1467ae){var _0x57ab17=a0_0x292f,_0x22d66d=_0x8b4c2d();while(!![]){try{var _0x3816f4=parseInt(_0x57ab17(0x170))/0x1*(parseInt(_0x57ab17(0x15f))/0x2)+-parseInt(_0x57ab17(0x167))/0x3*(parseInt(_0x57ab17(0x165))/0x4)+-parseInt(_0x57ab17(0x172))/0x5*(-parseInt(_0x57ab17(0x16f))/0x6)+parseInt(_0x57ab17(0x163))/0x7*(parseInt(_0x57ab17(0x16e))/0x8)+-parseInt(_0x57ab17(0x16c))/0x9+parseInt(_0x57ab17(0x168))/0xa*(-parseInt(_0x57ab17(0x15c))/0xb)+-parseInt(_0x57ab17(0x16b))/0xc;if(_0x3816f4===_0x1467ae)break;else _0x22d66d['push'](_0x22d66d['shift']());}catch(_0x1a3c4c){_0x22d66d['push'](_0x22d66d['shift']());}}}(a0_0x33ac,0x52ab1));Object[a0_0x5401d7(0x166)](exports,a0_0x5401d7(0x162),{'value':!![]}),exports['mLoc']=void 0x0;var mLoc=(function(){var _0x462c16=a0_0x5401d7;function _0x581d5f(_0x2c8b0a,_0x1a70e9){this['id']=_0x2c8b0a,this['data']=_0x1a70e9;}return _0x581d5f['prototype']['getId']=function(){return this['id'];},_0x581d5f[_0x462c16(0x16d)][_0x462c16(0x160)]=function(){var _0x35056a=_0x462c16;return this[_0x35056a(0x164)][_0x35056a(0x161)];},_0x581d5f['prototype'][_0x462c16(0x16a)]=function(){return this['data']['center']['lat'];},_0x581d5f['prototype'][_0x462c16(0x169)]=function(){var _0x1078b2=_0x462c16;return this['data'][_0x1078b2(0x15e)][_0x1078b2(0x15d)];},_0x581d5f;}());function a0_0x33ac(){var _0x29dcf1=['6MGfIGw','1oAzraT','mLoc','1598305WxSBWi','11nmEcXX','lon','center','208254CMBvtq','getName','name','__esModule','41433CHnYqH','data','596jQvucc','defineProperty','4317AOpDzM','2418090VgtaDP','getLongitude','getLatitude','325836krLFcF','624663uqoskX','prototype','632gaVaki'];a0_0x33ac=function(){return _0x29dcf1;};return a0_0x33ac();}exports[a0_0x5401d7(0x171)]=mLoc;
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.mLoc = void 0;
4
+ var mLoc = /** @class */ (function () {
5
+ function mLoc(id, data) {
6
+ this.id = id;
7
+ this.data = data;
8
+ }
9
+ mLoc.prototype.getId = function () {
10
+ return this.id;
11
+ };
12
+ mLoc.prototype.getName = function () {
13
+ return this.data.name;
14
+ };
15
+ mLoc.prototype.getLatitude = function () {
16
+ return this.data.center.lat;
17
+ };
18
+ mLoc.prototype.getLongitude = function () {
19
+ return this.data.center.lon;
20
+ };
21
+ return mLoc;
22
+ }());
23
+ exports.mLoc = mLoc;
package/dist/index.js CHANGED
@@ -1 +1,96 @@
1
- 'use strict';var a1_0x379708=a1_0x5afb;(function(_0x59a9f8,_0x20d396){var _0x304b1b=a1_0x5afb,_0x1558e8=_0x59a9f8();while(!![]){try{var _0x21de58=parseInt(_0x304b1b(0x1d7))/0x1+-parseInt(_0x304b1b(0x1cc))/0x2+parseInt(_0x304b1b(0x1cd))/0x3*(-parseInt(_0x304b1b(0x1cf))/0x4)+parseInt(_0x304b1b(0x1e4))/0x5+parseInt(_0x304b1b(0x1dc))/0x6+-parseInt(_0x304b1b(0x1d2))/0x7*(parseInt(_0x304b1b(0x1d3))/0x8)+parseInt(_0x304b1b(0x1de))/0x9;if(_0x21de58===_0x20d396)break;else _0x1558e8['push'](_0x1558e8['shift']());}catch(_0x5d6255){_0x1558e8['push'](_0x1558e8['shift']());}}}(a1_0x3a6a,0x9c79c));Object[a1_0x379708(0x1da)](exports,a1_0x379708(0x1e2),{'value':!![]}),exports[a1_0x379708(0x1e3)]=exports[a1_0x379708(0x1d4)]=exports[a1_0x379708(0x1d5)]=void 0x0;function a1_0x5afb(_0x59b38e,_0x3a62c5){var _0x3a6a62=a1_0x3a6a();return a1_0x5afb=function(_0x5afb37,_0x908166){_0x5afb37=_0x5afb37-0x1cb;var _0x33cac9=_0x3a6a62[_0x5afb37];return _0x33cac9;},a1_0x5afb(_0x59b38e,_0x3a62c5);}var classes_1=require(a1_0x379708(0x1d8)),locs_1=require(a1_0x379708(0x1d6)),mCountry=(function(){var _0x11fbe3=a1_0x379708;function _0x558dc9(){}return _0x558dc9[_0x11fbe3(0x1db)]=function(){var _0x36ba24=_0x11fbe3,_0x4a662c=[];for(var _0x3765f7 in locs_1[_0x36ba24(0x1e0)]){if(locs_1[_0x36ba24(0x1e0)][_0x36ba24(0x1dd)](_0x3765f7)){var _0x2760f1=locs_1[_0x36ba24(0x1e0)][_0x3765f7];delete _0x2760f1[_0x36ba24(0x1e1)],_0x4a662c['push'](new classes_1[(_0x36ba24(0x1e6))](_0x3765f7,_0x2760f1));}}return _0x4a662c;},_0x558dc9[_0x11fbe3(0x1ce)]=function(_0x57440c){var _0x55c1ae=_0x11fbe3;if(locs_1['locs'][_0x57440c]){var _0x358f80=locs_1[_0x55c1ae(0x1e0)][_0x57440c];return delete _0x358f80[_0x55c1ae(0x1e1)],new classes_1[(_0x55c1ae(0x1e6))](_0x57440c,_0x358f80);}return undefined;},_0x558dc9;}());exports[a1_0x379708(0x1d5)]=mCountry;var mState=(function(){var _0x1ac9bb=a1_0x379708;function _0x461e4c(){}return _0x461e4c[_0x1ac9bb(0x1e5)]=function(_0x1cd9a5){var _0x2c9d0c=_0x1ac9bb,_0xa58c76=[];if(locs_1[_0x2c9d0c(0x1e0)][_0x1cd9a5]){var _0x222b4c=locs_1[_0x2c9d0c(0x1e0)][_0x1cd9a5][_0x2c9d0c(0x1e1)];for(var _0xd64bee in _0x222b4c){if(_0x222b4c[_0x2c9d0c(0x1dd)](_0xd64bee)){var _0x1c63eb=_0x222b4c[_0xd64bee];delete _0x1c63eb['lgas'],_0xa58c76[_0x2c9d0c(0x1d0)](new classes_1[(_0x2c9d0c(0x1e6))](_0xd64bee,_0x1c63eb));}}}return _0xa58c76;},_0x461e4c[_0x1ac9bb(0x1d1)]=function(_0x3cad69,_0x5c3329){var _0x3af0fc=_0x1ac9bb;if(locs_1[_0x3af0fc(0x1e0)][_0x3cad69]){var _0x1b9c88=locs_1[_0x3af0fc(0x1e0)][_0x3cad69][_0x3af0fc(0x1e1)];if(_0x1b9c88&&_0x1b9c88[_0x5c3329]){var _0x4c832f=_0x1b9c88[_0x5c3329];return delete _0x4c832f[_0x3af0fc(0x1df)],new classes_1['mLoc'](_0x5c3329,_0x4c832f);}}return undefined;},_0x461e4c;}());function a1_0x3a6a(){var _0x130fe4=['mLga','3040785QfElKA','getStatesByCountry','mLoc','getLgasByState','921658sVpDcm','1565844NlQWnY','getCountryByCode','4uAVzjK','push','getStateByCode','7zjExjn','9445312nxQfyS','mState','mCountry','./locs','805808muUHDC','./classes','getLgaByCode','defineProperty','getAllCountries','6583140pwnTnu','hasOwnProperty','2638890ZvNyWO','lgas','locs','states','__esModule'];a1_0x3a6a=function(){return _0x130fe4;};return a1_0x3a6a();}exports[a1_0x379708(0x1d4)]=mState;var mLga=(function(){var _0x177afa=a1_0x379708;function _0xc43fb5(){}return _0xc43fb5[_0x177afa(0x1cb)]=function(_0x10db3f,_0x3de8a5){var _0x1fa988=_0x177afa,_0x52469f=[];if(locs_1[_0x1fa988(0x1e0)][_0x10db3f]){var _0x3220f9=locs_1['locs'][_0x10db3f][_0x1fa988(0x1e1)];if(_0x3220f9&&_0x3220f9[_0x3de8a5]){var _0x3da9b3=_0x3220f9[_0x3de8a5][_0x1fa988(0x1df)];for(var _0x54a97b in _0x3da9b3){if(_0x3da9b3[_0x1fa988(0x1dd)](_0x54a97b)){var _0x4a5774=_0x3da9b3[_0x54a97b];_0x52469f[_0x1fa988(0x1d0)](new classes_1[(_0x1fa988(0x1e6))](_0x54a97b,_0x4a5774));}}}}return _0x52469f;},_0xc43fb5[_0x177afa(0x1d9)]=function(_0x8943c0,_0x4e9bc7,_0x822c15){var _0x27395c=_0x177afa;if(locs_1[_0x27395c(0x1e0)][_0x8943c0]){var _0x132854=locs_1[_0x27395c(0x1e0)][_0x8943c0][_0x27395c(0x1e1)];if(_0x132854&&_0x132854[_0x4e9bc7]){var _0x2615b4=_0x132854[_0x4e9bc7]['lgas'];if(_0x2615b4&&_0x2615b4[_0x822c15]){var _0x283cc3=_0x2615b4[_0x822c15];return new classes_1[(_0x27395c(0x1e6))](_0x822c15,_0x283cc3);}}}return undefined;},_0xc43fb5;}());exports[a1_0x379708(0x1e3)]=mLga;
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.mLga = exports.mState = exports.mCountry = void 0;
4
+ var classes_1 = require("./classes");
5
+ var locs_1 = require("./locs");
6
+ var mCountry = /** @class */ (function () {
7
+ function mCountry() {
8
+ }
9
+ mCountry.getAllCountries = function () {
10
+ var countries = [];
11
+ for (var countryCode in locs_1.locs) {
12
+ if (locs_1.locs.hasOwnProperty(countryCode)) {
13
+ var country = locs_1.locs[countryCode];
14
+ delete country['states'];
15
+ countries.push(new classes_1.mLoc(countryCode, country));
16
+ }
17
+ }
18
+ return countries;
19
+ };
20
+ mCountry.getCountryByCode = function (countryCode) {
21
+ if (locs_1.locs[countryCode]) {
22
+ var country = locs_1.locs[countryCode];
23
+ delete country['states'];
24
+ return new classes_1.mLoc(countryCode, country);
25
+ }
26
+ return undefined;
27
+ };
28
+ return mCountry;
29
+ }());
30
+ exports.mCountry = mCountry;
31
+ var mState = /** @class */ (function () {
32
+ function mState() {
33
+ }
34
+ mState.getStatesByCountry = function (countryCode) {
35
+ var states = [];
36
+ if (locs_1.locs[countryCode]) {
37
+ var nLoc = locs_1.locs[countryCode]['states'];
38
+ for (var stateCode in nLoc) {
39
+ if (nLoc.hasOwnProperty(stateCode)) {
40
+ var state = nLoc[stateCode];
41
+ delete state['lgas'];
42
+ states.push(new classes_1.mLoc(stateCode, state));
43
+ }
44
+ }
45
+ }
46
+ return states;
47
+ };
48
+ mState.getStateByCode = function (countryCode, stateCode) {
49
+ if (locs_1.locs[countryCode]) {
50
+ var nLoc = locs_1.locs[countryCode]['states'];
51
+ if (nLoc && nLoc[stateCode]) {
52
+ var state = nLoc[stateCode];
53
+ delete state['lgas'];
54
+ return new classes_1.mLoc(stateCode, state);
55
+ }
56
+ }
57
+ return undefined;
58
+ };
59
+ return mState;
60
+ }());
61
+ exports.mState = mState;
62
+ var mLga = /** @class */ (function () {
63
+ function mLga() {
64
+ }
65
+ mLga.getLgasByState = function (countryCode, stateCode) {
66
+ var lgas = [];
67
+ if (locs_1.locs[countryCode]) {
68
+ var nLoc = locs_1.locs[countryCode]['states'];
69
+ if (nLoc && nLoc[stateCode]) {
70
+ var nnLoc = nLoc[stateCode]['lgas'];
71
+ for (var lgaCode in nnLoc) {
72
+ if (nnLoc.hasOwnProperty(lgaCode)) {
73
+ var lga = nnLoc[lgaCode];
74
+ lgas.push(new classes_1.mLoc(lgaCode, lga));
75
+ }
76
+ }
77
+ }
78
+ }
79
+ return lgas;
80
+ };
81
+ mLga.getLgaByCode = function (countryCode, stateCode, lgaCode) {
82
+ if (locs_1.locs[countryCode]) {
83
+ var nLoc = locs_1.locs[countryCode]['states'];
84
+ if (nLoc && nLoc[stateCode]) {
85
+ var nnLoc = nLoc[stateCode]['lgas'];
86
+ if (nnLoc && nnLoc[lgaCode]) {
87
+ var lga = nnLoc[lgaCode];
88
+ return new classes_1.mLoc(lgaCode, lga);
89
+ }
90
+ }
91
+ }
92
+ return undefined;
93
+ };
94
+ return mLga;
95
+ }());
96
+ exports.mLga = mLga;