Class: Array

Inherits:
Object show all
Defined in:
ext/fipdf/src/fachinfo_writer.rb

Instance Method Summary collapse

Instance Method Details

#obj_path(id, obj_path_id = nil) ⇒ Object



74
75
76
77
78
79
80
81
82
83
84
85
86
# File 'ext/fipdf/src/fachinfo_writer.rb', line 74

def obj_path(id, obj_path_id=nil)
	super or begin
		each_with_index { |item, idx|
			if(item.__id__ == id)
				return [idx]
			elsif(path = item.obj_path(id, obj_path_id))
				path.unshift(idx)
				return path
			end
		}
		nil
	end
end