@@ -27,17 +27,17 @@ defmodule Cachex.Router do
2727
2828 Please see all child implementations for supported options.
2929 """
30- @ callback init ( cache :: Cachex . t ( ) , options :: Keyword . t ( ) ) :: any
30+ @ callback init ( cache :: Cachex . t ( ) , options :: Keyword . t ( ) ) :: any ( )
3131
3232 @ doc """
3333 Retrieve the list of nodes from a routing state.
3434 """
35- @ callback nodes ( state :: any ) :: [ atom ]
35+ @ callback nodes ( state :: any ( ) ) :: [ atom ( ) ]
3636
3737 @ doc """
3838 Route a key to a node in a routing state.
3939 """
40- @ callback route ( state :: any , key :: any ) :: atom
40+ @ callback route ( state :: any ( ) , key :: any ( ) ) :: atom ( )
4141
4242 @ doc """
4343 Create a child specification to back a routing state.
@@ -74,22 +74,22 @@ defmodule Cachex.Router do
7474 @ doc """
7575 Retrieve all currently connected nodes (including this one).
7676 """
77- @ spec connected ( ) :: [ atom ]
77+ @ spec connected ( ) :: [ atom ( ) ]
7878 def connected ( ) ,
7979 do: [ node ( ) | :erlang . nodes ( :connected ) ]
8080
8181 @ doc """
8282 Retrieve all routable nodes for a cache.
8383 """
84- @ spec nodes ( cache :: Cachex . t ( ) ) :: { :ok , [ atom ] }
84+ @ spec nodes ( cache :: Cachex . t ( ) ) :: { :ok , [ atom ( ) ] }
8585 def nodes ( cache ( router: router ( module: module , state: state ) ) ) ,
8686 do: { :ok , module . nodes ( state ) }
8787
8888 @ doc """
8989 Executes a previously dispatched action..
9090 """
9191 # The first match short circuits local-only caches
92- @ spec route ( Cachex . t ( ) , atom , { atom , [ any ] } ) :: any
92+ @ spec route ( Cachex . t ( ) , atom ( ) , { atom ( ) , [ any ( ) ] } ) :: any ( )
9393 def route ( cache ( router: router ( module: Router.Local ) ) = cache , module , call ) ,
9494 do: route_local ( cache , module , call )
9595
0 commit comments