VictoriaFreSh 2021.4.18 → 2021.4.19
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.
- checksums.yaml +4 -4
- data/lib/victoriafresh.rb +1 -0
- data/victoriafresh.example.rb +4 -4
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1f8a1b21b33f86f42e6c3712cca0f5a7ec76e2c060493df051609e476b20a2df
|
4
|
+
data.tar.gz: 326eafeb9d1f68828348edde6c0b7f7fbb9876c5e4affe8e463fdd2e89662245
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d8e1eae45302abf8da5fd780fdedecc449f80668022b5310b7e77a2c6ebb4ea0e98f2395e16ceef3a975973f25a87b945d8840d541cf935d86ae1d58c74ce7a4
|
7
|
+
data.tar.gz: f75da9a9c352ba6511a0c35f3e21cd0f66e2c771b7c91f15f81795ddff1b5d6b69ba38b84ba2e4dfe8fb6952484c5c3c012827b46ebc69b2e8571a4a4c9cc1ec
|
data/lib/victoriafresh.rb
CHANGED
@@ -12,6 +12,7 @@ class VictoriaFresh
|
|
12
12
|
attr_accessor :diskFileName #向磁盘写入数据时的文件名或前缀
|
13
13
|
attr_accessor :diskMultiFile #向磁盘写入时,是否要写多个文件
|
14
14
|
attr_accessor :diskFlush #要提前磁盘写入文件,以节省内存吗?
|
15
|
+
attr_accessor :currentDiskFlushSuffix #当前的文件后缀。也等价于已经写入的文件片段个数
|
15
16
|
|
16
17
|
def initialize
|
17
18
|
@diskFlush=false #要向磁盘写入文件
|
data/victoriafresh.example.rb
CHANGED
@@ -9,7 +9,7 @@ else #指定了命令行参数。
|
|
9
9
|
|
10
10
|
$clipDownloader=VictoriaFresh.new #创建下载器。
|
11
11
|
|
12
|
-
$clipDownloader.diskFlush=
|
12
|
+
$clipDownloader.diskFlush=false #不向磁盘写入缓存
|
13
13
|
$clipDownloader.diskMultiFile=true #写多个磁盘文件
|
14
14
|
$clipDownloader.diskFileName='victoriafreshdata.v.' #磁盘文件名前缀
|
15
15
|
$clipDownloader.diskFlushSize=32*1024*1024 #磁盘文件大小
|
@@ -27,7 +27,7 @@ else #指定了命令行参数。
|
|
27
27
|
|
28
28
|
victoriaFreshFile.close #关闭文件。
|
29
29
|
|
30
|
-
|
31
|
-
|
32
|
-
|
30
|
+
victoriaFreshDataFile=File.new("victoriafreshdata.v","wb") #数据文件。
|
31
|
+
victoriaFreshDataFile.syswrite(victoriaFreshData) #写入文件。
|
32
|
+
victoriaFreshDataFile.close #关闭文件。
|
33
33
|
end
|