Interface DistributionPackage
A distribution package
-
Method Summary
Modifier and TypeMethodDescriptionvoidclose()closes all resources associated with this instance@NotNull InputStreamcreates a package stream.voiddelete()releases all resources associated with this package@NotNull StringgetId()get package id.@NotNull DistributionPackageInfogetInfo()gets an additional info holder for this package.longgetSize()@NotNull StringgetType()get the type of package
-
Method Details
-
getId
get package id. the id is a unique string that can be used to identify the package- Returns:
- the package id
-
getType
get the type of package- Returns:
- the package type
-
createInputStream
creates a package stream. a new stream is created for each call and it is the caller's obligation to close the stream.- Returns:
- an
InputStream - Throws:
IOException- if stream create fails
-
getSize
long getSize()- Returns:
- the size in bytes
-
close
void close()closes all resources associated with this instance -
delete
void delete()releases all resources associated with this package -
getInfo
gets an additional info holder for this package. The additional info object contains control information rather than content information. For example info.origin can be used to skip distributing back to the originating endpoint.- Returns:
- the associated metadata to this package
-