class Walk::Down::Filter(T)

Included Modules

Defined in:

walk/down/filter.cr

Constructors

Instance Method Summary

Macro Summary

Constructor Detail

def self.new(iterator : T, &predicate : Path -> Bool) #

[View source]

Instance Method Detail

def iterator : T #

Properties


[View source]
def iterator=(iterator : T) #

Properties


[View source]
def next #

Returns the next element.

Yields only entries which satisfy the given predicate and skips descending into directories that do not satisfy the given predicate.

The predicate is applied to all entries. If the predicate is true, iteration carries on as normal. If the predicate is false, the entry is ignored and if it is a directory, it is not descended into.


[View source]
def predicate : Path -> Bool #

[View source]
def predicate=(predicate : Path -> Bool) #

[View source]
def rewind #

Rewinds iterator.


[View source]

Macro Detail

macro wrapped_skip #

[View source]