README

wqbcs/moon_collections/counter does not have a README file

#
Counter

impl Collection for Counter[K]

#
Counter::add

fn[K : Hash + Eq] Counter::add(self : Counter[K], key : K) -> Unit

#
Counter::add_counter

fn[K : Hash + Eq] Counter::add_counter(self : Counter[K], other : Counter[K]) -> Counter[K]

#
Counter::clear

fn[K : Hash + Eq] Counter::clear(self : Counter[K]) -> Unit

#
Counter::contains

fn[K : Hash + Eq] Counter::contains(self : Counter[K], key : K) -> Bool

#
Counter::each

fn[K] Counter::each(self : Counter[K], f : (K, Int) -> Unit) -> Unit

#
Counter::elements

fn[K] Counter::elements(self : Counter[K]) -> Array[K]

#
Counter::filter

fn[K : Hash + Eq] Counter::filter(self : Counter[K], pred : (K, Int) -> Bool) -> Counter[K]

#
Counter::from_array

fn[K : Hash + Eq] Counter::from_array(items : Array[K]) -> Counter[K]

#
Counter::from_array_with_weight

fn[K : Hash + Eq] Counter::from_array_with_weight(items : Array[(K, Int)]) -> Counter[K]

#
Counter::get

fn[K : Hash + Eq] Counter::get(self : Counter[K], key : K) -> Int

#
Counter::is_empty

fn[K] Counter::is_empty(self : Counter[K]) -> Bool

#
Counter::items

fn[K] Counter::items(self : Counter[K]) -> Array[(K, Int)]

#
Counter::iter

fn[K] Counter::iter(self : Counter[K]) -> Iter[(K, Int)]

#
Counter::keys

fn[K] Counter::keys(self : Counter[K]) -> Iter[K]

#
Counter::keys_array

fn[K] Counter::keys_array(self : Counter[K]) -> Array[K]

#
Counter::len

fn[K] Counter::len(self : Counter[K]) -> Int

#
Counter::map_keys

fn[K, R : Hash + Eq] Counter::map_keys(self : Counter[K], f : (K) -> R) -> Counter[R]

#
Counter::max_count

fn[K] Counter::max_count(self : Counter[K]) -> Int

#
Counter::min_count

fn[K] Counter::min_count(self : Counter[K]) -> Int

#
Counter::most_common

fn[K : Hash + Eq] Counter::most_common(self : Counter[K], n : Int) -> Array[(K, Int)]

#
Counter::new

fn[K : Hash + Eq] Counter::new() -> Counter[K]

#
Counter::remove

fn[K : Hash + Eq] Counter::remove(self : Counter[K], key : K) -> Int

#
Counter::retain

fn[K : Hash + Eq] Counter::retain(self : Counter[K], pred : (K, Int) -> Bool) -> Unit

#
Counter::scale

fn[K : Hash + Eq] Counter::scale(self : Counter[K], factor : Int) -> Counter[K]

#
Counter::set

fn[K : Hash + Eq] Counter::set(self : Counter[K], key : K, count : Int) -> Unit

#
Counter::subtract

fn[K : Hash + Eq] Counter::subtract(self : Counter[K], key : K) -> Unit

#
Counter::subtract_counter

fn[K : Hash + Eq] Counter::subtract_counter(self : Counter[K], other : Counter[K]) -> Counter[K]

#
Counter::total

fn[K] Counter::total(self : Counter[K]) -> Int

Source Files