xiaomianao666

邀您一起看:奇妙工具箱

Apr 7th, 2023
95
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. 海阔视界规则分享,当前分享的是:二级页面详情¥page_detail¥奇妙工具箱@@eyJkYXRhIjoie1wibGFzdF9jaGFwdGVyX3J1bGVcIjpcIlwiLFwidGl0bGVcIjpcIuWlh+WmmeW3peWFt+eusVwiLFwiYXV0aG9yXCI6XCLlsI/mo4noooTwn4yeXCIsXCJ1cmxcIjpcImhpa2VyOi8vZW1wdHkjI1wiLFwidmVyc2lvblwiOjgsXCJjb2xfdHlwZVwiOlwibW92aWVfM1wiLFwiY2xhc3NfbmFtZVwiOlwiXCIsXCJ0eXBlXCI6XCJ0b29sXCIsXCJjbGFzc191cmxcIjpcIlwiLFwiYXJlYV9uYW1lXCI6XCJcIixcImFyZWFfdXJsXCI6XCJcIixcInNvcnRfbmFtZVwiOlwiXCIsXCJ5ZWFyX25hbWVcIjpcIlwiLFwic29ydF91cmxcIjpcIlwiLFwieWVhcl91cmxcIjpcIlwiLFwiZmluZF9ydWxlXCI6XCJqczpcXG52YXIgZCA9IFtdO1xcbmxldCB2aXAgPSBnZXRJdGVtKFxcXCJ2aXBcXFwiLCBcXFwiMFxcXCIpID09IFxcXCIxXFxcIjtcXG5kLnB1c2goe1xcbiAgICB0aXRsZTogdmlwID8gXFxcIuasoui/juaCqO+8jOWwiui0teeahOS8muWRmO+8gVxcXCIgOiBcXFwi5oKo6L+Y5LiN5piv5Lya5ZGYXFxcIixcXG4gICAgdXJsOiAkKFxcXCIjbm9Mb2FkaW5nI1xcXCIpLmxhenlSdWxlKCgpID0+IHtcXG4gICAgICAgIGNvbmZpcm0oe1xcbiAgICAgICAgICAgIHRpdGxlOiBcXFwi6K+05piOXFxcIixcXG4gICAgICAgICAgICBjb250ZW50OiBcXFwi5pys5bel5YW3566x5omA5pyJ5Yqf6IO95YWN6LS55peg5bm/5ZGK5L2/55So77yM5Li65r+A5Yqx5L2c6ICF5LiN5pat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AgICAgICAgICAgICAgdGl0bGU6IFxcXCLmuKnppqjmj5DnpLpcXFwiLFxcbiAgICAgICAgICAgICAgICBjb250ZW50OiBcXFwi5b2T5YmN5pyq5a+85YWl5omp5bGV5o+S5Lu277yM54K55Ye75LiL5pa556Gu5a6a5oyJ6ZKu5a+85YWlXFxcIixcXG4gICAgICAgICAgICAgICAgY29uZmlybTogJC50b1N0cmluZygoKSA9PiB7XFxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gXFxcIua1t+mYlOinhueVjOmmlumhtemikemBk+inhOWImeOAkOacrOWcsOi1hOa6kOeuoeeQhuOAke+/pWhvbWVfcnVsZV91cmzvv6VodHRwOi8vaGlrZXIubm9raWEucHJlc3MvaGlrZXJ1bGUvcnVsZWxpc3QuanNvbj9pZD0zNTU5XFxcIlxcbiAgICAgICAgICAgICAgICB9KVxcbiAgICAgICAgICAgIH0pO1xcbiAgICAgICAgICAgIHJldHVybiBcXFwiaGlrZXI6Ly9lbXB0eVxcXCJcXG4gICAgICAgIH1cXG4gICAgfSksXFxuICAgIGNvbF90eXBlOiBcXFwiY2FyZF9waWNfMlxcXCIsXFxuICAgIHBpY191cmw6IFxcXCJoaWtlcjovL2ltYWdlcy9ob21lX3BpYzRcXFwiLFxcbn0pO1xcbmQucHVzaCh7XFxuICAgIHRpdGxlOiBcXFwiZXB1YumYheivu+WZqFxcXCIsXFxuICAgIHVybDogXFxcImZpbGVTZWxlY3Q6Ly9cXFwiICsgJC50b1N0cmluZygoKSA9PiB7XFxuICAgICAgICBjb25zdCBGaWxlID0gamF2YS5pby5GaWxlO1xcbiAgICAgICAgbGV0IGphdmFJbXBvcnQgPSBuZXcgSmF2YUltcG9ydGVyKCk7XFxuICAgICAgICBqYXZhSW1wb3J0LmltcG9ydFBhY2thZ2UoXFxuICAgICAgICAgICAgUGFja2FnZXMuY29tLmV4YW1wbGUuaGlrZXJ2aWV3LnV0aWxzXFxuICAgICAgICApO1xcbiAgICAgICAgd2l0aChqYXZhSW1wb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ICAgICAgcmV0dXJuIFxcXCJoaWtlcjovL2hvbWVAV2ViZGF2XFxcIjtcXG4gICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgY29uZmlybSh7XFxuICAgICAgICAgICAgICAgIHRpdGxlOiBcXFwi5rip6aao5o+Q56S6XFxcIixcXG4gICAgICAgICAgICAgICAgY29udGVudDogXFxcIuW9k+WJjeacquWvvOWFpeaJqeWxleaPkuS7tu+8jOeCueWHu+S4i+aWueehruWumuaMiemSruWvvOWFpVxcXCIsXFxuICAgICAgICAgICAgICAgIGNvbmZpcm06ICQudG9TdHJpbmcoKCkgPT4ge1xcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIFxcXCLmtbfpmJTop4bnlYzpppbpobXpopHpgZPop4TliJnjgJBXZWJkYXbjgJHvv6Vob21lX3J1bGVfdXJs77+laHR0cDovL2hpa2VyLm5va2lhLnByZXNzL2hpa2VydWxlL3J1bGVsaXN0Lmpzb24/aWQ9NTIxMFxcXCJcXG4gICAgICAgICAgICAgICAgfSlcXG4gICAgICAgICAgICB9KTtcXG4gICAgICAgICAgICByZXR1cm4gXFxcImhpa2VyOi8vZW1wdHlcXFwiXFxuICAgICAgICB9XFxuICAgIH0pLFxcbiAgICBjb2xfdHlwZTogXFxcImNhcmRfcGljXzJfMlxcXCIsXFxuICAgIHBpY191cmw6IFxcXCJoaWtlcjovL2ltYWdlcy9ob21lX3BpYzJcXFwiXFxufSk7XFxuZC5wdXNoKHtcXG4gICAgdGl0bGU6IFxcXCLlm77niYfmj5Dlj5blmahcXFwiLFxcbiAgICB1cmw6IFxcXCJoaWtlcjovL3BhZ2UvcGljXFxcIixcXG4gICAgY29sX3R5cGU6IFxcXCJ0ZXh0X2NlbnRlcl8xXFxcIixcXG4gICAgZGVzYzogXFxcIlxcXCIsXFxuICAgIHBpY191cmw6IFxcXCJcXFwiXFxufSk7XFxuXFxuZC5wdXNoKHtcXG4gICAgdGl0bGU6IFxcXCLigJzigJzigJ3igJ08c3Bhbi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9uIGdldGltZ3MoKSB7XFxcXG4gICAgICAgICAgICAgICAgdmFyIHZpZGVvRWxlbWVudHMgPSBkb2N1bWVudC5nZXRFbGVtZW50c0J5VGFnTmFtZShcXFxcXFxcImltZ1xcXFxcXFwiKTtcXFxcbiAgICAgICAgICAgICAgICBpZiAodmlkZW9FbGVtZW50cyA9PSBudWxsKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBbXTtcXFxcbiAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgbGV0IHVybHMgPSBbXTtcXFxcbiAgICAgICAgICAgICAgICBmb3IgKGxldCBpID0gMDsgaSA8IHZpZGVvRWxlbWVudHMubGVuZ3RoOyBpKyspIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgaWYgKHZpZGVvRWxlbWVudHNbaV0ud2lkdGggPiA3MCAmJiB2aWRlb0VsZW1lbnRzW2ldLmhlaWdodCA+IDcwKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBjb25zdCBzcmMgPSB2aWRlb0VsZW1lbnRzW2ldLnNyYztcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmIChzcmMgPT0gbnVsbCB8fCBzcmMubGVuZ3RoIDwgNSB8fCB1cmxzLmluY2x1ZGVzKHNyYykgfHwgc3JjLmluZGV4T2YoXFxcXFxcXCJkYXRhOlxcXFxcXFwiKSA9PSAwKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgY29udGludWU7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAvL2xvZyhzcmMpO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgdXJscy5wdXNoKG5ldyBVUkwoc3JjKS50b1N0cmluZygpKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgfVxcXFxuICAgICAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgICAgICByZXR1cm4gdXJscztcXFxcbiAgICAgICAgICAgIH1cXFxcblxcXFxuICAgICAgICAgICAgZnVuY3Rpb24gY2hlY2soKSB7XFxcXG4gICAgICAgICAgICAgICAgdHJ5IHtcXFxcbiAgICAgICAgICAgICAgICAgICAgbGV0IHVybHMgPSBnZXRpbWdzKCk7XFxcXG4gICAgICAgICAgICAgICAgICAgIC8vZmJhLmxvZyhcXFxcXFxcImdldGltZ3PvvJpcXFxcXFxcIiArIHVybHMubGVuZ3RoKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgaWYgKHdpbmRvdy5jaGVja2VkVXJscyA9PSBudWxsKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICB3aW5kb3cuY2hlY2tlZFVybHMgPSBbXTtcXFxcbiAgICAgICAgICAgICAgICAgICAgfVxcXFxuICAgICAgICAgICAgICAgICAgICBsZXQgY2hlY2tlZFVybHMgPSB3aW5kb3cuY2hlY2tlZFVybHM7XFxcXG4gICAgICAgICAgICAgICAgICAgIHVybHMgPSB1cmxzLmZpbHRlcihpdCA9PiB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gIWNoZWNrZWRVcmxzLmluY2x1ZGVzKGl0KVxcXFxuICAgICAgICAgICAgICAgICAgICB9KTtcXFxcblxcXFxuICAgICAgICAgICAgICAgICAgICBpZiAodXJscy5sZW5ndGggPiAwKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBsZXQgcGljcyA9IHVybHMuZmlsdGVyKGl0ID0+IGl0ICE9IG51bGwgJiYgaXQgIT0gXFxcXFxcXCJcXFxcXFxcIilcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAubWFwKGl0ID0+IHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgbGV0IHUgPSBmYmEuZ2V0SGVhZGVyVXJsKGl0KTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgbGV0IHV1ID0gdS5zcGxpdChcXFxcXFxcIjtcXFxcXFxcIik7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGxldCBwaWMgPSB1O1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAodXUubGVuZ3RoID4gMSkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgbGV0IHUxID0gdXVbMF07XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBsZXQgdTIgPSB1dVsxXS5zbGljZSgxLCAtMSkuc3BsaXQoXFxcXFxcXCImJlxcXFxcXFwiKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGxldCByZWZlcmVyID0gbnVsbDtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGxldCB1YSA9IG51bGw7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBsZXQgY29va2llMCA9IG51bGw7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBmb3IgKGxldCBpaSBvZiB1Mikge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGxldCBpdDIgPSBpaS5zcGxpdChcXFxcXFxcIkBcXFxcXFxcIik7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgKGl0MlswXSA9PSBcXFxcXFxcIlJlZmVyZXJcXFxcXFxcIikge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZWZlcmVyID0gaXQyWzFdLnJlcGxhY2UoL++8m++8my9nLCBcXFxcXFxcIjtcXFxcXFxcIik7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChpdDJbMF0gPT0gXFxcXFxcXCJVc2VyLUFnZW50XFxcXFxcXCIpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdWEgPSBpdDJbMV0ucmVwbGFjZSgv77yb77ybL2csIFxcXFxcXFwiO1xcXFxcXFwiKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgKGl0MlswXSA9PSBcXFxcXFxcIkNvb2tpZVxcXFxcXFwiKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNvb2tpZTAgPSBpdDJbMV0ucmVwbGFjZSgv77yb77ybL2csIFxcXFxcXFwiO1xcXFxcXFwiKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBwaWMgPSB1MTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChyZWZlcmVyKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcGljID0gcGljICsgXFxcXFxcXCJAUmVmZXJlcj1cXFxcXFxcIiArIHJlZmVyZXI7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAodWEpIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBwaWMgPSBwaWMgKyBcXFxcXFxcIkBVc2VyLUFnZW50PVxcXFxcXFwiICsgdWE7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAoY29va2llMCkge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHBpYyA9IHBpYyArIFxcXFxcXFwiQENvb2tpZT1cXFxcXFxcIiArIGNvb2tpZTBcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cXFxcblxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcGljID0gaXQ7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHBpYzogcGljLFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdXJsOiB1XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9KTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGZiYS5sb2cocGljcy5sZW5ndGggKyBcXFxcXFxcIlxcXFxcXFwiKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIGZiYS5wYXJzZUxhenlSdWxlQXN5bmMoJCQkKCkubGF6eVJ1bGUoKHVybHMpID0+IHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAvL2xvZyh1cmxzKTtcXFxcblxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGxldCBhcnIgPSB1cmxzLm1hcChpdCA9PiB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB0aXRsZTogXFxcXFxcXCJcXFxcXFxcIixcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVybDogaXQucGljLFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcGljX3VybDogaXQucGljLFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY29sX3R5cGU6IFxcXFxcXFwiY2FyZF9waWNfM1xcXFxcXFwiLFxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZXh0cmE6IHtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBjbHM6IFxcXFxcXFwicGljc1xcXFxcXFwiXFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9KTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBhZGRJdGVtQmVmb3JlKFxcXFxcXFwicGljX2xpbmVcXFxcXFxcIiwgYXJyKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0sIHBpY3MpLCBmdW5jdGlvbigpIHtcXFxcblxcXFxuICAgICAgICAgICAgICAgICAgICAgICAgfSk7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICBmb3IgKGxldCBpdCBvZiB1cmxzKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgd2luZG93LmNoZWNrZWRVcmxzLnB1c2goaXQpO1xcXFxuICAgICAgICAgICAgICAgICAgICAgICAgfVxcXFxuICAgICAgICAgICAgICAgICAgICB9XFxcXG5cXFxcbiAgICAgICAgICAgICAgICB9IGNhdGNoIChlKSB7XFxcXG4gICAgICAgICAgICAgICAgICAgIGZiYS5sb2coZS50b1N0cmluZygpKTtcXFxcbiAgICAgICAgICAgICAgICB9XFxcXG4gICAgICAgICAgICAgICAgc2V0VGltZW91dChjaGVjaywgMzAwKTtcXFxcbiAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgIGNoZWNrKCk7XFxcXG4gICAgICAgIH0pXFxcXG4gICAgfVxcXFxufSk7XFxcXG5cXFxcblxcXFxuZC5wdXNoKHtcXFxcbiAgICB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