Skip to content

Commit 1e92d05

Browse files
pietroalbinijplatte
authored andcommitted
link: publish link as a module instead of re-exporting types
1 parent 92e6752 commit 1e92d05

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

src/common/link.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
//! Link header and types.
2+
13
use std::fmt;
24
use std::borrow::Cow;
35
use std::str::FromStr;
@@ -58,7 +60,7 @@ use {Header, Raw};
5860
/// # Examples
5961
///
6062
/// ```
61-
/// use headers::{Headers, Link, LinkValue, RelationType};
63+
/// use headers::{Headers, link::{Link, LinkValue, RelationType}};
6264
///
6365
/// let link_value = LinkValue::new("http://example.com/TheBook/chapter2")
6466
/// .push_rel(RelationType::Previous)

src/common/mod.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@ pub use self::if_range::IfRange;
4545
pub use self::if_unmodified_since::IfUnmodifiedSince;
4646
//pub use self::last_event_id::LastEventId;
4747
pub use self::last_modified::LastModified;
48-
pub use self::link::{Link, LinkValue, RelationType, MediaDesc};
4948
pub use self::location::Location;
5049
pub use self::origin::Origin;
5150
pub use self::pragma::Pragma;
@@ -165,7 +164,7 @@ mod if_range;
165164
mod if_unmodified_since;
166165
//mod last_event_id;
167166
mod last_modified;
168-
mod link;
167+
pub mod link;
169168
mod location;
170169
mod origin;
171170
mod pragma;

0 commit comments

Comments
 (0)