You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
All libxml classes are in the `LibXML::XML` module. The easiest
100
-
way to use libxml is to `require 'xml'`. This will mixin
101
-
the LibXML module into the global namespace, allowing you to
102
-
write code like this:
103
-
104
-
```ruby
105
-
require'xml'
106
-
document =XML::Document.new
107
-
```
108
-
109
-
However, when creating an application or library you plan to
110
-
redistribute, it is best to not add the LibXML module to the global
111
-
namespace, in which case you can either write your code like this:
112
-
113
-
```ruby
114
-
require'libxml'
115
-
document =LibXML::XML::Document.new
116
-
```
117
-
118
-
Or you can utilize a namespace for your own work and include LibXML into it.
119
-
For example:
120
-
121
-
```ruby
122
-
require'libxml'
123
-
124
-
moduleMyApplication
125
-
includeLibXML
126
-
127
-
classMyClass
128
-
defsome_method
129
-
document =XML::Document.new
130
-
end
131
-
end
132
-
end
133
-
```
134
-
135
-
For simplicity's sake, the documentation uses the xml module in its examples.
46
+
Full documentation is available at [xml4r.github.io/libxml-ruby](https://xml4r.github.io/libxml-ruby/) including a [getting started](https://xml4r.github.io/libxml-ruby/getting_started/) guide.
136
47
137
48
## Tests
138
49
@@ -148,14 +59,6 @@ Once you have built the shared library, you can then run tests using rake:
0 commit comments