gearman.stub.php 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392
  1. <?php
  2. /** @generate-function-entries */
  3. function gearman_version(): string {}
  4. function gearman_bugreport(): string {}
  5. function gearman_verbose_name(int $verbose): ?string {}
  6. function gearman_client_create(): GearmanClient|false {}
  7. function gearman_worker_create(): GearmanWorker|false {}
  8. class GearmanClient {
  9. public function __construct() {}
  10. public function __destruct() {}
  11. /** @alias gearman_client_return_code */
  12. public function returnCode(): int {}
  13. /** @alias gearman_client_error */
  14. public function error(): string|false {}
  15. /** @alias gearman_client_get_errno */
  16. public function getErrno(): int {}
  17. /** @alias gearman_client_options */
  18. public function options(): int {}
  19. /** @alias gearman_client_set_options */
  20. public function setOptions(int $option): bool {}
  21. /** @alias gearman_client_add_options */
  22. public function addOptions(int $option): bool {}
  23. /** @alias gearman_client_remove_options */
  24. public function removeOptions(int $option): bool {}
  25. /** @alias gearman_client_timeout */
  26. public function timeout(): int {}
  27. /** @alias gearman_client_set_timeout */
  28. public function setTimeout(int $timeout): bool {}
  29. /** @alias gearman_client_add_server */
  30. public function addServer(string $host = null, int $port = 0, bool $setupExceptionHandler = true): bool {}
  31. /** @alias gearman_client_add_servers */
  32. public function addServers(string $servers = null, bool $setupExceptionHandler = true): bool {}
  33. /** @alias gearman_client_wait */
  34. public function wait(): bool {}
  35. /** @alias gearman_client_do_normal */
  36. public function doNormal(string $function, string $workload, ?string $unique = null): string {}
  37. /** @alias gearman_client_do_high */
  38. public function doHigh(string $function, string $workload, ?string $unique = null): string {}
  39. /** @alias gearman_client_do_low */
  40. public function doLow(string $function, string $workload, ?string $unique = null): string {}
  41. /** @alias gearman_client_do_background */
  42. public function doBackground(string $function, string $workload, ?string $unique = null): string {}
  43. /** @alias gearman_client_do_high_background */
  44. public function doHighBackground(string $function, string $workload, ?string $unique = null): string {}
  45. /** @alias gearman_client_do_low_background */
  46. public function doLowBackground(string $function, string $workload, ?string $unique = null): string {}
  47. /** @alias gearman_client_do_job_handle */
  48. public function doJobHandle(): string {}
  49. /** @alias gearman_client_do_status */
  50. public function doStatus(): array {}
  51. /** @alias gearman_client_job_status */
  52. public function jobStatus(string $job_handle): array {}
  53. /** @alias gearman_client_job_status_by_unique_key */
  54. public function jobStatusByUniqueKey(string $unique_key): array {}
  55. /** @alias gearman_client_ping */
  56. public function ping(string $workload): bool {}
  57. /** @alias gearman_client_add_task */
  58. public function addTask(string $function_name, string|int|float $workload, mixed $context = null, ?string $unique_key = null): GearmanTask|false {}
  59. /** @alias gearman_client_add_task_high */
  60. public function addTaskHigh(string $function_name, string|int|float $workload, mixed $context = null, ?string $unique_key = null): GearmanTask|false {}
  61. /** @alias gearman_client_add_task_low */
  62. public function addTaskLow(string $function_name, string|int|float $workload, mixed $context = null, ?string $unique_key = null): GearmanTask|false {}
  63. /** @alias gearman_client_add_task_background */
  64. public function addTaskBackground(string $function_name, string|int|float $workload, mixed $context = null, ?string $unique_key = null): GearmanTask|false {}
  65. /** @alias gearman_client_add_task_high_background */
  66. public function addTaskHighBackground(string $function_name, string|int|float $workload, mixed $context = null, ?string $unique_key = null): GearmanTask|false {}
  67. /** @alias gearman_client_add_task_low_background */
  68. public function addTaskLowBackground(string $function_name, string|int|float $workload, mixed $context = null, ?string $unique_key = null): GearmanTask|false {}
  69. /** @alias gearman_client_run_tasks */
  70. public function runTasks(): bool {}
  71. /** @alias gearman_client_add_task_status */
  72. public function addTaskStatus (string $job_handle, mixed $context = null): GearmanTask|false {}
  73. /** @alias gearman_client_set_workload_callback */
  74. public function setWorkloadCallback(callable $function): bool {}
  75. /** @alias gearman_client_set_created_callback */
  76. public function setCreatedCallback(callable $function): bool {}
  77. /** @alias gearman_client_set_data_callback */
  78. public function setDataCallback(callable $function): bool {}
  79. /** @alias gearman_client_set_warning_callback */
  80. public function setWarningCallback(callable $function): bool {}
  81. /** @alias gearman_client_set_status_callback */
  82. public function setStatusCallback(callable $function): bool {}
  83. /** @alias gearman_client_set_complete_callback */
  84. public function setCompleteCallback(callable $function): bool {}
  85. /** @alias gearman_client_set_exception_callback */
  86. public function setExceptionCallback(callable $function): bool {}
  87. /** @alias gearman_client_set_fail_callback */
  88. public function setFailCallback(callable $function): bool {}
  89. /** @alias gearman_client_clear_callbacks */
  90. public function clearCallbacks(): bool {}
  91. /** @alias gearman_client_context */
  92. public function context(): string {}
  93. /** @alias gearman_client_set_context */
  94. public function setContext(string $data): bool {}
  95. /** @alias gearman_client_enable_exception_handler */
  96. public function enableExceptionHandler(): bool {}
  97. }
  98. function gearman_client_return_code(GearmanClient $obj): int {}
  99. function gearman_client_error(GearmanClient $obj): string|false {}
  100. function gearman_client_get_errno(GearmanClient $obj): int {}
  101. function gearman_client_options(GearmanClient $obj): int {}
  102. function gearman_client_set_options(GearmanClient $obj, int $option): bool {}
  103. function gearman_client_add_options(GearmanClient $obj, int $option): bool {}
  104. function gearman_client_remove_options(GearmanClient $obj, int $option): bool {}
  105. function gearman_client_timeout(GearmanClient $obj): ?int {}
  106. function gearman_client_set_timeout(GearmanClient $obj, int $timeout): bool {}
  107. function gearman_client_add_server(GearmanClient $obj, string $host = null, int $port = 0, bool $setupExceptionHandler = true): bool {}
  108. function gearman_client_add_servers(GearmanClient $obj, string $servers = null, bool $setupExceptionHandler = true): bool {}
  109. function gearman_client_wait(GearmanClient $obj): bool {}
  110. function gearman_client_do_normal(GearmanClient $obj, string $function, string $workload, ?string $unique = null): string {}
  111. function gearman_client_do_high(GearmanClient $obj, string $function, string $workload, ?string $unique = null): string {}
  112. function gearman_client_do_low(GearmanClient $obj, string $function, string $workload, ?string $unique = null): string {}
  113. function gearman_client_do_background(GearmanClient $obj, string $function, string $workload, ?string $unique = null): string {}
  114. function gearman_client_do_high_background(GearmanClient $obj, string $function, string $workload, ?string $unique = null): string {}
  115. function gearman_client_do_low_background(GearmanClient $obj, string $function, string $workload, ?string $unique = null): string {}
  116. function gearman_client_do_job_handle(GearmanClient $obj): string {}
  117. function gearman_client_do_status(GearmanClient $obj): array {}
  118. function gearman_client_job_status(GearmanClient $obj, string $job_handle): array {}
  119. function gearman_client_job_status_by_unique_key(GearmanClient $obj, string $unique_key): array {}
  120. function gearman_client_ping(GearmanClient $obj, string $workload): bool {}
  121. function gearman_client_add_task(GearmanClient $obj, string $function_name, string|int|float $workload, mixed $context = null, ?string $unique_key = null): GearmanTask|false {}
  122. function gearman_client_add_task_high(GearmanClient $obj, string $function_name, string|int|float $workload, mixed $context = null, ?string $unique_key = null): GearmanTask|false {}
  123. function gearman_client_add_task_low(GearmanClient $obj, string $function_name, string|int|float $workload, mixed $context = null, ?string $unique_key = null): GearmanTask|false {}
  124. function gearman_client_add_task_background(GearmanClient $obj, string $function_name, string|int|float $workload, mixed $context = null, ?string $unique_key = null): GearmanTask|false {}
  125. function gearman_client_add_task_high_background(GearmanClient $obj, string $function_name, string|int|float $workload, mixed $context = null, ?string $unique_key = null): GearmanTask|false {}
  126. function gearman_client_add_task_low_background(GearmanClient $obj, string $function_name, string|int|float $workload, mixed $context = null, ?string $unique_key = null): GearmanTask|false {}
  127. function gearman_client_run_tasks(GearmanClient $obj): bool {}
  128. function gearman_client_add_task_status(GearmanClient $obj, string $job_handle, mixed $context = null): GearmanTask|false {}
  129. function gearman_client_set_workload_callback(GearmanClient $obj, callable $function): bool {}
  130. function gearman_client_set_created_callback(GearmanClient $obj, callable $function): bool {}
  131. function gearman_client_set_data_callback(GearmanClient $obj, callable $function): bool {}
  132. function gearman_client_set_warning_callback(GearmanClient $obj, callable $function): bool {}
  133. function gearman_client_set_status_callback(GearmanClient $obj, callable $function): bool {}
  134. function gearman_client_set_complete_callback(GearmanClient $obj, callable $function): bool {}
  135. function gearman_client_set_exception_callback(GearmanClient $obj, callable $function): bool {}
  136. function gearman_client_set_fail_callback(GearmanClient $obj, callable $function): bool {}
  137. function gearman_client_clear_callbacks(GearmanClient $obj): bool {}
  138. function gearman_client_context(GearmanClient $obj): string {}
  139. function gearman_client_set_context(GearmanClient $obj, string $data): bool {}
  140. function gearman_client_enable_exception_handler(GearmanClient $obj): bool {}
  141. class GearmanJob {
  142. public function __destruct() {}
  143. /** @alias gearman_job_return_code */
  144. public function returnCode(): int {}
  145. /** @alias gearman_job_set_return */
  146. public function setReturn(int $gearman_return_t): bool {}
  147. /** @alias gearman_job_send_data */
  148. public function sendData(string $data): bool {}
  149. /** @alias gearman_job_send_warning */
  150. public function sendWarning(string $warning): bool {}
  151. /** @alias gearman_job_send_status */
  152. public function sendStatus(int $numerator, int $denominator): bool {}
  153. /** @alias gearman_job_send_complete */
  154. public function sendComplete(string $result): bool {}
  155. /** @alias gearman_job_send_exception */
  156. public function sendException(string $exception): bool {}
  157. /** @alias gearman_job_send_fail */
  158. public function sendFail(): bool {}
  159. /** @alias gearman_job_handle */
  160. public function handle(): false|string {}
  161. /** @alias gearman_job_function_name */
  162. public function functionName(): false|string {}
  163. /** @alias gearman_job_unique */
  164. public function unique(): false|string {}
  165. /** @alias gearman_job_workload */
  166. public function workload(): string {}
  167. /** @alias gearman_job_workload_size */
  168. public function workloadSize(): int {}
  169. }
  170. function gearman_job_return_code(GearmanJob $obj): int {}
  171. function gearman_job_set_return(GearmanJob $obj, int $gearman_return_t): bool {}
  172. function gearman_job_send_data(GearmanJob $obj, string $data): bool {}
  173. function gearman_job_send_warning(GearmanJob $obj, string $warning): bool {}
  174. function gearman_job_send_status(GearmanJob $obj, int $numerator, int $denominator): bool {}
  175. function gearman_job_send_complete(GearmanJob $obj, string $result): bool {}
  176. function gearman_job_send_exception(GearmanJob $obj, string $exception): bool {}
  177. function gearman_job_send_fail(GearmanJob $obj): bool {}
  178. function gearman_job_handle(GearmanJob $obj): false|string {}
  179. function gearman_job_function_name(GearmanJob $obj): false|string {}
  180. function gearman_job_unique(GearmanJob $obj): false|string {}
  181. function gearman_job_workload(GearmanJob $obj): string {}
  182. function gearman_job_workload_size(GearmanJob $obj): int {}
  183. class GearmanTask {
  184. public function __construct() {}
  185. /** @alias gearman_task_return_code */
  186. public function returnCode(): int {}
  187. /** @alias gearman_task_function_name */
  188. public function functionName(): false|string {}
  189. /** @alias gearman_task_unique */
  190. public function unique(): false|string {}
  191. /** @alias gearman_task_job_handle */
  192. public function jobHandle(): false|string {}
  193. /** @alias gearman_task_is_known */
  194. public function isKnown(): bool {}
  195. /** @alias gearman_task_is_running */
  196. public function isRunning(): bool {}
  197. /** @alias gearman_task_numerator */
  198. public function taskNumerator(): false|int {}
  199. /** @alias gearman_task_denominator */
  200. public function taskDenominator(): false|int {}
  201. /** @alias gearman_task_data */
  202. public function data(): false|string {}
  203. /** @alias gearman_task_data_size */
  204. public function dataSize(): int|false {}
  205. /** @alias gearman_task_send_workload */
  206. public function sendWorkload(string $data): int|false {}
  207. /** @alias gearman_task_recv_data */
  208. public function recvData(int $data_len): false|array {}
  209. }
  210. function gearman_task_return_code(GearmanTask $obj): int {}
  211. function gearman_task_function_name(GearmanTask $obj): false|string {}
  212. function gearman_task_unique(GearmanTask $obj): false|string {}
  213. function gearman_task_job_handle(GearmanTask $obj): false|string {}
  214. function gearman_task_is_known(GearmanTask $obj): bool {}
  215. function gearman_task_is_running(GearmanTask $obj): bool {}
  216. function gearman_task_numerator(GearmanTask $obj): false|int {}
  217. function gearman_task_denominator(GearmanTask $obj): false|int {}
  218. function gearman_task_data(GearmanTask $obj): false|string {}
  219. function gearman_task_data_size(GearmanTask $obj): int|false {}
  220. function gearman_task_send_workload(GearmanTask $obj, string $data): int|false {}
  221. function gearman_task_recv_data(GearmanTask $obj, int $data_len): false|array {}
  222. class GearmanWorker {
  223. public function __construct() {}
  224. public function __destruct() {}
  225. /** @alias gearman_worker_return_code */
  226. public function returnCode(): int {}
  227. /** @alias gearman_worker_error */
  228. public function error(): string|false {}
  229. /** @alias gearman_worker_errno */
  230. public function getErrno(): int {}
  231. /** @alias gearman_worker_options */
  232. public function options(): int {}
  233. /** @alias gearman_worker_set_options */
  234. public function setOptions(int $option): true {}
  235. /** @alias gearman_worker_add_options */
  236. public function addOptions(int $option): true {}
  237. /** @alias gearman_worker_remove_options */
  238. public function removeOptions(int $option): true {}
  239. /** @alias gearman_worker_timeout */
  240. public function timeout(): int {}
  241. /** @alias gearman_worker_set_timeout */
  242. public function setTimeout(int $timeout): true {}
  243. /** @alias gearman_worker_set_id */
  244. public function setId(string $id): bool {}
  245. /** @alias gearman_worker_add_server */
  246. public function addServer(string $host = null, int $port = 0, bool $setupExceptionHandler = true): bool {}
  247. /** @alias gearman_worker_add_servers */
  248. public function addServers(string $servers = null, bool $setupExceptionHandler = true): bool {}
  249. /** @alias gearman_worker_wait */
  250. public function wait(): bool {}
  251. /** @alias gearman_worker_register */
  252. public function register(string $function_name, int $timeout = 0): bool {}
  253. /** @alias gearman_worker_unregister */
  254. public function unregister(string $function_name): bool {}
  255. /** @alias gearman_worker_unregister_all */
  256. public function unregisterAll(): bool {}
  257. /** @alias gearman_worker_grab_job */
  258. public function grabJob(): GearmanWorker|false {}
  259. /** @alias gearman_worker_add_function */
  260. public function addFunction(string $function_name, callable $function, mixed $context = null, int $timeout = 0): bool {}
  261. /** @alias gearman_worker_work */
  262. public function work(): bool {}
  263. /** @alias gearman_worker_ping */
  264. public function ping(string $data): bool {}
  265. /** @alias gearman_worker_enable_exception_handler */
  266. public function enableExceptionHandler(): bool {}
  267. }
  268. function gearman_worker_return_code(GearmanWorker $obj): int {}
  269. function gearman_worker_error(GearmanWorker $obj): string|false {}
  270. function gearman_worker_errno(GearmanWorker $obj): int {}
  271. function gearman_worker_options(GearmanWorker $obj): int {}
  272. function gearman_worker_set_options(GearmanWorker $obj, int $option): true {}
  273. function gearman_worker_add_options(GearmanWorker $obj, int $option): true {}
  274. function gearman_worker_remove_options(GearmanWorker $obj, int $option): true {}
  275. function gearman_worker_timeout(GearmanWorker $obj): int {}
  276. function gearman_worker_set_timeout(GearmanWorker $obj, int $timeout): true {}
  277. function gearman_worker_set_id(GearmanWorker $obj, string $id): bool {}
  278. function gearman_worker_add_server(GearmanWorker $obj, string $host = null, int $port = 0, bool $setupExceptionHandler = true): bool {}
  279. function gearman_worker_add_servers(GearmanWorker $obj, string $servers = null, bool $setupExceptionHandler = true): bool {}
  280. function gearman_worker_wait(GearmanWorker $obj): bool {}
  281. function gearman_worker_register(GearmanWorker $obj, string $function_name, int $timeout = 0): bool {}
  282. function gearman_worker_unregister(GearmanWorker $obj, string $function_name): bool {}
  283. function gearman_worker_unregister_all(GearmanWorker $obj): bool {}
  284. function gearman_worker_grab_job(GearmanWorker $obj): GearmanWorker|false {}
  285. function gearman_worker_add_function(GearmanWorker $obj, string $function_name, callable $function, mixed $context = null, int $timeout = 0): bool {}
  286. function gearman_worker_work(GearmanWorker $obj): bool {}
  287. function gearman_worker_ping(GearmanWorker $obj, string $data): bool {}
  288. function gearman_worker_enable_exception_handler(GearmanWorker $obj): bool {}
  289. class GearmanException extends Exception { }