pub struct LinkContent {
pub url: String,
pub title: Option<String>,
pub content: String,
pub content_type: LinkContentType,
pub metadata: LinkMetadata,
}Expand description
Extracted content from a URL — the full intelligence report.
Fields§
§url: StringThe original URL that was extracted.
title: Option<String>Title of the page/content.
content: StringThe extracted main text content.
content_type: LinkContentTypeClassification of the content type.
metadata: LinkMetadataMetadata about the content.
Implementations§
Source§impl LinkContent
impl LinkContent
Sourcepub fn new(
url: impl Into<String>,
content: impl Into<String>,
content_type: LinkContentType,
) -> Self
pub fn new( url: impl Into<String>, content: impl Into<String>, content_type: LinkContentType, ) -> Self
Create a new link content result.
Sourcepub fn with_title(self, title: impl Into<String>) -> Self
pub fn with_title(self, title: impl Into<String>) -> Self
Set the title.
Sourcepub fn with_metadata(self, metadata: LinkMetadata) -> Self
pub fn with_metadata(self, metadata: LinkMetadata) -> Self
Set metadata.
Trait Implementations§
Source§impl Clone for LinkContent
impl Clone for LinkContent
Source§fn clone(&self) -> LinkContent
fn clone(&self) -> LinkContent
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for LinkContent
impl Debug for LinkContent
Source§impl<'de> Deserialize<'de> for LinkContent
impl<'de> Deserialize<'de> for LinkContent
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for LinkContent
impl RefUnwindSafe for LinkContent
impl Send for LinkContent
impl Sync for LinkContent
impl Unpin for LinkContent
impl UnsafeUnpin for LinkContent
impl UnwindSafe for LinkContent
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more