public class Layer extends Object implements Content
ImageArchive.| Modifier and Type | Method and Description |
|---|---|
static Layer |
fromTarArchive(TarArchive tarArchive)
Factory method to create a new
Layer from a TarArchive. |
LayerId |
getId()
Return the ID of the layer.
|
static Layer |
of(IOConsumer<Layout> layout)
|
int |
size()
The size of the content in bytes.
|
void |
writeTo(OutputStream outputStream)
Write the content to the given output stream.
|
public LayerId getId()
public int size()
Contentpublic void writeTo(OutputStream outputStream) throws IOException
ContentwriteTo in interface ContentoutputStream - the output stream to write toIOException - on IO errorpublic static Layer of(IOConsumer<Layout> layout) throws IOException
layout - the layer layoutIOException - on IO errorpublic static Layer fromTarArchive(TarArchive tarArchive) throws IOException
Layer from a TarArchive.tarArchive - the contents of the layerIOException - on error