Results for: "strip"

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

Returns value specified by the member name of VT_RECORD OLE object. If the member name is not correct, KeyError exception is raised. If you can’t access member variable of VT_RECORD OLE object directly, use this method.

If COM server in VB.NET ComServer project is the following:

Imports System.Runtime.InteropServices
Public Class ComClass
    Public Structure ComObject
        Public object_id As Ineger
    End Structure
End Class

and Ruby Object class has title attribute:

then accessing object_id of ComObject from Ruby is as the following:

srver = WIN32OLE.new('ComServer.ComClass')
obj = WIN32OLE_RECORD.new('ComObject', server)
# obj.object_id returns Ruby Object#object_id
obj.ole_instance_variable_get(:object_id) # => nil

Sets value specified by the member name of VT_RECORD OLE object. If the member name is not correct, KeyError exception is raised. If you can’t set value of member of VT_RECORD OLE object directly, use this method.

If COM server in VB.NET ComServer project is the following:

Imports System.Runtime.InteropServices
Public Class ComClass
    <MarshalAs(UnmanagedType.BStr)> _
    Public title As String
    Public cost As Integer
End Class

then setting value of the ‘title’ member is as following:

srver = WIN32OLE.new('ComServer.ComClass')
obj = WIN32OLE_RECORD.new('Book', server)
obj.ole_instance_variable_set(:title, "The Ruby Book")

Starts tracing object allocations.

Stop tracing object allocations.

Note that if ::trace_object_allocations_start is called n-times, then tracing will stop after calling ::trace_object_allocations_stop n-times.

Raises NoMemoryError when allocating an instance of the given classes.

No longer raises NoMemoryError when allocating an instance of the given classes.

The iterator version of the strongly_connected_components method. obj.each_strongly_connected_component is similar to obj.strongly_connected_components.each, but modification of obj during the iteration may lead to unexpected results.

each_strongly_connected_component returns nil.

class G
  include TSort
  def initialize(g)
    @g = g
  end
  def tsort_each_child(n, &b) @g[n].each(&b) end
  def tsort_each_node(&b) @g.each_key(&b) end
end

graph = G.new({1=>[2, 3], 2=>[4], 3=>[2, 4], 4=>[]})
graph.each_strongly_connected_component {|scc| p scc }
#=> [4]
#   [2]
#   [3]
#   [1]

graph = G.new({1=>[2], 2=>[3, 4], 3=>[2], 4=>[]})
graph.each_strongly_connected_component {|scc| p scc }
#=> [4]
#   [2, 3]
#   [1]

The iterator version of the TSort.strongly_connected_components method.

The graph is represented by each_node and each_child. each_node should have call method which yields for each node in the graph. each_child should have call method which takes a node argument and yields for each child node.

g = {1=>[2, 3], 2=>[4], 3=>[2, 4], 4=>[]}
each_node = lambda {|&b| g.each_key(&b) }
each_child = lambda {|n, &b| g[n].each(&b) }
TSort.each_strongly_connected_component(each_node, each_child) {|scc| p scc }
#=> [4]
#   [2]
#   [3]
#   [1]

g = {1=>[2], 2=>[3, 4], 3=>[2], 4=>[]}
each_node = lambda {|&b| g.each_key(&b) }
each_child = lambda {|n, &b| g[n].each(&b) }
TSort.each_strongly_connected_component(each_node, each_child) {|scc| p scc }
#=> [4]
#   [2, 3]
#   [1]
No documentation available
No documentation available
No documentation available

Convert internal ID of token symbol to the string.

Creates a new Socket::Option object for IP_MULTICAST_TTL.

The size is dependent on the platform.

p Socket::Option.ipv4_multicast_ttl(10)
#=> #<Socket::Option: INET IP MULTICAST_TTL 10>

Returns the ipv4_multicast_ttl data in sockopt as an integer.

sockopt = Socket::Option.ipv4_multicast_ttl(10)
p sockopt.ipv4_multicast_ttl => 10

Creates a new Socket::Option object for IP_MULTICAST_LOOP.

The size is dependent on the platform.

sockopt = Socket::Option.int(:INET, :IPPROTO_IP, :IP_MULTICAST_LOOP, 1)
p sockopt.int => 1

p Socket::Option.ipv4_multicast_loop(10)
#=> #<Socket::Option: INET IP MULTICAST_LOOP 10>

Returns the ipv4_multicast_loop data in sockopt as an integer.

sockopt = Socket::Option.ipv4_multicast_loop(10)
p sockopt.ipv4_multicast_loop => 10

Specification attributes that must be non-nil

Expire memoized instance variables that can incorrectly generate, replace or miss files due changes in certain attributes used to compute them.

Creates a regular expression to match IPv4 addresses

Returns the inverse of the eigenvector matrix V

No documentation available
Search took: 4ms  ·  Total Results: 1841