Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F7892728
caching.ex
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
caching.ex
View Options
# Pleroma: A lightweight social networking server
# Copyright © 2017-2022 Pleroma Authors <https://pleroma.social/>
# SPDX-License-Identifier: AGPL-3.0-only
defmodule
Pleroma.Caching
do
@callback
get!
(
Cachex
.
cache
(),
any
())
::
any
()
@callback
get
(
Cachex
.
cache
(),
any
())
::
{
atom
(),
any
()}
@callback
put
(
Cachex
.
cache
(),
any
(),
any
(),
Keyword
.
t
())
::
{
Cachex
.
status
(),
boolean
()}
@callback
put
(
Cachex
.
cache
(),
any
(),
any
())
::
{
Cachex
.
status
(),
boolean
()}
@callback
fetch!
(
Cachex
.
cache
(),
any
(),
function
()
|
nil
)
::
any
()
@callback
fetch
(
Cachex
.
cache
(),
any
(),
function
()
|
nil
)
::
{
atom
(),
any
()}
|
{
atom
(),
any
(),
any
()}
# @callback del(Cachex.cache(), any(), Keyword.t()) :: {Cachex.status(), boolean()}
@callback
del
(
Cachex
.
cache
(),
any
())
::
{
Cachex
.
status
(),
boolean
()}
@callback
stream!
(
Cachex
.
cache
(),
any
())
::
Enumerable
.
t
()
@callback
expire_at
(
Cachex
.
cache
(),
binary
(),
number
())
::
{
Cachex
.
status
(),
boolean
()}
@callback
expire
(
Cachex
.
cache
(),
binary
(),
number
())
::
{
Cachex
.
status
(),
boolean
()}
@callback
exists?
(
Cachex
.
cache
(),
any
())
::
{
Cachex
.
status
(),
boolean
()}
@callback
execute!
(
Cachex
.
cache
(),
function
())
::
any
()
@callback
get_and_update
(
Cachex
.
cache
(),
any
(),
function
())
::
{
:commit
|
:ignore
,
any
()}
end
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Oct 2, 4:36 AM (1 d, 8 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
471484
Default Alt Text
caching.ex (1 KB)
Attached To
Mode
rPUBE pleroma-upstream
Attached
Detach File
Event Timeline
Log In to Comment