docs: deprecate unnecessary API
This commit is contained in:
parent
7ff565aacb
commit
548db12b07
1 changed files with 12 additions and 0 deletions
|
@ -14,11 +14,19 @@ pub enum CompressionMethod {
|
||||||
#[cfg(feature = "bzip2")]
|
#[cfg(feature = "bzip2")]
|
||||||
Bzip2,
|
Bzip2,
|
||||||
/// Unsupported compression method
|
/// Unsupported compression method
|
||||||
|
#[deprecated(
|
||||||
|
since = "0.5.7",
|
||||||
|
note = "implementation details are being removed from the public API"
|
||||||
|
)]
|
||||||
Unsupported(u16),
|
Unsupported(u16),
|
||||||
}
|
}
|
||||||
|
|
||||||
impl CompressionMethod {
|
impl CompressionMethod {
|
||||||
/// Converts an u16 to its corresponding CompressionMethod
|
/// Converts an u16 to its corresponding CompressionMethod
|
||||||
|
#[deprecated(
|
||||||
|
since = "0.5.7",
|
||||||
|
note = "implementation details are being removed from the public API"
|
||||||
|
)]
|
||||||
pub fn from_u16(val: u16) -> CompressionMethod {
|
pub fn from_u16(val: u16) -> CompressionMethod {
|
||||||
match val {
|
match val {
|
||||||
0 => CompressionMethod::Stored,
|
0 => CompressionMethod::Stored,
|
||||||
|
@ -31,6 +39,10 @@ impl CompressionMethod {
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Converts a CompressionMethod to a u16
|
/// Converts a CompressionMethod to a u16
|
||||||
|
#[deprecated(
|
||||||
|
since = "0.5.7",
|
||||||
|
note = "implementation details are being removed from the public API"
|
||||||
|
)]
|
||||||
pub fn to_u16(self) -> u16 {
|
pub fn to_u16(self) -> u16 {
|
||||||
match self {
|
match self {
|
||||||
CompressionMethod::Stored => 0,
|
CompressionMethod::Stored => 0,
|
||||||
|
|
Loading…
Add table
Reference in a new issue