Results for: "Pathname"

According to the XML spec, a root node has no expanded name

Adds a namespace to this element.

prefix

the prefix string, or the namespace URI if uri is not supplied

uri

the namespace URI. May be nil, in which prefix is used as the URI

Evaluates to: this Element

a = Element.new("a")
a.add_namespace("xmlns:foo", "bar" )
a.add_namespace("foo", "bar")  # shorthand for previous line
a.add_namespace("twiddle")
puts a   #-> <a xmlns:foo='bar' xmlns='twiddle'/>

Removes a namespace from this node. This only works if the namespace is actually declared in this node. If no argument is passed, deletes the default namespace.

Evaluates to: this element

doc = Document.new "<a xmlns:foo='bar' xmlns='twiddle'/>"
doc.root.delete_namespace
puts doc     # -> <a xmlns:foo='bar'/>
doc.root.delete_namespace 'foo'
puts doc     # -> <a/>

Returns a String namespace for a node, given a prefix The rules are:

1. Use the supplied namespace mapping first.
2. If no mapping was supplied, use the context node to look up the namespace

Return the list of all instance variables.

CommandProcessor#expand_path(path)

  path:   String
  return: String
returns the absolute path for <path>

Merges a base path base, with relative path rel, returns a modified base path.

No documentation available
No documentation available
No documentation available

Helper method.

Returns the name of the cipher which may differ slightly from the original name provided.

Returns the sn of this Digest algorithm.

Example

digest = OpenSSL::Digest::SHA512.new
puts digest.name # => SHA512

Get the descriptive name for this engine.

OpenSSL::Engine.load
OpenSSL::Engine.engines #=> [#<OpenSSL::Engine#>, ...]
OpenSSL::Engine.engines.first.name
  #=> "RSAX engine support"

Convert path string to a class

The file name of the input.

Returns the interface name of ifaddr.

returns the socket option name as an integer.

p Socket::Option.new(:INET6, :IPV6, :RECVPKTINFO, [1].pack("i!")).optname
#=> 2

Returns the path of this instruction sequence.

<compiled> if the iseq was evaluated from a string.

For example, using irb:

iseq = RubyVM::InstructionSequence.compile('num = 1 + 2')
#=> <RubyVM::InstructionSequence:<compiled>@<compiled>>
iseq.path
#=> "<compiled>"

Using ::compile_file:

# /tmp/method.rb
def hello
  puts "hello, world"
end

# in irb
> iseq = RubyVM::InstructionSequence.compile_file('/tmp/method.rb')
> iseq.path #=> /tmp/method.rb

Renames a file on the server.

Sends a RENAME command to change the name of the mailbox to newname.

A Net::IMAP::NoResponseError is raised if a mailbox with the name mailbox cannot be renamed to newname for whatever reason; for instance, because mailbox does not exist, or because there is already a mailbox with the name newname.

Returns the path from an FTP URI.

RFC 1738 specifically states that the path for an FTP URI does not include the / which separates the URI path from the URI host. Example:

ftp://ftp.example.com/pub/ruby

The above URI indicates that the client should connect to ftp.example.com then cd pub/ruby from the initial login directory.

If you want to cd to an absolute directory, you must include an escaped / (%2F) in the path. Example:

+ftp.example.com/%2Fpub/ruby+

This method will then return “/pub/ruby”

Gets the hostname of address from the hosts file.

Gets all hostnames for address from the hosts file.

Gets the hostname for address from the DNS resolver.

address must be a Resolv::IPv4, Resolv::IPv6 or a String. Retrieved name will be a Resolv::DNS::Name.

Search took: 3ms  ·  Total Results: 2628