pub struct MediaEntry {
pub partname: PartName,
pub content_type: String,
pub blob: Vec<u8>,
pub rid: String,
}Expand description
媒体条目:保存到 /ppt/media/<file> 目录中的二进制资源。
对应 python-pptx 中 SlideShapes.add_picture(...) 隐式管理的 part。
rid 是预先生成的关系 id(如 "rIdImg1"),用于在 slideN.xml.rels 中
显式添加 <Relationship Id="rIdImg1" Type="...image" Target="../media/img.png"/>。
Fields§
§partname: PartName媒体 part 路径,例如 /ppt/media/image1.png。
content_type: String媒体 MIME / Office Content-Type(如 image/png)。
blob: Vec<u8>二进制内容(图片像素、嵌入字体字节等)。
rid: String在 slide xml 中引用的关系 id(形如 rIdImg1)。
Trait Implementations§
Source§impl Clone for MediaEntry
impl Clone for MediaEntry
Source§fn clone(&self) -> MediaEntry
fn clone(&self) -> MediaEntry
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for MediaEntry
impl RefUnwindSafe for MediaEntry
impl Send for MediaEntry
impl Sync for MediaEntry
impl Unpin for MediaEntry
impl UnsafeUnpin for MediaEntry
impl UnwindSafe for MediaEntry
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