Results for: "Data"

Formats time as an IMAP-style date.

Formats time as an IMAP-style date-time.

No documentation available

A recommended version for use with a ~> Requirement.

No documentation available

Extracts the Gem::Specification and raw metadata from the .gem file at path.

Content: [ String text ]

No documentation available

When invoked with a block, yields all repeated combinations of length n of elements from the array and then returns the array itself.

The implementation makes no guarantees about the order in which the repeated combinations are yielded.

If no block is given, an Enumerator is returned instead.

Examples:

a = [1, 2, 3]
a.repeated_combination(1).to_a  #=> [[1], [2], [3]]
a.repeated_combination(2).to_a  #=> [[1,1],[1,2],[1,3],[2,2],[2,3],[3,3]]
a.repeated_combination(3).to_a  #=> [[1,1,1],[1,1,2],[1,1,3],[1,2,2],[1,2,3],
                                #    [1,3,3],[2,2,2],[2,2,3],[2,3,3],[3,3,3]]
a.repeated_combination(4).to_a  #=> [[1,1,1,1],[1,1,1,2],[1,1,1,3],[1,1,2,2],[1,1,2,3],
                                #    [1,1,3,3],[1,2,2,2],[1,2,2,3],[1,2,3,3],[1,3,3,3],
                                #    [2,2,2,2],[2,2,2,3],[2,2,3,3],[2,3,3,3],[3,3,3,3]]
a.repeated_combination(0).to_a  #=> [[]] # one combination of length 0

Makes a list of existing constants private.

Makes a list of existing constants deprecated.

Returns true if the given calendar date is valid, and false if not.

Date.valid_date?(2001,2,3)        #=> true
Date.valid_date?(2001,2,29)       #=> false

See also ::jd and ::civil.

Returns self.

Returns a DateTime object which denotes self.

Returns a Date object which denotes self.

Returns self.

Returns a Date object which denotes self.

Returns a DateTime object which denotes self.

Returns true if this class can be used to create an instance from a serialised JSON string. The class has to implement a class method json_create that expects a hash as first parameter. The hash should include the required data.

Returns garbage collector generation for the given object.

class B
  include ObjectSpace

  def foo
    trace_object_allocations do
      obj = Object.new
      p "Generation is #{allocation_generation(obj)}"
    end
  end
end

B.new.foo #=> "Generation is 3"

See ::trace_object_allocations for more information and examples.

How String Gem paths should be split. Overridable for esoteric platforms.

Takes a hash as its argument. The key is a symbol or an array of symbols. These symbols correspond to method names. The value is the accessor to which the methods will be delegated.

Returns the status of the last executed child process in the current thread.

Process.wait Process.spawn("ruby", "-e", "exit 13")
Process.last_status   #=> #<Process::Status: pid 4825 exit 13>

If no child process has ever been executed in the current thread, this returns nil.

Process.last_status   #=> nil

Update the digest using given string and return self.

Encrypts data in a streaming fashion. Hand consecutive blocks of data to the update method in order to encrypt it. Returns the encrypted data chunk. When done, the output of Cipher#final should be additionally added to the result.

If buffer is given, the encryption/decryption result will be written to it. buffer will be resized automatically.

Search took: 6ms  ·  Total Results: 1681