定制 dbp/relay-blob-library 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

dbp/relay-blob-library

最新稳定版本:v0.3.10

Composer 安装命令:

composer require dbp/relay-blob-library

包简介

PHP helper library for interaction with the dbp/relay-blob-bundle.

README 文档

README

GitHub | Packagist | Changelog

Test

PHP helper library for interaction with the relay-blob-bundle.

Installation

composer require dbp/relay-blob-library

Usage

Here is an example of how to use the library in HTTP mode, with OIDC authentication enabled:

    // create the API
    $blobApi = BlobApi::createHttpModeApi(
        $bucketIdentifier, $bucketKey, $blobBaseUrl,
        $oidcEnabled, $oidcProviderUrl, $oidcClientId, $oidcClientSecret);

    $blobFile = new BlobFile();
    $filePath = 'files/myFile.txt';
    $blobFile->setFilename(basename($filePath));
    $blobFile->setFile(new SplFileInfo($filePath));
    $blobFile->setPrefix('my-prefix');
    
    // add the file    
    $blobFile = $blobApi->addFile($blobFile);

    // get the file
    $blobFile = $blobApi->getFile($blobFile->getIdentifier());

    // remove the file
    $blobApi->removeFile($blobFile->getIdentifier());

Integration into a Symfony bundle

Soon to come.

统计信息

  • 总下载量: 40.56k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 1
  • 依赖项目数: 5
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 2
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: AGPL-3.0-or-later
  • 更新时间: 2023-07-25