amaccis/php-dict 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

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

amaccis/php-dict

Composer 安装命令:

composer require amaccis/php-dict

包简介

A PHP DICT client

README 文档

README

PHP Version CI

The DICT Protocol

As per RFC 2229, the Dictionary Server Protocol (DICT) is a TCP transaction based query/response protocol that allows a client to access dictionary definitions from a set of natural language dictionary databases. For more details see dict.org.

Installation

php-dict is available on Packagist, you can install it using Composer.

composer require amaccis/php-stemmer

Usage

<?php

use Amaccis\Dict\Client;
use Amaccis\Dict\Query\CommandInterface;

$client = new Client();
$parameters = [
    'command' => CommandInterface::COMMAND_DEFINE,
    'word' => 'hacker',
    'database' => 'jargon'
];
$response = $client->query('dict.org', $parameters);
var_dump($response);
/*
array(6) {
  [0] =>
  class Amaccis\Dict\Response\Response#358 (2) {
    private $code =>
    string(3) "220"
    private $text =>
    string(84) "dict dictd 1.12.1/rf on Linux 4.19.0-10-amd64 <auth.mime> <534.2367.1605732508@dict>"
  }
  [1] =>
  class Amaccis\Dict\Response\Response#357 (2) {
    private $code =>
    string(3) "250"
    private $text =>
    string(2) "ok"
  }
  [2] =>
  class Amaccis\Dict\Response\Response#356 (2) {
    private $code =>
    string(3) "150"
    private $text =>
    string(23) "1 definitions retrieved"
  }
  [3] =>
  class Amaccis\Dict\Response\Response#355 (2) {
    private $code =>
    string(3) "151"
    private $text =>
    string(2516) ""hacker" jargon "The Jargon File (version 4.4.7, 29 Dec 2003)"
hacker
 n.

    [originally, someone who makes furniture with an axe]

    1. A person who enjoys exploring the details of programmable systems and
    how to stretch their capabilities, as opposed to most users, who prefer to
    learn only the minimum necessary. RFC1392, the Internet Users' Glossary,
    usefully amplifies this as: A person who delights in having an intimate
    understanding of the internal workings of a system, com"...
  }
  [4] =>
  class Amaccis\Dict\Response\Response#354 (2) {
    private $code =>
    string(3) "250"
    private $text =>
    string(41) "ok [d/m/c = 1/0/10; 0.000r 0.000u 0.000s]"
  }
  [5] =>
  class Amaccis\Dict\Response\Response#353 (2) {
    private $code =>
    string(3) "221"
    private $text =>
    string(41) "bye [d/m/c = 0/0/0; 0.000r 0.000u 0.000s]"
  }
}
*/

License

All files are MIT © Andrea Maccis

amaccis/php-dict 适用场景与选型建议

amaccis/php-dict 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 2 次下载、GitHub Stars 达 1, 最近一次更新时间为 2020 年 11 月 19 日, 在 PHP 生态内属于活跃度较高的组件。

我们在过去多个企业项目中使用过 amaccis/php-dict 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。

围绕 amaccis/php-dict 我们能提供哪些服务?
定制开发 / 二次开发

基于 amaccis/php-dict 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。

BUG 修复 & 性能优化

线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。

项目外包 & 长期维护

承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。

yvsm@zunyunkeji.com QQ:316430983 微信:yvsm316 西安尊云信息科技 · 专注 PHP / Go / 分布式系统研发

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2020-11-19