Top Level Namespace

Defined Under Namespace

Modules: Nokogiri, XSD

Constant Summary collapse

ROOT =
File.expand_path(File.join(File.dirname(__FILE__), '..', '..'))
LIBDIR =
INCLUDEDIR =
HEADER_DIRS =
[
  # First search /opt/local for macports
  '/opt/local/include',

  # Then search /usr/local for people that installed from source
  '/usr/local/include',

  # Check the ruby install locations
  INCLUDEDIR,

  # Finally fall back to /usr
  '/usr/include',
  '/usr/include/libxml2',
]
LIB_DIRS =
[
  # First search /opt/local for macports
  '/opt/local/lib',

  # Then search /usr/local for people that installed from source
  '/usr/local/lib',

  # Check the ruby install locations
  LIBDIR,

  # Finally fall back to /usr
  '/usr/lib',
]

Instance Method Summary collapse

Instance Method Details

#asplode(lib) ⇒ Object



71
72
73
# File 'ext/nokogiri/extconf.rb', line 71

def asplode(lib)
  abort "-----\n#{lib} is missing.  please visit http://nokogiri.org/tutorials/installing_nokogiri.html for help with installing dependencies.\n-----"
end

#Nokogiri(*args, &block) ⇒ Object

Parser a document contained in args. Nokogiri will try to guess what type of document you are attempting to parse. For more information, see Nokogiri.parse

To specify the type of document, use Nokogiri.XML or Nokogiri.HTML.



126
127
128
129
130
131
132
133
# File 'lib/nokogiri.rb', line 126

def Nokogiri(*args, &block)
  if block_given?
    builder = Nokogiri::HTML::Builder.new(&block)
    return builder.doc.root
  else
    Nokogiri.parse(*args)
  end
end