pub struct URLMessage<'a> {
pub title: Option<&'a str>,
pub summary: Option<&'a str>,
pub url: Option<&'a str>,
pub original_url: Option<&'a str>,
pub item_type: Option<&'a str>,
pub images: Vec<&'a str>,
pub icons: Vec<&'a str>,
pub site_name: Option<&'a str>,
pub placeholder: bool,
}
Expand description
This struct is not documented by Apple, but represents messages created by
com.apple.messages.URLBalloonProvider
.
Fields§
§title: Option<&'a str>
The webpage’s <og:title>
attribute
summary: Option<&'a str>
The webpage’s <og:description>
attribute
url: Option<&'a str>
The URL that ended up serving content, after all redirects
original_url: Option<&'a str>
The original url, before any redirects
item_type: Option<&'a str>
The type of webpage Apple thinks the link represents
images: Vec<&'a str>
Up to 4 image previews displayed in the background of the bubble
icons: Vec<&'a str>
Icons that represent the website, generally the favicon or apple-touch-icon
site_name: Option<&'a str>
The name of a website
placeholder: bool
Indicates whether this is a placeholder link preview that needs to be loaded
Implementations§
Source§impl<'a> URLMessage<'a>
impl<'a> URLMessage<'a>
Sourcepub fn get_url_message_override(
payload: &'a Value,
) -> Result<URLOverride<'a>, PlistParseError>
pub fn get_url_message_override( payload: &'a Value, ) -> Result<URLOverride<'a>, PlistParseError>
Gets the subtype of the URL message based on the payload
Trait Implementations§
Source§impl<'a> BalloonProvider<'a> for URLMessage<'a>
impl<'a> BalloonProvider<'a> for URLMessage<'a>
Source§impl<'a> Debug for URLMessage<'a>
impl<'a> Debug for URLMessage<'a>
Source§impl<'a> PartialEq for URLMessage<'a>
impl<'a> PartialEq for URLMessage<'a>
impl<'a> Eq for URLMessage<'a>
impl<'a> StructuralPartialEq for URLMessage<'a>
Auto Trait Implementations§
impl<'a> Freeze for URLMessage<'a>
impl<'a> RefUnwindSafe for URLMessage<'a>
impl<'a> Send for URLMessage<'a>
impl<'a> Sync for URLMessage<'a>
impl<'a> Unpin for URLMessage<'a>
impl<'a> UnwindSafe for URLMessage<'a>
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
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.