Archive.Entry (Archive v0.4.0)

Archive.Entry represents a single item in an archive.

Most functions in this module will only work within the context of the aupplied mapping function given to Archive.read/3. This is because these functions require a reference to the archive while streaming and while the entry is the current item in the stream.

Summary

Functions

Creates a new Archive.Entry struct. This is done implicitly during Archive.read/3.

Loads the entry data into the archive. The archive is automatically passed to the current entry during Archive.read/3, Archive.from_memory_streaming/3, and Archive.from_file_streaming/3.

Types

@type t() :: %Archive.Entry{
  data: binary() | nil,
  path: String.t(),
  stat: File.Stat.t()
}

Functions

Link to this function

extract(entry, stream, opts \\ [])

Link to this function

new(fields \\ [])

Creates a new Archive.Entry struct. This is done implicitly during Archive.read/3.

Link to this function

new!(fields \\ [])

Link to this function

read_data(e, arg2)

Loads the entry data into the archive. The archive is automatically passed to the current entry during Archive.read/3, Archive.from_memory_streaming/3, and Archive.from_file_streaming/3.

Link to this function

read_data!(entry, archive)

Link to this function

read_header(entry, stream)

Link to this function

write_header(entry, stream)