略微加速

PHP官方手册 - 互联网笔记

PHP - Manual: TokyoTyrant::size

2024-04-27

TokyoTyrant::size

(PECL tokyo_tyrant >= 0.1.0)

TokyoTyrant::sizeReturns the size of the value

说明

public TokyoTyrant::size ( string $key ) : int

Returns the size of a value by key

参数

key

The key of which size to fetch

返回值

Returns the size of the key or throw TokyoTyrantException on error

范例

Example #1 TokyoTyrant::size() example

<?php
$tt 
= new TokyoTyrant("localhost");

$tt->put("test_key""12345");

echo 
$tt->size("test_key");
?>

以上例程会输出:

5
add a note add a note

User Contributed Notes

There are no user contributed notes for this page.

官方地址:https://www.php.net/manual/en/tokyotyrant.size.php

北京半月雨文化科技有限公司.版权所有 京ICP备12026184号-3