filter

File filter.str
Author unknown
Since unknown

This module contains strategies for filtering and partitioninglists.




Statistics


General
Lines of code 115
Stratego
Module number 1 (100% documented)
Constructor number 0
Overlay number 0
Strategy number 13 (69% documented)
Rule number 0
DynamicRule number 0



Strategy summary


filter(Strategy s) n/a filter.str
filter(Strategy s, Strategy tail) n/a filter.str
partition(Strategy s) n/a filter.str
partition(Strategy s1, Strategy s2) Partitions a list into a tuple of two lists filter.str
remove-all(Strategy s) Removes all elements from a list that satisfy s filter.str
retain-all(Strategy s) Returns all elements in a list that satisfy s, as a list filter.str
reverse-filter(Strategy s) Returns all elements in a list that satisfy s, as a list filter.str
reverse-filter(Strategy s, Strategy tail) n/a filter.str



Strategy details


ATerm partition(Strategy s1, Strategy s2)
File filter.str
Author unknown
Since unknown
 
Parameters
Strategy s1 s1 a -> b
Strategy s2 s2 a -> c

Partitions a list into a tuple of two lists.


type List(a) -> (List(b), List(c))

 
ATerm remove-all(Strategy s)
File filter.str
Author unknown
Since unknown
 
Parameters
Strategy s s a -> b

Removes all elements from a list that satisfy s


type List(a) -> List(a)

 
ATerm retain-all(Strategy s)
File filter.str
Author unknown
Since unknown
 
Parameters
Strategy s s a -> b

Returns all elements in a list that satisfy s, as a list.


type List(a) -> List(b)

 
ATerm reverse-filter(Strategy s)
File filter.str
Author unknown
Since unknown
 
Parameters
Strategy s s a -> b

Returns all elements in a list that satisfy s, as a list.Traverses the list in reverse order.


type List(a) -> List(b)