-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
380 lines (332 loc) · 62.7 KB
/
index.html
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
<!DOCTYPE html><html lang="zh-CN" data-theme="light"><head><meta charset="UTF-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"><title>人话翻译机 - 有限的时间,先限的可能</title><meta name="author" content="潇洒"><meta name="copyright" content="潇洒"><meta name="format-detection" content="telephone=no"><meta name="theme-color" content="#ffffff"><meta name="description" content="吾日三省吾身,吾没错">
<meta property="og:type" content="website">
<meta property="og:title" content="人话翻译机">
<meta property="og:url" content="https://liukai.net/index.html">
<meta property="og:site_name" content="人话翻译机">
<meta property="og:description" content="吾日三省吾身,吾没错">
<meta property="og:locale" content="zh_CN">
<meta property="og:image" content="https://liukai.net/images/touxiang.jpeg">
<meta property="article:author" content="潇洒">
<meta name="twitter:card" content="summary">
<meta name="twitter:image" content="https://liukai.net/images/touxiang.jpeg"><link rel="shortcut icon" href="/img/favicon.png"><link rel="canonical" href="https://liukai.net/"><link rel="preconnect" href="//cdn.jsdelivr.net"/><link rel="preconnect" href="//hm.baidu.com"/><link rel="stylesheet" href="/css/index.css"><link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fortawesome/fontawesome-free@6/css/all.min.css" media="print" onload="this.media='all'"><link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fancyapps/ui/dist/fancybox.css" media="print" onload="this.media='all'"><script>var _hmt = _hmt || [];
(function() {
var hm = document.createElement("script");
hm.src = "https://hm.baidu.com/hm.js?added40fbf61be46f3921338ad631294";
var s = document.getElementsByTagName("script")[0];
s.parentNode.insertBefore(hm, s);
})();
</script><script>const GLOBAL_CONFIG = {
root: '/',
algolia: undefined,
localSearch: {"path":"/search.xml","preload":false,"languages":{"hits_empty":"找不到您查询的内容:${query}"}},
translate: undefined,
noticeOutdate: undefined,
highlight: {"plugin":"highlighjs","highlightCopy":true,"highlightLang":true,"highlightHeightLimit":false},
copy: {
success: '复制成功',
error: '复制错误',
noSupport: '浏览器不支持'
},
relativeDate: {
homepage: false,
post: false
},
runtime: '',
date_suffix: {
just: '刚刚',
min: '分钟前',
hour: '小时前',
day: '天前',
month: '个月前'
},
copyright: undefined,
lightbox: 'fancybox',
Snackbar: undefined,
source: {
justifiedGallery: {
js: 'https://cdn.jsdelivr.net/npm/flickr-justified-gallery@2/dist/fjGallery.min.js',
css: 'https://cdn.jsdelivr.net/npm/flickr-justified-gallery@2/dist/fjGallery.min.css'
}
},
isPhotoFigcaption: false,
islazyload: false,
isAnchor: false
}</script><script id="config-diff">var GLOBAL_CONFIG_SITE = {
title: '人话翻译机',
isPost: false,
isHome: true,
isHighlightShrink: false,
isToc: false,
postUpdate: '2024-01-12 16:00:28'
}</script><noscript><style type="text/css">
#nav {
opacity: 1
}
.justified-gallery img {
opacity: 1
}
#recent-posts time,
#post-meta time {
display: inline !important
}
</style></noscript><script>(win=>{
win.saveToLocal = {
set: function setWithExpiry(key, value, ttl) {
if (ttl === 0) return
const now = new Date()
const expiryDay = ttl * 86400000
const item = {
value: value,
expiry: now.getTime() + expiryDay,
}
localStorage.setItem(key, JSON.stringify(item))
},
get: function getWithExpiry(key) {
const itemStr = localStorage.getItem(key)
if (!itemStr) {
return undefined
}
const item = JSON.parse(itemStr)
const now = new Date()
if (now.getTime() > item.expiry) {
localStorage.removeItem(key)
return undefined
}
return item.value
}
}
win.getScript = url => new Promise((resolve, reject) => {
const script = document.createElement('script')
script.src = url
script.async = true
script.onerror = reject
script.onload = script.onreadystatechange = function() {
const loadState = this.readyState
if (loadState && loadState !== 'loaded' && loadState !== 'complete') return
script.onload = script.onreadystatechange = null
resolve()
}
document.head.appendChild(script)
})
win.activateDarkMode = function () {
document.documentElement.setAttribute('data-theme', 'dark')
if (document.querySelector('meta[name="theme-color"]') !== null) {
document.querySelector('meta[name="theme-color"]').setAttribute('content', '#0d0d0d')
}
}
win.activateLightMode = function () {
document.documentElement.setAttribute('data-theme', 'light')
if (document.querySelector('meta[name="theme-color"]') !== null) {
document.querySelector('meta[name="theme-color"]').setAttribute('content', '#ffffff')
}
}
const t = saveToLocal.get('theme')
if (t === 'dark') activateDarkMode()
else if (t === 'light') activateLightMode()
const asideStatus = saveToLocal.get('aside-status')
if (asideStatus !== undefined) {
if (asideStatus === 'hide') {
document.documentElement.classList.add('hide-aside')
} else {
document.documentElement.classList.remove('hide-aside')
}
}
const detectApple = () => {
if(/iPad|iPhone|iPod|Macintosh/.test(navigator.userAgent)){
document.documentElement.classList.add('apple')
}
}
detectApple()
})(window)</script><meta name="generator" content="Hexo 5.4.2"></head><body><div id="web_bg"></div><div id="sidebar"><div id="menu-mask"></div><div id="sidebar-menus"><div class="avatar-img is-center"><img src="/images/touxiang.jpeg" onerror="onerror=null;src='/img/friend_404.gif'" alt="avatar"/></div><div class="sidebar-site-data site-data is-center"><a href="/archives/"><div class="headline">文章</div><div class="length-num">294</div></a><a href="/tags/"><div class="headline">标签</div><div class="length-num">445</div></a><a href="/categories/"><div class="headline">分类</div><div class="length-num">176</div></a></div><hr/><div class="menus_items"><div class="menus_item"><a class="site-page" href="/"><i class="fa-fw fas fa-home"></i><span> 首页</span></a></div><div class="menus_item"><a class="site-page group" href="javascript:void(0);"><i class="fa-fw fas fa-list"></i><span> Java</span><i class="fas fa-chevron-down"></i></a><ul class="menus_item_child"><li><a class="site-page child" href="/categories/java"><i class="fa-fw fas fa-folder-open"></i><span> java</span></a></li><li><a class="site-page child" href="/categories/java/reflect"><i class="fa-fw fas fa-folder-open"></i><span> 反射</span></a></li><li><a class="site-page child" href="/categories/java/annotation"><i class="fa-fw fas fa-folder-open"></i><span> 注解</span></a></li><li><a class="site-page child" href="/categories/java/jvm"><i class="fa-fw fas fa-folder-open"></i><span> JVM</span></a></li><li><a class="site-page child" href="/categories/java/concurrent"><i class="fa-fw fas fa-folder-open"></i><span> 并发</span></a></li><li><a class="site-page child" href="/categories/java/lambda"><i class="fa-fw fas fa-folder-open"></i><span> functional</span></a></li><li><a class="site-page child" href="/categories/java/nio"><i class="fa-fw fas fa-folder-open"></i><span> nio</span></a></li><li><a class="site-page child" href="/categories/java/netty"><i class="fa-fw fas fa-folder-open"></i><span> netty</span></a></li><li><a class="site-page child" href="/categories/java/spring"><i class="fa-fw fas fa-folder-open"></i><span> Spring</span></a></li><li><a class="site-page child" href="/categories/spring/springboot"><i class="fa-fw fas fa-folder-open"></i><span> Spring Boot</span></a></li><li><a class="site-page child" href="/categories/spring/springcloud"><i class="fa-fw fas fa-folder-open"></i><span> Spring Cloud</span></a></li><li><a class="site-page child" href="/categories/java/maven"><i class="fa-fw fas fa-folder-open"></i><span> maven</span></a></li><li><a class="site-page child" href="/categories/java/gradle"><i class="fa-fw fas fa-folder-open"></i><span> gradle</span></a></li></ul></div><div class="menus_item"><a class="site-page group" href="javascript:void(0);"><i class="fa-fw fas fa-list"></i><span> go</span><i class="fas fa-chevron-down"></i></a><ul class="menus_item_child"><li><a class="site-page child" href="/categories/go"><i class="fa-fw fas fa-folder-open"></i><span> go</span></a></li></ul></div><div class="menus_item"><a class="site-page group" href="javascript:void(0);"><i class="fa-fw fas fa-list"></i><span> rust</span><i class="fas fa-chevron-down"></i></a><ul class="menus_item_child"><li><a class="site-page child" href="/categories/rust"><i class="fa-fw fas fa-folder-open"></i><span> rust</span></a></li></ul></div><div class="menus_item"><a class="site-page group" href="javascript:void(0);"><i class="fa-fw fas fa-list"></i><span> 工程化</span><i class="fas fa-chevron-down"></i></a><ul class="menus_item_child"><li><a class="site-page child" href="/categories/git"><i class="fa-fw fas fa-folder-open"></i><span> git</span></a></li><li><a class="site-page child" href="/categories/devops"><i class="fa-fw fas fa-folder-open"></i><span> devops</span></a></li><li><a class="site-page child" href="/categories/design"><i class="fa-fw fas fa-folder-open"></i><span> design</span></a></li></ul></div><div class="menus_item"><a class="site-page group" href="javascript:void(0);"><i class="fa-fw fas fa-list"></i><span> 算法</span><i class="fas fa-chevron-down"></i></a><ul class="menus_item_child"><li><a class="site-page child" href="/categories/algorithm"><i class="fa-fw fas fa-folder-open"></i><span> algorithm</span></a></li><li><a class="site-page child" href="/categories/leetcode"><i class="fa-fw fas fa-folder-open"></i><span> LeetCode</span></a></li></ul></div><div class="menus_item"><a class="site-page group" href="javascript:void(0);"><i class="fa-fw fas fa-list"></i><span> blockchain</span><i class="fas fa-chevron-down"></i></a><ul class="menus_item_child"><li><a class="site-page child" href="/categories/blockchain/"><i class="fa-fw fas fa-folder-open"></i><span> Blockchain</span></a></li><li><a class="site-page child" href="/categories/blockchain/bitcoin"><i class="fa-fw fas fa-folder-open"></i><span> Bitcoin</span></a></li><li><a class="site-page child" href="/categories/blockchain/ethereum"><i class="fa-fw fas fa-folder-open"></i><span> Ethereum</span></a></li><li><a class="site-page child" href="/categories/eth/eip"><i class="fa-fw fas fa-folder-open"></i><span> EIP</span></a></li><li><a class="site-page child" href="/categories/tron"><i class="fa-fw fas fa-folder-open"></i><span> Tron</span></a></li><li><a class="site-page child" href="/categories/tendermint"><i class="fa-fw fas fa-folder-open"></i><span> Cosmos</span></a></li></ul></div><div class="menus_item"><a class="site-page group" href="javascript:void(0);"><i class="fa-fw fas fa-list"></i><span> Linux</span><i class="fas fa-chevron-down"></i></a><ul class="menus_item_child"><li><a class="site-page child" href="/categories/linux"><i class="fa-fw fas fa-folder-open"></i><span> linux</span></a></li><li><a class="site-page child" href="/categories/linux/shell"><i class="fa-fw fas fa-folder-open"></i><span> shell</span></a></li><li><a class="site-page child" href="/categories/linux/vim"><i class="fa-fw fas fa-folder-open"></i><span> vim</span></a></li></ul></div><div class="menus_item"><a class="site-page group" href="javascript:void(0);"><i class="fa-fw fas fa-list"></i><span> 存储</span><i class="fas fa-chevron-down"></i></a><ul class="menus_item_child"><li><a class="site-page child" href="/categories/mysql"><i class="fa-fw fas fa-folder-open"></i><span> mysql</span></a></li><li><a class="site-page child" href="/categories/redis"><i class="fa-fw fas fa-folder-open"></i><span> redis</span></a></li><li><a class="site-page child" href="/categories/leveldb"><i class="fa-fw fas fa-folder-open"></i><span> leveldb</span></a></li></ul></div><div class="menus_item"><a class="site-page group" href="javascript:void(0);"><i class="fa-fw fas fa-list"></i><span> 容器化</span><i class="fas fa-chevron-down"></i></a><ul class="menus_item_child"><li><a class="site-page child" href="/categories/docker"><i class="fa-fw fas fa-folder-open"></i><span> docker</span></a></li><li><a class="site-page child" href="/categories/k8s"><i class="fa-fw fas fa-folder-open"></i><span> k8s</span></a></li></ul></div><div class="menus_item"><a class="site-page group" href="javascript:void(0);"><i class="fa-fw fas fa-list"></i><span> 分类归档</span><i class="fas fa-chevron-down"></i></a><ul class="menus_item_child"><li><a class="site-page child" href="/archives/"><i class="fa-fw fas fa-archive"></i><span> 归档</span></a></li><li><a class="site-page child" href="/tags/"><i class="fa-fw fas fa-tags"></i><span> 标签</span></a></li><li><a class="site-page child" href="/categories/"><i class="fa-fw fas fa-folder-open"></i><span> 分类</span></a></li></ul></div><div class="menus_item"><a class="site-page" href="/link/"><i class="fa-fw fas fa-link"></i><span> 链接</span></a></div><div class="menus_item"><a class="site-page" href="/messageboard/"><i class="fa-fw fas fa-link"></i><span> 留言板</span></a></div><div class="menus_item"><a class="site-page" href="/about/"><i class="fa-fw fas fa-heart"></i><span> 关于</span></a></div></div></div></div><div class="page" id="body-wrap"><header class="full_page" id="page-header" style="background-image: url('/images/bg.jpeg')"><nav id="nav"><span id="blog_name"><a id="site-name" href="/">人话翻译机</a></span><div id="menus"><div id="search-button"><a class="site-page social-icon search"><i class="fas fa-search fa-fw"></i><span> 搜索</span></a></div><div class="menus_items"><div class="menus_item"><a class="site-page" href="/"><i class="fa-fw fas fa-home"></i><span> 首页</span></a></div><div class="menus_item"><a class="site-page group" href="javascript:void(0);"><i class="fa-fw fas fa-list"></i><span> Java</span><i class="fas fa-chevron-down"></i></a><ul class="menus_item_child"><li><a class="site-page child" href="/categories/java"><i class="fa-fw fas fa-folder-open"></i><span> java</span></a></li><li><a class="site-page child" href="/categories/java/reflect"><i class="fa-fw fas fa-folder-open"></i><span> 反射</span></a></li><li><a class="site-page child" href="/categories/java/annotation"><i class="fa-fw fas fa-folder-open"></i><span> 注解</span></a></li><li><a class="site-page child" href="/categories/java/jvm"><i class="fa-fw fas fa-folder-open"></i><span> JVM</span></a></li><li><a class="site-page child" href="/categories/java/concurrent"><i class="fa-fw fas fa-folder-open"></i><span> 并发</span></a></li><li><a class="site-page child" href="/categories/java/lambda"><i class="fa-fw fas fa-folder-open"></i><span> functional</span></a></li><li><a class="site-page child" href="/categories/java/nio"><i class="fa-fw fas fa-folder-open"></i><span> nio</span></a></li><li><a class="site-page child" href="/categories/java/netty"><i class="fa-fw fas fa-folder-open"></i><span> netty</span></a></li><li><a class="site-page child" href="/categories/java/spring"><i class="fa-fw fas fa-folder-open"></i><span> Spring</span></a></li><li><a class="site-page child" href="/categories/spring/springboot"><i class="fa-fw fas fa-folder-open"></i><span> Spring Boot</span></a></li><li><a class="site-page child" href="/categories/spring/springcloud"><i class="fa-fw fas fa-folder-open"></i><span> Spring Cloud</span></a></li><li><a class="site-page child" href="/categories/java/maven"><i class="fa-fw fas fa-folder-open"></i><span> maven</span></a></li><li><a class="site-page child" href="/categories/java/gradle"><i class="fa-fw fas fa-folder-open"></i><span> gradle</span></a></li></ul></div><div class="menus_item"><a class="site-page group" href="javascript:void(0);"><i class="fa-fw fas fa-list"></i><span> go</span><i class="fas fa-chevron-down"></i></a><ul class="menus_item_child"><li><a class="site-page child" href="/categories/go"><i class="fa-fw fas fa-folder-open"></i><span> go</span></a></li></ul></div><div class="menus_item"><a class="site-page group" href="javascript:void(0);"><i class="fa-fw fas fa-list"></i><span> rust</span><i class="fas fa-chevron-down"></i></a><ul class="menus_item_child"><li><a class="site-page child" href="/categories/rust"><i class="fa-fw fas fa-folder-open"></i><span> rust</span></a></li></ul></div><div class="menus_item"><a class="site-page group" href="javascript:void(0);"><i class="fa-fw fas fa-list"></i><span> 工程化</span><i class="fas fa-chevron-down"></i></a><ul class="menus_item_child"><li><a class="site-page child" href="/categories/git"><i class="fa-fw fas fa-folder-open"></i><span> git</span></a></li><li><a class="site-page child" href="/categories/devops"><i class="fa-fw fas fa-folder-open"></i><span> devops</span></a></li><li><a class="site-page child" href="/categories/design"><i class="fa-fw fas fa-folder-open"></i><span> design</span></a></li></ul></div><div class="menus_item"><a class="site-page group" href="javascript:void(0);"><i class="fa-fw fas fa-list"></i><span> 算法</span><i class="fas fa-chevron-down"></i></a><ul class="menus_item_child"><li><a class="site-page child" href="/categories/algorithm"><i class="fa-fw fas fa-folder-open"></i><span> algorithm</span></a></li><li><a class="site-page child" href="/categories/leetcode"><i class="fa-fw fas fa-folder-open"></i><span> LeetCode</span></a></li></ul></div><div class="menus_item"><a class="site-page group" href="javascript:void(0);"><i class="fa-fw fas fa-list"></i><span> blockchain</span><i class="fas fa-chevron-down"></i></a><ul class="menus_item_child"><li><a class="site-page child" href="/categories/blockchain/"><i class="fa-fw fas fa-folder-open"></i><span> Blockchain</span></a></li><li><a class="site-page child" href="/categories/blockchain/bitcoin"><i class="fa-fw fas fa-folder-open"></i><span> Bitcoin</span></a></li><li><a class="site-page child" href="/categories/blockchain/ethereum"><i class="fa-fw fas fa-folder-open"></i><span> Ethereum</span></a></li><li><a class="site-page child" href="/categories/eth/eip"><i class="fa-fw fas fa-folder-open"></i><span> EIP</span></a></li><li><a class="site-page child" href="/categories/tron"><i class="fa-fw fas fa-folder-open"></i><span> Tron</span></a></li><li><a class="site-page child" href="/categories/tendermint"><i class="fa-fw fas fa-folder-open"></i><span> Cosmos</span></a></li></ul></div><div class="menus_item"><a class="site-page group" href="javascript:void(0);"><i class="fa-fw fas fa-list"></i><span> Linux</span><i class="fas fa-chevron-down"></i></a><ul class="menus_item_child"><li><a class="site-page child" href="/categories/linux"><i class="fa-fw fas fa-folder-open"></i><span> linux</span></a></li><li><a class="site-page child" href="/categories/linux/shell"><i class="fa-fw fas fa-folder-open"></i><span> shell</span></a></li><li><a class="site-page child" href="/categories/linux/vim"><i class="fa-fw fas fa-folder-open"></i><span> vim</span></a></li></ul></div><div class="menus_item"><a class="site-page group" href="javascript:void(0);"><i class="fa-fw fas fa-list"></i><span> 存储</span><i class="fas fa-chevron-down"></i></a><ul class="menus_item_child"><li><a class="site-page child" href="/categories/mysql"><i class="fa-fw fas fa-folder-open"></i><span> mysql</span></a></li><li><a class="site-page child" href="/categories/redis"><i class="fa-fw fas fa-folder-open"></i><span> redis</span></a></li><li><a class="site-page child" href="/categories/leveldb"><i class="fa-fw fas fa-folder-open"></i><span> leveldb</span></a></li></ul></div><div class="menus_item"><a class="site-page group" href="javascript:void(0);"><i class="fa-fw fas fa-list"></i><span> 容器化</span><i class="fas fa-chevron-down"></i></a><ul class="menus_item_child"><li><a class="site-page child" href="/categories/docker"><i class="fa-fw fas fa-folder-open"></i><span> docker</span></a></li><li><a class="site-page child" href="/categories/k8s"><i class="fa-fw fas fa-folder-open"></i><span> k8s</span></a></li></ul></div><div class="menus_item"><a class="site-page group" href="javascript:void(0);"><i class="fa-fw fas fa-list"></i><span> 分类归档</span><i class="fas fa-chevron-down"></i></a><ul class="menus_item_child"><li><a class="site-page child" href="/archives/"><i class="fa-fw fas fa-archive"></i><span> 归档</span></a></li><li><a class="site-page child" href="/tags/"><i class="fa-fw fas fa-tags"></i><span> 标签</span></a></li><li><a class="site-page child" href="/categories/"><i class="fa-fw fas fa-folder-open"></i><span> 分类</span></a></li></ul></div><div class="menus_item"><a class="site-page" href="/link/"><i class="fa-fw fas fa-link"></i><span> 链接</span></a></div><div class="menus_item"><a class="site-page" href="/messageboard/"><i class="fa-fw fas fa-link"></i><span> 留言板</span></a></div><div class="menus_item"><a class="site-page" href="/about/"><i class="fa-fw fas fa-heart"></i><span> 关于</span></a></div></div><div id="toggle-menu"><a class="site-page"><i class="fas fa-bars fa-fw"></i></a></div></div></nav><div id="site-info"><h1 id="site-title">人话翻译机</h1><div id="site-subtitle"><span id="subtitle"></span></div><div id="site_social_icons"><a class="social-icon" href="https://github.com/forfreeday" target="_blank" title="Github"><i class="fab fa-github"></i></a><a class="social-icon" href="/atom.xml" target="_blank" title="RSS"><i class="fas fa-rss-square"></i></a></div></div><div id="scroll-down"><i class="fas fa-angle-down scroll-down-effects"></i></div></header><main class="layout" id="content-inner"><div class="recent-posts" id="recent-posts"><div class="recent-post-item"><div class="post_cover left"><a href="/posts/752261e8.html" title="ETH-EIP-4337"><img class="post_bg" src="/images/cover/cover-eth.jpeg" onerror="this.onerror=null;this.src='/img/404.jpg'" alt="ETH-EIP-4337"></a></div><div class="recent-post-info"><a class="article-title" href="/posts/752261e8.html" title="ETH-EIP-4337">ETH-EIP-4337</a><div class="article-meta-wrap"><span class="post-meta-date"><i class="far fa-calendar-alt"></i><span class="article-meta-label">发表于</span><time datetime="2023-11-20T15:40:48.000Z" title="发表于 2023-11-20 23:40:48">2023-11-20</time></span><span class="article-meta"><span class="article-meta-separator">|</span><i class="fas fa-inbox"></i><a class="article-meta__categories" href="/categories/blockchain/">blockchain</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/ethereum/">ethereum</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/eth/">eth</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/eth/4337/">4337</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/ethereum/eip/">eip</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/blockchain/eth/">eth</a></span></div><div class="content">EIP-4337首先声明以下几点:
用户钱包都采用 contract 实现,每个用户对应一个合约地址
用户初次发起交易时,会自动创建合约
用户可以指定一个 payment 合约地址,用该地址中的余额支付手续费
整体架构
ERC-4337 定义了一个基于 ETH 的账户抽象标准,以下为简单介绍。
UserOperation:类比原生交易,不过为另一种格式的交易,比如支持携带自定义签名、交易的基础信息(gas、sender、limit等)
UserOperation mempool:专门的一些节点搭建的P2P网络构成的交易缓存池,用于接受UserOperation
Bundler:负责收集、校验、打包UserOperation,并将打包好的交易发送给产块人,交易上链的费用由Bundler支付,但是Bundler会从UserOperation中获取用户的手续费作为奖励。
Note:本质上是启动了一个独立于主链的P2P网络,用于接收抽象账户的交易并打包上链。
https://github.com/ethereum/EIPs/blob/3fd65b1a782912bfc18cb975c6 ...</div></div></div><div class="recent-post-item"><div class="post_cover right"><a href="/posts/819a1e2d.html" title="Cosmos 普通交易手续费调研"><img class="post_bg" src="/images/cover/cover-cosmos.svg" onerror="this.onerror=null;this.src='/img/404.jpg'" alt="Cosmos 普通交易手续费调研"></a></div><div class="recent-post-info"><a class="article-title" href="/posts/819a1e2d.html" title="Cosmos 普通交易手续费调研">Cosmos 普通交易手续费调研</a><div class="article-meta-wrap"><span class="post-meta-date"><i class="far fa-calendar-alt"></i><span class="article-meta-label">发表于</span><time datetime="2023-09-18T09:19:26.000Z" title="发表于 2023-09-18 17:19:26">2023-09-18</time></span><span class="article-meta"><span class="article-meta-separator">|</span><i class="fas fa-inbox"></i><a class="article-meta__categories" href="/categories/blockchain/">blockchain</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/blockchain/cosmos/">cosmos</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/cosmos/">cosmos</a></span></div><div class="content">背景分析 cosmos 的交易手续费的实现细节,以了解其实现手续费模型用于实现参考。在 cosmos 中,gas 用于跟踪执行期间的资源消耗。普通交易消耗的也是 gas。gas 通常在对存储进行读取和写入时使用,但如果需要执行昂贵的计算,也可以使用。
重点关注的两件事情:
如果计算、校验,即交易做了哪些操作,是否合法
每个操作的收费是如何定价的,包括:读取、存储、计算。
tx 会产生所有状态读取/写入、签名验证以及与 tx 大小成比例的成本的 gas 成本。运营商在启动节点时会设定最低 gas 价格。
需要消耗 gas的交易类型每个交易在执行过程中都会消耗一定数量的Gas,该Gas用于跟踪执行过程中的资源消耗。在Cosmos SDK应用程序中,交易可以是发送消息(Message)的操作,例如
发送代币
执行智能合约
当执行这些消息时,相关的Gas会被消耗,并且可能会生成相应的费用(Fees)。
请注意,Gas的消耗和费用的生成通常由应用程序开发者定义和管理,可以根据具体的应用逻辑和需求进行设置。
Cosmos SDK提供了Gas计量器(GasMeter)(主要就是通过个是来记录 ...</div></div></div><div class="recent-post-item"><div class="post_cover left"><a href="/posts/82ae354b.html" title="EIP-4844-blob 简单说明"><img class="post_bg" src="/images/cover/cover-eth.jpeg" onerror="this.onerror=null;this.src='/img/404.jpg'" alt="EIP-4844-blob 简单说明"></a></div><div class="recent-post-info"><a class="article-title" href="/posts/82ae354b.html" title="EIP-4844-blob 简单说明">EIP-4844-blob 简单说明</a><div class="article-meta-wrap"><span class="post-meta-date"><i class="far fa-calendar-alt"></i><span class="article-meta-label">发表于</span><time datetime="2023-06-20T15:01:09.000Z" title="发表于 2023-06-20 23:01:09">2023-06-20</time></span><span class="article-meta"><span class="article-meta-separator">|</span><i class="fas fa-inbox"></i><a class="article-meta__categories" href="/categories/blockchain/">blockchain</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/ethereum/">ethereum</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/eth/">eth</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/eth/4844/">4844</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/ethereum/eip/">eip</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/blockchain/eth/">eth</a></span></div><div class="content">简述Blob交易是专门为Rollups而设计的特殊交易。它从 EVM 执行环境中分离出来,并以状态最小化的方式,来促进rollup机制原生嵌入以太坊网络中的实施(包括 optimistic 和 zk)的方式大幅增加交易吞吐量。大白话就是,为了省钱(手续费)专门设计的一种交易类型。
第一阶段EIP4844 主要即为第一个阶段所要完成的工作。主要包括:
1.新增一种交易类型,该交易类型新增了一种字段:blob,为该字段设置单独的gas收费标准,且收费较低,rollup 可采用该字段存储数据
2.新增blob会增大区块数据量,新增历史数据清理功能,超过30天的blob数据可以从节点移除,或迁移至第三方去中心化存储
3.blob与 tx 存储分离,并通过一个 commitment 来进行关联,commitment采用 KZG 算法来实现,KZG 算法可以看做类似 merkle 树的证明算法
4.KZG 在 sharding 中扮演着重要的角色,Rollup 校验中除了 KZG,采用别的验证算法都无法达到很好的效果。
数据结构
1.消息与签名12345678910111213141516clas ...</div></div></div><div class="recent-post-item"><div class="post_cover right"><a href="/posts/4cbcc746.html" title="rust 继承、封装、多态"><img class="post_bg" src="/images/cover/cover-rust.jpeg" onerror="this.onerror=null;this.src='/img/404.jpg'" alt="rust 继承、封装、多态"></a></div><div class="recent-post-info"><a class="article-title" href="/posts/4cbcc746.html" title="rust 继承、封装、多态">rust 继承、封装、多态</a><div class="article-meta-wrap"><span class="post-meta-date"><i class="far fa-calendar-alt"></i><span class="article-meta-label">发表于</span><time datetime="2023-06-01T12:00:03.000Z" title="发表于 2023-06-01 20:00:03">2023-06-01</time></span><span class="article-meta"><span class="article-meta-separator">|</span><i class="fas fa-inbox"></i><a class="article-meta__categories" href="/categories/rust/">rust</a></span></div><div class="content">封装(encapsulation)rust 的封装是基于结构体,而不是对象,结构体就是 rust 的对象,这个和go一样。默认情况下,结构体只有字段。注意,结构体自身被标记为 pub,这样其他代码就可以使用这个结构体,但是在结构体内部的字段仍然是私有的!!!!可以通过实现结构体,来为结构体添加方法,也是和go一样的特性!!
123456789101112131415161718192021222324252627282930313233343536373839404142pub struct AveragedCollection { list: Vec<i32>, average: f64,}impl AveragedCollection { // 这个 self 是不是有熟悉的感觉,python 中大量使用 self pub fn add(&mut self, value: i32) { self.list.push(value); self.update_average( ...</div></div></div><div class="recent-post-item"><div class="post_cover left"><a href="/posts/e5fa7f4c.html" title="以太坊 EIP-4844 简述"><img class="post_bg" src="/images/cover/cover-eth.jpeg" onerror="this.onerror=null;this.src='/img/404.jpg'" alt="以太坊 EIP-4844 简述"></a></div><div class="recent-post-info"><a class="article-title" href="/posts/e5fa7f4c.html" title="以太坊 EIP-4844 简述">以太坊 EIP-4844 简述</a><div class="article-meta-wrap"><span class="post-meta-date"><i class="far fa-calendar-alt"></i><span class="article-meta-label">发表于</span><time datetime="2023-05-23T17:17:21.000Z" title="发表于 2023-05-24 01:17:21">2023-05-24</time></span><span class="article-meta"><span class="article-meta-separator">|</span><i class="fas fa-inbox"></i><a class="article-meta__categories" href="/categories/blockchain/">blockchain</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/ethereum/">ethereum</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/eth/">eth</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/blockchain/ethereum/">ethereum</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/ethereum/eip/">eip</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/blockchain/eth/">eth</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/eth/eip/">eip</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/eip/">eip</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/eip/4844/">4844</a></span></div><div class="content">简述是由Vitalik Buterin和其他来自以太坊生态系统的程序员共同创建的,它关注的是分片技术。
目的EIP-4844的主要目的是在不牺牲去中心化的情况下,降低网络上的gas费用,特别是对rollup解决方案。Arbitrum和Optimism等rollup解决方案可以将gas费用降低100到1000倍。
EIP-4844 提案是作为以太坊2.0更新完成之前的临时解决方案。该提案解释了一种新方法,以帮助划分交易中所需的信息,如验证规则和交易格式,而无需实际实现任何分片。
这是一个很大的EIP,细分下来,需要用很多篇文章才能讲完整个EIP的细节经及EIP-4844要做的事。
背景每个区块 12 秒的出块时间 TPS 大概为 13~30 笔交易左右,但根据目前已知以太坊的 TPS 最高可以达到每秒 45 笔交易。以太坊做为最主流的区块链,这个TPS就非常拉夸,还要号称世界计算机。
所以想要成为 “世界计算机” 的以太坊每秒最多处理 45 笔交易的性能实在是太弱了。所以以太坊迫切需要扩容来解决性能问题。
以太坊由于智能合约的存在,每个交易的内容各不相同,所以每个区块可以处理多少笔交易( ...</div></div></div><div class="recent-post-item"><div class="post_cover right"><a href="/posts/750b0a4e.html" title="使用IDEA开发rust提示file is not included in module tree"><img class="post_bg" src="/images/cover/cover-rust.jpeg" onerror="this.onerror=null;this.src='/img/404.jpg'" alt="使用IDEA开发rust提示file is not included in module tree"></a></div><div class="recent-post-info"><a class="article-title" href="/posts/750b0a4e.html" title="使用IDEA开发rust提示file is not included in module tree">使用IDEA开发rust提示file is not included in module tree</a><div class="article-meta-wrap"><span class="post-meta-date"><i class="far fa-calendar-alt"></i><span class="article-meta-label">发表于</span><time datetime="2023-04-18T18:08:57.000Z" title="发表于 2023-04-19 02:08:57">2023-04-19</time></span><span class="article-meta"><span class="article-meta-separator">|</span><i class="fas fa-inbox"></i><a class="article-meta__categories" href="/categories/rust/">rust</a></span></div><div class="content">问题用了很长一段时间nvim写rust,还没有用IDEA这样的IDE来写rust。就准备用一下,一用发现,还不太会在IDEA上用rust。碰到的第一个问题就是 IDEA 提示:
file is not included in module tree, analysis is not available
fn main 也没有可以运行的按钮,但是命令行使用 cargo run 正常。这个说明应该是IDEA的配置的问题。
解决IDEA 用 rust 我也不熟,猜测应该是跟项目构建有关,就类似IDEA 使用 maven 的构建,也需要对应的设置一样。
右键一下 Cargo.toml看一下,还真有一个Attach Cargo Project这一项,然后只要把项目添加到 IDEA 中就可以:
右键--> Cargo.toml-->Attach Cargo Project
之后运行就正常了,记录一下,虽然是个小问题,但是可能也会帮助到同样出现这个问题的小伙伴。
</div></div></div><div class="recent-post-item"><div class="post_cover left"><a href="/posts/49b9d1d2.html" title="rust-生命周期"><img class="post_bg" src="/images/cover/cover-rust.jpeg" onerror="this.onerror=null;this.src='/img/404.jpg'" alt="rust-生命周期"></a></div><div class="recent-post-info"><a class="article-title" href="/posts/49b9d1d2.html" title="rust-生命周期">rust-生命周期</a><div class="article-meta-wrap"><span class="post-meta-date"><i class="far fa-calendar-alt"></i><span class="article-meta-label">发表于</span><time datetime="2023-03-06T14:06:13.000Z" title="发表于 2023-03-06 22:06:13">2023-03-06</time></span><span class="article-meta"><span class="article-meta-separator">|</span><i class="fas fa-inbox"></i><a class="article-meta__categories" href="/categories/rust/">rust</a></span></div><div class="content">前言先说大白话,rust 的生命周期标注,是为了明确多个变量的生命周期是否一致,仅此而已,因为如果rust不知道多个变量的生命周期是否一致,它无法确的知道这个变量是否已经被释放。这个下面再细说,先说有什么用。
rust当中,的两个重要概念:借用和生命周期分别代是在:
栈变量,需要关注【所有权】
引用(指针),需要关注【生命周期】
Rust 的每个引用都有自己的生命周期,生命周期指的是引用保持有效的作用域。大多数情况下,引用是隐式的、可以被推断出来的,但当引用可能以不同的方式互相关联时,则需要手动标注生命周期。这里重点就是以不同的方式互相关联时。
大多数情况下,rust 可以自己推断出引用的生拿周期,也就是只有在一些rust无法自行推断的情况下,才需要手动标注生命周期。
生命周期Rust 中的每一个引用都有其生命周期(lifetime),也就是引用保持有效的作用域。大部分时候生命周期是隐含并可以推断的,正如大部分时候类型也是可以推断的一样。类似于当因为有多种可能类型的时候必须注明类型,也会出现引用的生命周期以一些不同方式相关联的情况,所以 Rust 需要我们使用泛型生命周期参数来注明 ...</div></div></div><div class="recent-post-item"><div class="post_cover right"><a href="/posts/3e7235c0.html" title="rust-vim 整合基于vimspector的debug调试环境"><img class="post_bg" src="/images/cover/cover-rust.jpeg" onerror="this.onerror=null;this.src='/img/404.jpg'" alt="rust-vim 整合基于vimspector的debug调试环境"></a></div><div class="recent-post-info"><a class="article-title" href="/posts/3e7235c0.html" title="rust-vim 整合基于vimspector的debug调试环境">rust-vim 整合基于vimspector的debug调试环境</a><div class="article-meta-wrap"><span class="post-meta-date"><i class="far fa-calendar-alt"></i><span class="article-meta-label">发表于</span><time datetime="2023-02-27T15:17:08.000Z" title="发表于 2023-02-27 23:17:08">2023-02-27</time></span><span class="article-meta"><span class="article-meta-separator">|</span><i class="fas fa-inbox"></i><a class="article-meta__categories" href="/categories/rust/">rust</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/vim/">vim</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/vim/ide/">ide</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/rust/ide/">ide</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/vim/rust/">rust</a></span></div><div class="content">前言前面配置好rust开发环境后,还需要一个调试功能就能用了。不清楚的可以回看我的rust-vim安装记录调试器,找了几款,最后还是觉得还是使用vimspector这个用的习惯,捣鼓两个整合了一下基于vimspector的调试环境,快捷键不用重新再配置。
效果图:
这几天换了mac M2,把功能都迁移过来,完可用,这图就是M2上载图的。另外补全相关的配置,需要coc的一些额外配置。vim CocConfig参数设置说明
流程
安装vimspector插件: puremourning/vimspector
添加配置文件:
lldb-vscode.json
.vimspector.json
安装vimspector插件添加插件,然后执行PlugInstall,路径:
~/.config/nvim/init.vim
--enable-rust 表示要启用的语言支持,可以从官网查看支持的语言。
1Plug 'puremourning/vimspector', {'do': './install_gadget.py --en ...</div></div></div><div class="recent-post-item"><div class="post_cover left"><a href="/posts/2fd8d4c0.html" title="coc-java无法启动和lombok报错解决"><img class="post_bg" src="/images/cover/cover-java.jpeg" onerror="this.onerror=null;this.src='/img/404.jpg'" alt="coc-java无法启动和lombok报错解决"></a></div><div class="recent-post-info"><a class="article-title" href="/posts/2fd8d4c0.html" title="coc-java无法启动和lombok报错解决">coc-java无法启动和lombok报错解决</a><div class="article-meta-wrap"><span class="post-meta-date"><i class="far fa-calendar-alt"></i><span class="article-meta-label">发表于</span><time datetime="2023-02-21T17:33:35.000Z" title="发表于 2023-02-22 01:33:35">2023-02-22</time></span><span class="article-meta"><span class="article-meta-separator">|</span><i class="fas fa-inbox"></i><a class="article-meta__categories" href="/categories/java/">java</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/vim/">vim</a><i class="fas fa-angle-right article-meta-link"></i><a class="article-meta__categories" href="/categories/vim/java/">java</a></span></div><div class="content">问题一问时间不写java,这两天写java程序发现vim-java相关配置失效了,症状就是:
语法提示服务jdt不启动
lombok 失效
排查了一圈发现启动后官方的插件配置名都变了,改用合结vs-code的配置,又折腾了好一会。
解决更新jdt从官方jdt下载一个新包:https://github.com/eclipse/eclipse.jdt.ls备分:~/.config/coc/extensions/coc-java-data/server/ 目录,把下载的新包,内容放到 server下。
解决 lombok 报错问题还没完,启动后发现lombok报错,首先coc-java-lombok必须安装,没装的可以装一下
1CocInstall coc-java-lombok
然后安装OpenJDK,这个已验证必须使用OpenJDK才能解决这个问题。最后清理一下项目,很多人发现改完也没有效果,就是因为没有清理:
1CocCommand java.clean.workspace
</div></div></div><div class="recent-post-item"><div class="post_cover right"><a href="/posts/4fcae1e5.html" title="rust-泛型generics"><img class="post_bg" src="/images/cover/cover-rust.jpeg" onerror="this.onerror=null;this.src='/img/404.jpg'" alt="rust-泛型generics"></a></div><div class="recent-post-info"><a class="article-title" href="/posts/4fcae1e5.html" title="rust-泛型generics">rust-泛型generics</a><div class="article-meta-wrap"><span class="post-meta-date"><i class="far fa-calendar-alt"></i><span class="article-meta-label">发表于</span><time datetime="2023-02-12T06:49:53.000Z" title="发表于 2023-02-12 14:49:53">2023-02-12</time></span><span class="article-meta"><span class="article-meta-separator">|</span><i class="fas fa-inbox"></i><a class="article-meta__categories" href="/categories/rust/">rust</a></span></div><div class="content">泛型(generics)rust 也有泛型,这种最早出现1970年代的Ada语言中,后来被许多基于对象和面向对象的语言所采用,包括BETA、 C++、java。rust 也借鉴了这一特性。这种特性让程序有更好的通用性。
1.简单示例-结构体泛型给结构体 Point 定义一个泛型 T
123456789struct Point<T> { x: T, y: T,}fn main() { let integer = Point { x: 5, y: 10 }; let float = Point { x: 1.0, y: 4.0 };}
不同类型泛型
12345678910struct Point<T, U> { x: T, y: U,}fn main() { let both_integer = Point { x: 5, y: 10 }; let both_float = Point & ...</div></div></div><nav id="pagination"><div class="pagination"><span class="page-number current">1</span><a class="page-number" href="/page/2/#content-inner">2</a><span class="space">…</span><a class="page-number" href="/page/30/#content-inner">30</a><a class="extend next" rel="next" href="/page/2/#content-inner"><i class="fas fa-chevron-right fa-fw"></i></a></div></nav></div><div class="aside-content" id="aside-content"><div class="card-widget card-info"><div class="is-center"><div class="avatar-img"><img src="/images/touxiang.jpeg" onerror="this.onerror=null;this.src='/img/friend_404.gif'" alt="avatar"/></div><div class="author-info__name">潇洒</div><div class="author-info__description">吾日三省吾身,吾没错</div></div><div class="card-info-data site-data is-center"><a href="/archives/"><div class="headline">文章</div><div class="length-num">294</div></a><a href="/tags/"><div class="headline">标签</div><div class="length-num">445</div></a><a href="/categories/"><div class="headline">分类</div><div class="length-num">176</div></a></div><a id="card-info-btn" target="_blank" rel="noopener" href="https://github.com/forfreeday"><i class="fab fa-github"></i><span>Follow Me</span></a><div class="card-info-social-icons is-center"><a class="social-icon" href="https://github.com/forfreeday" target="_blank" title="Github"><i class="fab fa-github"></i></a><a class="social-icon" href="/atom.xml" target="_blank" title="RSS"><i class="fas fa-rss-square"></i></a></div></div><div class="card-widget card-announcement"><div class="item-headline"><i class="fas fa-bullhorn fa-shake"></i><span>公告</span></div><div class="announcement_content">重回赛道,开始追赶</div></div><div class="sticky_layout"><div class="card-widget card-recent-post"><div class="item-headline"><i class="fas fa-history"></i><span>最新文章</span></div><div class="aside-list"><div class="aside-list-item"><a class="thumbnail" href="/posts/752261e8.html" title="ETH-EIP-4337"><img src="/images/cover/cover-eth.jpeg" onerror="this.onerror=null;this.src='/img/404.jpg'" alt="ETH-EIP-4337"/></a><div class="content"><a class="title" href="/posts/752261e8.html" title="ETH-EIP-4337">ETH-EIP-4337</a><time datetime="2023-11-20T15:40:48.000Z" title="发表于 2023-11-20 23:40:48">2023-11-20</time></div></div><div class="aside-list-item"><a class="thumbnail" href="/posts/819a1e2d.html" title="Cosmos 普通交易手续费调研"><img src="/images/cover/cover-cosmos.svg" onerror="this.onerror=null;this.src='/img/404.jpg'" alt="Cosmos 普通交易手续费调研"/></a><div class="content"><a class="title" href="/posts/819a1e2d.html" title="Cosmos 普通交易手续费调研">Cosmos 普通交易手续费调研</a><time datetime="2023-09-18T09:19:26.000Z" title="发表于 2023-09-18 17:19:26">2023-09-18</time></div></div><div class="aside-list-item"><a class="thumbnail" href="/posts/82ae354b.html" title="EIP-4844-blob 简单说明"><img src="/images/cover/cover-eth.jpeg" onerror="this.onerror=null;this.src='/img/404.jpg'" alt="EIP-4844-blob 简单说明"/></a><div class="content"><a class="title" href="/posts/82ae354b.html" title="EIP-4844-blob 简单说明">EIP-4844-blob 简单说明</a><time datetime="2023-06-20T15:01:09.000Z" title="发表于 2023-06-20 23:01:09">2023-06-20</time></div></div><div class="aside-list-item"><a class="thumbnail" href="/posts/4cbcc746.html" title="rust 继承、封装、多态"><img src="/images/cover/cover-rust.jpeg" onerror="this.onerror=null;this.src='/img/404.jpg'" alt="rust 继承、封装、多态"/></a><div class="content"><a class="title" href="/posts/4cbcc746.html" title="rust 继承、封装、多态">rust 继承、封装、多态</a><time datetime="2023-06-01T12:00:03.000Z" title="发表于 2023-06-01 20:00:03">2023-06-01</time></div></div><div class="aside-list-item"><a class="thumbnail" href="/posts/e5fa7f4c.html" title="以太坊 EIP-4844 简述"><img src="/images/cover/cover-eth.jpeg" onerror="this.onerror=null;this.src='/img/404.jpg'" alt="以太坊 EIP-4844 简述"/></a><div class="content"><a class="title" href="/posts/e5fa7f4c.html" title="以太坊 EIP-4844 简述">以太坊 EIP-4844 简述</a><time datetime="2023-05-23T17:17:21.000Z" title="发表于 2023-05-24 01:17:21">2023-05-24</time></div></div></div></div><div class="card-widget" id="card-newest-comments"><div class="item-headline"><i class="fas fa-comment-dots"></i><span>最新评论</span></div><div class="aside-list"><span>正在加载中...</span></div></div><div class="card-widget card-categories"><div class="item-headline">
<i class="fas fa-folder-open"></i>
<span>分类</span>
<a class="card-more-btn" href="/categories/" title="查看更多">
<i class="fas fa-angle-right"></i></a>
</div>
<ul class="card-category-list" id="aside-cat-list">
<li class="card-category-list-item "><a class="card-category-list-link" href="/categories/Tendermint/"><span class="card-category-list-name">Tendermint</span><span class="card-category-list-count">4</span></a><ul class="card-category-list child"><li class="card-category-list-item "><a class="card-category-list-link" href="/categories/Tendermint/%E6%BA%90%E7%A0%81%E5%88%86%E6%9E%90/"><span class="card-category-list-name">源码分析</span><span class="card-category-list-count">1</span></a></li></ul></li><li class="card-category-list-item "><a class="card-category-list-link" href="/categories/algorithm/"><span class="card-category-list-name">algorithm</span><span class="card-category-list-count">17</span></a><ul class="card-category-list child"><li class="card-category-list-item "><a class="card-category-list-link" href="/categories/algorithm/array/"><span class="card-category-list-name">array</span><span class="card-category-list-count">1</span></a></li><li class="card-category-list-item "><a class="card-category-list-link" href="/categories/algorithm/concurrent/"><span class="card-category-list-name">concurrent</span><span class="card-category-list-count">1</span></a></li><li class="card-category-list-item "><a class="card-category-list-link" href="/categories/algorithm/leetcode/"><span class="card-category-list-name">leetcode</span><span class="card-category-list-count">4</span></a></li><li class="card-category-list-item "><a class="card-category-list-link" href="/categories/algorithm/slot/"><span class="card-category-list-name">slot</span><span class="card-category-list-count">1</span></a></li><li class="card-category-list-item "><a class="card-category-list-link" href="/categories/algorithm/struct/"><span class="card-category-list-name">struct</span><span class="card-category-list-count">1</span></a></li></ul></li>
</ul></div><div class="card-widget card-tags"><div class="item-headline"><i class="fas fa-tags"></i><span>标签</span></div><div class="card-tag-cloud"><a href="/tags/blockchain/" style="font-size: 1.45em; color: rgb(189, 58, 144)">blockchain</a><a href="/tags/merkle/" style="font-size: 1.15em; color: rgb(141, 174, 51)">merkle</a><a href="/tags/%E6%A0%91/" style="font-size: 1.18em; color: rgb(108, 158, 172)">树</a><a href="/tags/%E5%8E%9F%E7%90%86/" style="font-size: 1.28em; color: rgb(118, 165, 28)">原理</a><a href="/tags/trie/" style="font-size: 1.15em; color: rgb(124, 178, 98)">trie</a><a href="/tags/%E5%8C%BA%E5%9D%97%E9%93%BE/" style="font-size: 1.38em; color: rgb(56, 54, 29)">区块链</a><a href="/tags/%E7%AE%97%E6%B3%95/" style="font-size: 1.42em; color: rgb(190, 116, 102)">算法</a><a href="/tags/linux/" style="font-size: 1.38em; color: rgb(123, 143, 169)">linux</a><a href="/tags/core/" style="font-size: 1.15em; color: rgb(72, 59, 121)">core</a><a href="/tags/%E5%86%85%E6%A0%B8/" style="font-size: 1.15em; color: rgb(34, 149, 149)">内核</a><a href="/tags/%E7%89%88%E6%9C%AC/" style="font-size: 1.15em; color: rgb(187, 195, 193)">版本</a><a href="/tags/rust/" style="font-size: 1.32em; color: rgb(158, 131, 106)">rust</a><a href="/tags/%E7%94%9F%E5%91%BD%E5%91%A8%E6%9C%9F/" style="font-size: 1.15em; color: rgb(76, 143, 119)">生命周期</a><a href="/tags/ethereum/" style="font-size: 1.32em; color: rgb(188, 3, 15)">ethereum</a><a href="/tags/eth/" style="font-size: 1.35em; color: rgb(87, 39, 168)">eth</a><a href="/tags/account/" style="font-size: 1.15em; color: rgb(153, 8, 27)">account</a><a href="/tags/%E8%B4%A6%E6%88%B7%E6%A8%A1%E5%9E%8B/" style="font-size: 1.15em; color: rgb(5, 166, 153)">账户模型</a><a href="/tags/%E8%B4%A6%E6%88%B7/" style="font-size: 1.15em; color: rgb(127, 117, 165)">账户</a><a href="/tags/%E6%A8%A1%E5%9E%8B/" style="font-size: 1.18em; color: rgb(122, 5, 170)">模型</a><a href="/tags/%E4%BB%A5%E5%A4%AA%E5%9D%8A/" style="font-size: 1.22em; color: rgb(67, 62, 54)">以太坊</a><a href="/tags/%E5%A4%96%E9%83%A8%E8%B4%A6%E6%88%B7/" style="font-size: 1.15em; color: rgb(137, 153, 124)">外部账户</a><a href="/tags/%E5%90%88%E7%BA%A6%E8%B4%A6%E6%88%B7/" style="font-size: 1.15em; color: rgb(170, 190, 62)">合约账户</a><a href="/tags/idea/" style="font-size: 1.25em; color: rgb(177, 170, 11)">idea</a><a href="/tags/tron/" style="font-size: 1.42em; color: rgb(184, 94, 80)">tron</a><a href="/tags/snapshot/" style="font-size: 1.15em; color: rgb(87, 131, 106)">snapshot</a><a href="/tags/%E5%BF%AB%E7%85%A7/" style="font-size: 1.18em; color: rgb(193, 147, 24)">快照</a><a href="/tags/wol/" style="font-size: 1.15em; color: rgb(118, 182, 186)">wol</a><a href="/tags/synology/" style="font-size: 1.22em; color: rgb(128, 68, 199)">synology</a><a href="/tags/%E9%9D%A2%E5%83%8F%E5%AF%B9%E8%B1%A1/" style="font-size: 1.15em; color: rgb(179, 75, 66)">面像对象</a><a href="/tags/%E7%BB%A7%E6%89%BF/" style="font-size: 1.15em; color: rgb(149, 200, 63)">继承</a><a href="/tags/%E5%B0%81%E8%A3%85/" style="font-size: 1.15em; color: rgb(158, 105, 38)">封装</a><a href="/tags/%E5%A4%9A%E6%80%81/" style="font-size: 1.15em; color: rgb(141, 179, 147)">多态</a><a href="/tags/%E8%83%BD%E9%87%8F/" style="font-size: 1.15em; color: rgb(120, 14, 38)">能量</a><a href="/tags/%E5%B8%A6%E5%AE%BD/" style="font-size: 1.15em; color: rgb(146, 151, 172)">带宽</a><a href="/tags/%E8%B5%84%E6%BA%90/" style="font-size: 1.15em; color: rgb(55, 98, 11)">资源</a><a href="/tags/%E5%B9%BF%E6%92%AD/" style="font-size: 1.18em; color: rgb(168, 153, 21)">广播</a><a href="/tags/%E5%A4%A7%E6%95%B0%E6%8D%AE/" style="font-size: 1.22em; color: rgb(96, 37, 43)">大数据</a><a href="/tags/hadoop1-0/" style="font-size: 1.15em; color: rgb(146, 124, 51)">hadoop1.0</a><a href="/tags/NameNode/" style="font-size: 1.15em; color: rgb(115, 114, 79)">NameNode</a><a href="/tags/map-%E4%BB%BB%E5%8A%A1/" style="font-size: 1.15em; color: rgb(168, 9, 67)">map 任务</a></div></div><div class="card-widget card-archives"><div class="item-headline"><i class="fas fa-archive"></i><span>归档</span><a class="card-more-btn" href="/archives/" title="查看更多">
<i class="fas fa-angle-right"></i></a></div><ul class="card-archive-list"><li class="card-archive-list-item"><a class="card-archive-list-link" href="/archives/2023/11/"><span class="card-archive-list-date">十一月 2023</span><span class="card-archive-list-count">1</span></a></li><li class="card-archive-list-item"><a class="card-archive-list-link" href="/archives/2023/09/"><span class="card-archive-list-date">九月 2023</span><span class="card-archive-list-count">1</span></a></li><li class="card-archive-list-item"><a class="card-archive-list-link" href="/archives/2023/06/"><span class="card-archive-list-date">六月 2023</span><span class="card-archive-list-count">2</span></a></li><li class="card-archive-list-item"><a class="card-archive-list-link" href="/archives/2023/05/"><span class="card-archive-list-date">五月 2023</span><span class="card-archive-list-count">1</span></a></li><li class="card-archive-list-item"><a class="card-archive-list-link" href="/archives/2023/04/"><span class="card-archive-list-date">四月 2023</span><span class="card-archive-list-count">1</span></a></li><li class="card-archive-list-item"><a class="card-archive-list-link" href="/archives/2023/03/"><span class="card-archive-list-date">三月 2023</span><span class="card-archive-list-count">1</span></a></li><li class="card-archive-list-item"><a class="card-archive-list-link" href="/archives/2023/02/"><span class="card-archive-list-date">二月 2023</span><span class="card-archive-list-count">4</span></a></li><li class="card-archive-list-item"><a class="card-archive-list-link" href="/archives/2023/01/"><span class="card-archive-list-date">一月 2023</span><span class="card-archive-list-count">4</span></a></li></ul></div><div class="card-widget card-webinfo"><div class="item-headline"><i class="fas fa-chart-line"></i><span>网站资讯</span></div><div class="webinfo"><div class="webinfo-item"><div class="item-name">文章数目 :</div><div class="item-count">294</div></div><div class="webinfo-item"><div class="item-name">最后更新时间 :</div><div class="item-count" id="last-push-date" data-lastPushDate="2024-01-12T08:00:27.029Z"></div></div></div></div></div></div></main><footer id="footer" style="background-image: url('/images/bg.jpeg')"><div id="footer-wrap"><div class="copyright">©2020 - 2024 By 潇洒</div><div class="framework-info"><span>框架 </span><a target="_blank" rel="noopener" href="https://hexo.io">Hexo</a><span class="footer-separator">|</span><span>主题 </span><a target="_blank" rel="noopener" href="https://github.com/jerryc127/hexo-theme-butterfly">Butterfly</a><span class="footer-separator">|</span><a href="http://beian.miit.gov.cn/" style="color:#f72b07" target="_blank">京ICP备2023002120号</a></div></div></footer></div><div id="rightside"><div id="rightside-config-hide"><button id="darkmode" type="button" title="浅色和深色模式转换"><i class="fas fa-adjust"></i></button><button id="hide-aside-btn" type="button" title="单栏和双栏切换"><i class="fas fa-arrows-alt-h"></i></button></div><div id="rightside-config-show"><button id="rightside_config" type="button" title="设置"><i class="fas fa-cog fa-spin"></i></button><button id="go-up" type="button" title="回到顶部"><i class="fas fa-arrow-up"></i></button></div></div><div id="local-search"><div class="search-dialog"><nav class="search-nav"><span class="search-dialog-title">搜索</span><span id="loading-status"></span><button class="search-close-button"><i class="fas fa-times"></i></button></nav><div class="is-center" id="loading-database"><i class="fas fa-spinner fa-pulse"></i><span> 数据库加载中</span></div><div class="search-wrap"><div id="local-search-input"><div class="local-search-box"><input class="local-search-box--input" placeholder="搜索文章" type="text"/></div></div><hr/><div id="local-search-results"></div></div></div><div id="search-mask"></div></div><div><script src="/js/utils.js"></script><script src="/js/main.js"></script><script src="https://cdn.jsdelivr.net/npm/@fancyapps/ui/dist/fancybox.umd.js"></script><script src="/js/search/local-search.js"></script><div class="js-pjax"><script>function subtitleType () {
if (true) {
window.typed = new Typed("#subtitle", {
strings: ["本世纪,大白话翻译家","有限的时间,无限的可能","整体框架,局部细节","刻意训练,持续输出"],
startDelay: 300,
typeSpeed: 150,
loop: true,
backSpeed: 50
})
} else {
document.getElementById("subtitle").innerHTML = '本世纪,大白话翻译家'
}
}
if (true) {
if (typeof Typed === 'function') {
subtitleType()
} else {
getScript('https://cdn.jsdelivr.net/npm/typed.js/lib/typed.min.js').then(subtitleType)
}
} else {
subtitleType()
}</script></div><script>window.addEventListener('load', () => {
const changeContent = (content) => {
if (content === '') return content
content = content.replace(/<img.*?src="(.*?)"?[^\>]+>/ig, '[图片]') // replace image link
content = content.replace(/<a[^>]+?href=["']?([^"']+)["']?[^>]*>([^<]+)<\/a>/gi, '[链接]') // replace url
content = content.replace(/<pre><code>.*?<\/pre>/gi, '[代码]') // replace code
content = content.replace(/<[^>]+>/g,"") // remove html tag
if (content.length > 150) {
content = content.substring(0,150) + '...'
}
return content
}
const findTrueUrl = (array) => {
Promise.all(array.map(item =>
fetch(item.url).then(resp => resp.json()).then(data => {
const urlArray = data.body.match(/(https?:\/\/)?([\da-z\.-]+)\.([a-z\.]{2,6})([\/\w \.-]*)*\/?/ig)
if (data.user.login === 'utterances-bot') {
return urlArray.pop()
} else {
return urlArray.shift()
}
})
)).then(res => {
array = array.map((i,index)=> {
return {
...i,
url: res[index]
}
})
saveToLocal.set('github-newest-comments', JSON.stringify(array), 10/(60*24))
generateHtml(array)
});
}
const getComment = () => {
fetch('https://api.github.com/repos/forfreeday/forfreeday.github.io/issues/comments?sort=updated&direction=desc&per_page=6&page=1',{
"headers": {
Accept: 'application/vnd.github.v3.html+json'
}
})
.then(response => response.json())
.then(data => {
const githubArray = data.map(item => {
return {
'avatar': item.user.avatar_url,
'content': changeContent(item.body_html),
'nick': item.user.login,
'url': item.issue_url,
'date': item.updated_at,
'githubUrl': item.html_url
}
})
findTrueUrl(githubArray)
}).catch(e => {
const $dom = document.querySelector('#card-newest-comments .aside-list')
$dom.innerHTML= "无法获取评论,请确认相关配置是否正确"
})
}
const generateHtml = array => {
let result = ''
if (array.length) {
for (let i = 0; i < array.length; i++) {
result += '<div class=\'aside-list-item\'>'
if (true) {
const name = 'src'
result += `<a href='${array[i].url}' class='thumbnail'><img ${name}='${array[i].avatar}' alt='${array[i].nick}'></a>`
}
result += `<div class='content'>
<a class='comment' href='${array[i].url}' title='${array[i].content}'>${array[i].content}</a>
<div class='name'><span>${array[i].nick} / </span><time datetime="${array[i].date}">${btf.diffDate(array[i].date, true)}</time></div>
</div></div>`
}
} else {
result += '没有评论'
}
let $dom = document.querySelector('#card-newest-comments .aside-list')
$dom.innerHTML= result
window.lazyLoadInstance && window.lazyLoadInstance.update()
window.pjax && window.pjax.refresh($dom)
}
const newestCommentInit = () => {
if (document.querySelector('#card-newest-comments .aside-list')) {
const data = saveToLocal.get('github-newest-comments')
if (data) {
generateHtml(JSON.parse(data))
} else {
getComment()
}
}
}
newestCommentInit()
document.addEventListener('pjax:complete', newestCommentInit)
})</script></div></body></html>