Archive.Entry (Archive v0.2.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

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.

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

Types

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

Functions

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

load!(entry, archive)

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 \\ [])