Results for: "max_by"

Escapes all possible entities

Unescapes all possible entities

No documentation available
No documentation available
No documentation available
No documentation available
No documentation available
No documentation available
No documentation available
No documentation available
No documentation available
No documentation available
No documentation available

Does this dependency request match spec?

NOTE: match? only matches prerelease versions when dependency is a prerelease dependency.

Returns a new lazy enumerator with the concatenated results of running block once for every element in lazy.

["foo", "bar"].lazy.flat_map {|i| i.each_char.lazy}.force
#=> ["f", "o", "o", "b", "a", "r"]

A value x returned by block is decomposed if either of the following conditions is true:

a) <i>x</i> responds to both each and force, which means that
   <i>x</i> is a lazy enumerator.
b) <i>x</i> is an array or responds to to_ary.

Otherwise, x is contained as-is in the return value.

[{a:1}, {b:2}].lazy.flat_map {|i| i}.force
#=> [{:a=>1}, {:b=>2}]

Emit a sequence with map and tag

Called when a map starts.

anchor is the anchor associated with the map or nil. tag is the tag associated with the map or nil. implicit is a boolean indicating whether or not the map was implicitly started. style is an integer indicating the mapping style.

See the constants in Psych::Nodes::Mapping for the possible values of style.

Example

Here is a YAML document that exercises most of the possible ways this method can be called:

---
k: !!map { hello: world }
v: &pewpew
  hello: world

The above YAML document consists of three maps, an outer map that contains two inner maps. Below is a matrix of the parameters sent in order to represent these three maps:

# anchor    tag                       implicit  style
[nil,       nil,                      true,     1     ]
[nil,       "tag:yaml.org,2002:map",  false,    2     ]
["pewpew",  nil,                      true,     1     ]

Called when a map ends

Start emitting a YAML map with anchor, tag, an implicit start and end, and style.

See Psych::Handler#start_mapping

Emit the end of a mapping.

See Psych::Handler#end_mapping

Builds a methods for level meth.

Returns the major part of File_Stat#dev or nil.

File.stat("/dev/fd1").dev_major   #=> 2
File.stat("/dev/tty").dev_major   #=> 5

Returns the major part of File_Stat#rdev or nil.

File.stat("/dev/fd1").rdev_major   #=> 2
File.stat("/dev/tty").rdev_major   #=> 5

Sets the rubygems_version to the current RubyGems version.

Backport of performance enhancement added to RubyGems 1.4

Search took: 3ms  ·  Total Results: 647