Object -
cache
:
AbstractEvictionPolicy
The cache:AbstractEvictionPolicy
Ballerina object is used for custom implementations of the eviction policy for a
Ballerina cache object. Any custom eviction policy implementation should be object-wise similar.
Methods
Parameters
- list LinkedList
-
Linked list data structure, which is used to govern the eviction policy
- node Node
-
Node of the linked list, which is retrieved
Parameters
- list LinkedList
-
Linked list data structure, which is used to govern the eviction policy
- node Node
-
Node of the linked list, which is added newly
Parameters
- list LinkedList
-
Linked list data structure, which is used to govern the eviction policy
- node Node
-
Node of the linked list, which is deleted
Parameters
- list LinkedList
-
Linked list data structure, which is used to govern the eviction policy
- newNode Node
-
Node of the linked list, which will be replacing the
oldNode
- oldNode Node
-
Node of the linked list, which will be replaced by the
newNode
Parameters
- list LinkedList
-
Linked list data structure, which is used to govern the eviction policy
Parameters
- list LinkedList
-
Linked list data structure, which is used to govern the eviction policy
-
Return Type
(Node?) The Node, which is evicted from the linked list or
()
if nothing to be evicted