OXIESEC PANEL
- Current Dir:
/
/
usr
/
lib
/
ruby
/
2.5.0
/
rexml
Server IP: 139.59.38.164
Upload:
Create Dir:
Name
Size
Modified
Perms
📁
..
-
05/09/2024 07:14:11 AM
rwxr-xr-x
📄
attlistdecl.rb
1.92 KB
12/16/2015 05:07:31 AM
rw-r--r--
📄
attribute.rb
5.53 KB
07/22/2016 01:39:49 AM
rw-r--r--
📄
cdata.rb
1.58 KB
12/12/2017 11:56:25 AM
rw-r--r--
📄
child.rb
2.66 KB
12/16/2015 05:07:31 AM
rw-r--r--
📄
comment.rb
2.12 KB
12/12/2017 11:56:25 AM
rw-r--r--
📄
doctype.rb
7.64 KB
05/15/2023 11:41:43 AM
rw-r--r--
📄
document.rb
9.51 KB
12/16/2015 05:07:31 AM
rw-r--r--
📁
dtd
-
05/09/2024 07:14:11 AM
rwxr-xr-x
📄
element.rb
44.38 KB
12/12/2017 11:56:25 AM
rw-r--r--
📄
encoding.rb
1.16 KB
12/16/2015 05:07:31 AM
rw-r--r--
📄
entity.rb
5.39 KB
11/02/2017 08:06:38 PM
rw-r--r--
📁
formatters
-
05/09/2024 07:14:11 AM
rwxr-xr-x
📄
functions.rb
11.9 KB
08/13/2017 12:14:24 PM
rw-r--r--
📄
instruction.rb
2.05 KB
12/12/2017 11:56:25 AM
rw-r--r--
📁
light
-
05/09/2024 07:14:11 AM
rwxr-xr-x
📄
namespace.rb
1.12 KB
12/16/2015 05:07:31 AM
rw-r--r--
📄
node.rb
2.17 KB
12/12/2017 11:56:25 AM
rw-r--r--
📄
output.rb
550 bytes
12/16/2015 05:07:31 AM
rw-r--r--
📄
parent.rb
4.27 KB
12/16/2015 05:07:31 AM
rw-r--r--
📄
parseexception.rb
1.25 KB
12/16/2015 05:07:31 AM
rw-r--r--
📁
parsers
-
05/09/2024 07:14:11 AM
rwxr-xr-x
📄
quickpath.rb
9.12 KB
05/17/2016 01:15:57 PM
rw-r--r--
📄
rexml.rb
1.32 KB
05/15/2023 11:41:43 AM
rw-r--r--
📄
sax2listener.rb
3.61 KB
12/16/2015 05:07:31 AM
rw-r--r--
📄
security.rb
824 bytes
12/16/2015 05:07:31 AM
rw-r--r--
📄
source.rb
7.64 KB
12/16/2015 05:07:31 AM
rw-r--r--
📄
streamlistener.rb
3.84 KB
12/16/2015 05:07:31 AM
rw-r--r--
📄
syncenumerator.rb
716 bytes
12/16/2015 05:07:31 AM
rw-r--r--
📄
text.rb
13.78 KB
12/12/2017 11:56:25 AM
rw-r--r--
📄
undefinednamespaceexception.rb
241 bytes
12/16/2015 05:07:31 AM
rw-r--r--
📁
validation
-
05/09/2024 07:14:11 AM
rwxr-xr-x
📄
xmldecl.rb
2.71 KB
12/16/2015 05:07:31 AM
rw-r--r--
📄
xmltokens.rb
2.32 KB
12/16/2015 05:07:31 AM
rw-r--r--
📄
xpath.rb
3.34 KB
12/16/2015 05:07:31 AM
rw-r--r--
📄
xpath_parser.rb
20.44 KB
05/17/2016 01:15:57 PM
rw-r--r--
Editing: child.rb
Close
# frozen_string_literal: false require "rexml/node" module REXML ## # A Child object is something contained by a parent, and this class # contains methods to support that. Most user code will not use this # class directly. class Child include Node attr_reader :parent # The Parent of this object # Constructor. Any inheritors of this class should call super to make # sure this method is called. # parent:: # if supplied, the parent of this child will be set to the # supplied value, and self will be added to the parent def initialize( parent = nil ) @parent = nil # Declare @parent, but don't define it. The next line sets the # parent. parent.add( self ) if parent end # Replaces this object with another object. Basically, calls # Parent.replace_child # # Returns:: self def replace_with( child ) @parent.replace_child( self, child ) self end # Removes this child from the parent. # # Returns:: self def remove unless @parent.nil? @parent.delete self end self end # Sets the parent of this child to the supplied argument. # # other:: # Must be a Parent object. If this object is the same object as the # existing parent of this child, no action is taken. Otherwise, this # child is removed from the current parent (if one exists), and is added # to the new parent. # Returns:: The parent added def parent=( other ) return @parent if @parent == other @parent.delete self if defined? @parent and @parent @parent = other end alias :next_sibling :next_sibling_node alias :previous_sibling :previous_sibling_node # Sets the next sibling of this child. This can be used to insert a child # after some other child. # a = Element.new("a") # b = a.add_element("b") # c = Element.new("c") # b.next_sibling = c # # => <a><b/><c/></a> def next_sibling=( other ) parent.insert_after self, other end # Sets the previous sibling of this child. This can be used to insert a # child before some other child. # a = Element.new("a") # b = a.add_element("b") # c = Element.new("c") # b.previous_sibling = c # # => <a><b/><c/></a> def previous_sibling=(other) parent.insert_before self, other end # Returns:: the document this child belongs to, or nil if this child # belongs to no document def document return parent.document unless parent.nil? nil end # This doesn't yet handle encodings def bytes document.encoding to_s end end end