PHPackages                             test\_zx/breakpoint - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. test\_zx/breakpoint

ActiveLibrary

test\_zx/breakpoint
===================

断点续传-后端实现，本地存储

1.0.0(1y ago)01MITPHPPHP ^7.4|^8.0

Since Apr 29Pushed 1y ago1 watchersCompare

[ Source](https://github.com/zx352166501/BPUploader)[ Packagist](https://packagist.org/packages/test_zx/breakpoint)[ Docs](https://github.com/zx352166501/BPUploader.git)[ RSS](/packages/test-zx-breakpoint/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (1)Dependencies (1)Versions (2)Used By (0)

断点续传
====

[](#断点续传)

上传前检查
-----

[](#上传前检查)

```
    $breakPointObj = new BPUploaderLocal();
    $breakPointObj ->chunkDir = __DIR__. '/../upload';
    $breakPointObj ->check($identifier);

```

上传文件
----

[](#上传文件)

```
    // 文件准备
    $testFile = [
        'name' => 'test.txt',
        'type' => 'text/plain',
        'tmp_name' => __DIR__ . '/test.txt',
        'error' => UPLOAD_ERR_OK,
        'size' => 100,
    ];
    // 创建临时文件
    file_put_contents($testFile['tmp_name'], 'This is a test file.');

    // 检查唯一标识
    $breakPointObj = new BPUploaderLocal();
    $breakPointObj ->chunkDir = __DIR__. '/../upload';
    $breakPointObj ->upload($identifier,$chunkNumber,$testFile);

```

文件合并
----

[](#文件合并)

```
    // 检查唯一标识
    $breakPointObj = new BPUploaderLocal();
    $breakPointObj ->chunkDir = __DIR__. '/../upload';
    $breakPointObj ->finalFileDir = __DIR__. '/../newUpload';
    $breakPointObj ->merge($identifier,$newFileName,$totalChunks);

```

备注
--

[](#备注)

- identifier 文件32位唯一标识
- chunkNumber 当前文件块序号
- chunkDir 为临时切块存储路径
- finalFileDir 为最终目录存储地址
- check 为检查方法，返回已经存储的块序号烈豪
- upload 为上传方法，返回成功块编号
- merge 为合并方法，返回最终文件的绝对路径

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance48

Moderate activity, may be stable

Popularity1

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity42

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

385d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/f846bf8e673489c31349d372e7134b7df4f03e473e188d1976caad3a5b398e9b?d=identicon)[zx352166501](/maintainers/zx352166501)

---

Top Contributors

[![zx352166501](https://avatars.githubusercontent.com/u/19216498?v=4)](https://github.com/zx352166501 "zx352166501 (7 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/test-zx-breakpoint/health.svg)

```
[![Health](https://phpackages.com/badges/test-zx-breakpoint/health.svg)](https://phpackages.com/packages/test-zx-breakpoint)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
