Class: Numeric

Inherits
Object show all
Defined in
lib/kyanite/array.rb,
lib/kyanite/numeric.rb,
lib/kyanite/string/split.rb,
lib/kyanite/general/kernel.rb

Instance Method Summary (collapse)

Instance Method Details

- (Object) seconds(&block)

Repeats a block until the time is up. Returns the number of passes. All Exceptions are caught (=> bad blocks seem to run faster). Example (using Numeric):

3.seconds do
 puts Time.now.inspect
end

Example (using KKernel):

repeat_n_seconds 3 do
 puts Time.now.inspect
end


78
79
80
81
82
# File 'lib/kyanite/general/kernel.rb', line 78

def seconds( &block )
  repeat_n_seconds( self ) do 
        yield block if block    
  end
end

- (NilClass) shift_complement

nil, Complements Array#shift_complement.

Returns:



122
123
124
# File 'lib/kyanite/array.rb', line 122

def shift_complement 
  nil
end

- (Numeric) split_numeric

self, complements String#split_numeric.

Returns:



165
166
167
# File 'lib/kyanite/string/split.rb', line 165

def split_numeric 
    self 
end