Method: Zip::ZipExtraField::UniversalTime#merge

Defined in:
lib/pik/contrib/zip/zip.rb

#merge(binstr) ⇒ Object



1692
1693
1694
1695
1696
1697
1698
1699
1700
# File 'lib/pik/contrib/zip/zip.rb', line 1692

def merge(binstr)
  binstr == "" and return
  size, content = initial_parse(binstr)
  size or return
  @flag, mtime, atime, ctime = content.unpack("CVVV")
  mtime and @mtime ||= Time.at(mtime)
  atime and @atime ||= Time.at(atime)
  ctime and @ctime ||= Time.at(ctime)
end