Sha256: 7fc8b0070dabfd24337c9ad04e8c859193049c5ec0802722a42edfc2baf2609f
Contents?: true
Size: 599 Bytes
Versions: 1
Compression:
Stored size: 599 Bytes
Contents
class TrueClass { "TrueClass. The class of the singleton @true value." def TrueClass new { # always return true singleton object when trying to create a new # TrueClass instance true } def if_true: block { "Calls @block." block call: [self] } def if_true: then_block else: else_block { "Calls @then_block." then_block call: [self] } def true? { "Returns @true." true } def to_s { "Returns @true as a @String@." "true" } def to_a { "Returns an empty @Array@." [] } def not { "Returns @false." false } }
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
fancy-0.3.3 | lib/true_class.fy |