Skip to content

struct Crystal::Matches
inherits Struct

Included modules

Enumerable

Class methods

.new(matches, cover, owner = nil, success = true)

View source

Methods

#[](*args)

View source

#cover : Bool | Cover | Nil

View source

#cover=(cover : Bool | Cover | Nil)

View source

#cover_all?

View source

#each

Must yield this collection's elements to the block.

View source

#empty?

Returns true if self is empty, false otherwise.

([] of Int32).empty? # => true
([1]).empty?         # => false
View source

#matches : Array(Match)?

View source

#matches=(matches : Array(Match)?)

View source

#owner : Type?

View source

#owner=(owner : Type?)

View source

#size

Returns the number of elements in the collection.

[1, 2, 3, 4].size # => 4
View source