pub trait EmbedTechnique {
// Required methods
fn technique(&self) -> StegoTechnique;
fn capacity(&self, cover: &CoverMedia) -> Result<Capacity, StegoError>;
fn embed(
&self,
cover: CoverMedia,
payload: &Payload,
) -> Result<CoverMedia, StegoError>;
}Expand description
Embedding half of a steganographic technique.
Required Methods§
Sourcefn technique(&self) -> StegoTechnique
fn technique(&self) -> StegoTechnique
The technique identifier for this implementation.
Sourcefn capacity(&self, cover: &CoverMedia) -> Result<Capacity, StegoError>
fn capacity(&self, cover: &CoverMedia) -> Result<Capacity, StegoError>
Estimate how many payload bytes cover can hold.
§Errors
Returns StegoError::UnsupportedCoverType if the cover kind is
incompatible with this technique.
Sourcefn embed(
&self,
cover: CoverMedia,
payload: &Payload,
) -> Result<CoverMedia, StegoError>
fn embed( &self, cover: CoverMedia, payload: &Payload, ) -> Result<CoverMedia, StegoError>
Embed payload into cover, returning the stego cover.
§Errors
Returns StegoError::PayloadTooLarge or
StegoError::MalformedCoverData.