1
0

xcache.php 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217
  1. <?php
  2. /**
  3. * Common Used Functions
  4. */
  5. /**
  6. * Get cached data by specified name
  7. *
  8. * @param string $name Key name
  9. * @return mixed
  10. */
  11. function xcache_get($name) {}
  12. /**
  13. * Store data to cache by specified name
  14. *
  15. * @param string $name Key name
  16. * @param mixed $value Value to store
  17. * @param int $ttl TTL in seconds
  18. * @return bool TRUE on success, FALSE otherwise
  19. */
  20. function xcache_set($name, $value, $ttl = 0) {}
  21. /**
  22. * Check if an entry exists in cache by specified name
  23. *
  24. * @param string $name Key name
  25. * @return bool TRUE if key exists, FALSE otherwise
  26. */
  27. function xcache_isset($name) {}
  28. /**
  29. * Unset existing data in cache by specified name
  30. *
  31. * @param string $name Key name
  32. * @return bool
  33. */
  34. function xcache_unset($name) {}
  35. /**
  36. * Unset existing data in cache by specified prefix
  37. *
  38. * @param string $prefix Keys' prefix
  39. * @return bool
  40. */
  41. function xcache_unset_by_prefix($prefix) {}
  42. /**
  43. * Increase an int counter in cache by specified name, create it if not exists
  44. *
  45. * @param string $name
  46. * @param mixed $value
  47. * @param int $ttl
  48. * @return int
  49. */
  50. function xcache_inc($name, $value = 1, $ttl = 0) {}
  51. /**
  52. * Decrease an int counter in cache by specified name, create it if not exists
  53. *
  54. * @param string $name
  55. * @param mixed $value
  56. * @param int $ttl
  57. * @return int
  58. */
  59. function xcache_dec($name, $value = 1, $ttl = 0) {}
  60. /**
  61. * Administrator Functions
  62. */
  63. /**
  64. * Return count of cache on specified cache type
  65. *
  66. * @param int $type
  67. * @return int
  68. */
  69. function xcache_count($type) {}
  70. /**
  71. * Get cache info by id on specified cache type
  72. *
  73. * @param int $type
  74. * @param int $id
  75. * @return array
  76. */
  77. function xcache_info($type, $id) {}
  78. /**
  79. * Get cache entries list by id on specified cache type
  80. *
  81. * @param int $type
  82. * @param int $id
  83. * @return array
  84. */
  85. function xcache_list($type, $id) {}
  86. /**
  87. * Clear cache by id on specified cache type
  88. *
  89. * @param int $type
  90. * @param int $id
  91. * @return void
  92. */
  93. function xcache_clear_cache($type, $id = -1) {}
  94. /**
  95. * @param int $op_type
  96. * @return string
  97. */
  98. function xcache_coredump($op_type) {}
  99. /**
  100. * Coverager Functions
  101. */
  102. /**
  103. * @param string $data
  104. * @return array
  105. */
  106. function xcache_coverager_decode($data) {}
  107. /**
  108. * @param bool $clean
  109. * @return void
  110. */
  111. function xcache_coverager_start($clean = true) {}
  112. /**
  113. * @param bool $clean
  114. * @return void
  115. */
  116. function xcache_coverager_stop($clean = false) {}
  117. /**
  118. * @param bool $clean
  119. * @return array
  120. */
  121. function xcache_coverager_get($clean = false) {}
  122. /**
  123. * Opcode Functions
  124. */
  125. /**
  126. * @param string $filename
  127. * @return string
  128. */
  129. function xcache_asm($filename) {}
  130. /**
  131. * Disassemble file into opcode array by filename
  132. *
  133. * @param string $filename
  134. * @return string
  135. */
  136. function xcache_dasm_file($filename) {}
  137. /**
  138. * Disassemble php code into opcode array
  139. *
  140. * @param string $code
  141. * @return string
  142. */
  143. function xcache_dasm_string($code) {}
  144. /**
  145. * Encode php file into XCache opcode encoded format
  146. *
  147. * @param string $filename
  148. * @return string
  149. */
  150. function xcache_encode($filename) {}
  151. /**
  152. * Decode(load) opcode from XCache encoded format file
  153. *
  154. * @param string $filename
  155. * @return bool
  156. */
  157. function xcache_decode($filename) {}
  158. /**
  159. * @param int $op_type
  160. * @return string
  161. */
  162. function xcache_get_op_type($op_type) {}
  163. /**
  164. * @param int $type
  165. * @return string
  166. */
  167. function xcache_get_data_type($type) {}
  168. /**
  169. * @param int $opcode
  170. * @return string
  171. */
  172. function xcache_get_opcode($opcode) {}
  173. /**
  174. * @param int $op_type
  175. * @return string
  176. */
  177. function xcache_get_op_spec($op_type) {}
  178. /**
  179. * @param int $opcode
  180. * @return string
  181. */
  182. function xcache_get_opcode_spec($opcode) {}
  183. /**
  184. * @param string $name
  185. * @return string
  186. */
  187. function xcache_is_autoglobal($name) {}