Method: BinData::Base#rel_offset

Defined in:
lib/bindata/base.rb

#rel_offsetObject

Returns the offset (in bytes) of this object with respect to its parent.



223
224
225
226
227
228
229
# File 'lib/bindata/base.rb', line 223

def rel_offset
  if @parent
    @parent.offset_of(self)
  else
    0
  end
end