Module: ProvaVhm::Raw2Xml

Extended by:
FFI::Library
Defined in:
lib/prova-vhm-raw2xml.rb

Class Method Summary collapse

Class Method Details

.running_on_a_mac?Boolean

Returns:

  • (Boolean)


18
19
20
# File 'lib/prova-vhm-raw2xml.rb', line 18

def running_on_a_mac?
  RUBY_PLATFORM =~ /-darwin\d/
end

.running_on_windows?Boolean

Returns:

  • (Boolean)


14
15
16
# File 'lib/prova-vhm-raw2xml.rb', line 14

def running_on_windows?
  RUBY_PLATFORM =~ /mswin32|mingw32/
end

.shared_library_pathObject



8
9
10
11
12
# File 'lib/prova-vhm-raw2xml.rb', line 8

def shared_library_path
  abort("Windows isn't supported by this gem") if running_on_windows?
  File.expand_path(File.dirname(__FILE__) +
                       "/libZVLParser/#{running_on_a_mac? ? 'mac' : 'linux'}/libZVLParser64.so")
end