mirror of
https://github.com/YGGverse/Yoda.git
synced 2026-04-01 17:15:28 +00:00
update shared memory pool api
This commit is contained in:
parent
3ff79cb0be
commit
b18b9bb99e
3 changed files with 117 additions and 42 deletions
|
|
@ -14,18 +14,37 @@ interface Pool
|
|||
?string $namespace = null
|
||||
);
|
||||
|
||||
public function init(
|
||||
string $key,
|
||||
int $size = 0xfffff,
|
||||
string $flags = 'c',
|
||||
int $mode = 0644,
|
||||
): ?\Shmop;
|
||||
|
||||
public function read(
|
||||
string $key,
|
||||
int $start = 0,
|
||||
int $count = 0
|
||||
): ?string;
|
||||
|
||||
public function write(
|
||||
string $key,
|
||||
string $value,
|
||||
int $offset = 0
|
||||
): int;
|
||||
|
||||
public function delete(
|
||||
string $key
|
||||
): bool;
|
||||
|
||||
public function get(
|
||||
string $key
|
||||
): ?string;
|
||||
): string;
|
||||
|
||||
public function set(
|
||||
string $key,
|
||||
?string $value = null,
|
||||
string $flags = 'c',
|
||||
int $offset = 0,
|
||||
int $mode = 0644,
|
||||
?string $encoding = null
|
||||
): int;
|
||||
?string $value = null
|
||||
): void;
|
||||
|
||||
public function reset(): void;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue