pub struct DocDir {
pub index: u32,
pub document_file_name: String,
pub public_res_file_name: String,
pub document_res_file_name: String,
pub signs_dir_name: String,
pub pages_dir_name: String,
pub res_dir_name: String,
pub annots_dir_name: String,
pub annotations_file_name: String,
pub attachments_file_name: String,
}Expand description
文档目录。
描述单个 OFD 文档的目录结构,管理文档内的 各种子容器(页面、资源、签名、注释等)。
Fields§
§index: u32文档索引(从 0 开始)。
document_file_name: String文档根节点描述文件名称。
public_res_file_name: String公共资源索引描述文件名称。
document_res_file_name: String文档自身资源索引描述文件名称。
signs_dir_name: String数字签名容器名称。
pages_dir_name: String页面容器名称。
res_dir_name: String资源容器名称。
annots_dir_name: String注释容器名称。
annotations_file_name: String注释入口文件名称。
attachments_file_name: String附件入口文件名称。
Implementations§
Source§impl DocDir
impl DocDir
Sourcepub const DOC_CONTAINER_PREFIX: &'static str = "Doc_"
pub const DOC_CONTAINER_PREFIX: &'static str = "Doc_"
文档容器名称前缀。
Sourcepub const DOCUMENT_FILE_NAME: &'static str = "Document.xml"
pub const DOCUMENT_FILE_NAME: &'static str = "Document.xml"
文档根节点描述文件名。
Sourcepub const PUBLIC_RES_FILE_NAME: &'static str = "PublicRes.xml"
pub const PUBLIC_RES_FILE_NAME: &'static str = "PublicRes.xml"
公共资源索引文件名。
Sourcepub const DOCUMENT_RES_FILE_NAME: &'static str = "DocumentRes.xml"
pub const DOCUMENT_RES_FILE_NAME: &'static str = "DocumentRes.xml"
文档自身资源索引文件名。
Sourcepub const SIGNS_DIR_NAME: &'static str = "Signs"
pub const SIGNS_DIR_NAME: &'static str = "Signs"
数字签名容器名。
Sourcepub const SIGN_CONTAINER_PREFIX: &'static str = "Sign_"
pub const SIGN_CONTAINER_PREFIX: &'static str = "Sign_"
数字签名容器名称前缀。
Sourcepub const TAGS_DIR_NAME: &'static str = "Tags"
pub const TAGS_DIR_NAME: &'static str = "Tags"
自定义标签容器名。
Sourcepub const TEMPS_DIR_NAME: &'static str = "Temps"
pub const TEMPS_DIR_NAME: &'static str = "Temps"
临时文件容器名。
Sourcepub const PAGES_DIR_NAME: &'static str = "Pages"
pub const PAGES_DIR_NAME: &'static str = "Pages"
页面容器名。
Sourcepub const PAGE_CONTAINER_PREFIX: &'static str = "Page_"
pub const PAGE_CONTAINER_PREFIX: &'static str = "Page_"
页面容器名称前缀。
Sourcepub const RES_DIR_NAME: &'static str = "Res"
pub const RES_DIR_NAME: &'static str = "Res"
资源容器名。
Sourcepub const ANNOTS_DIR_NAME: &'static str = "Annots"
pub const ANNOTS_DIR_NAME: &'static str = "Annots"
注释容器名。
Sourcepub const ANNOTATIONS_FILE_NAME: &'static str = "Annotations.xml"
pub const ANNOTATIONS_FILE_NAME: &'static str = "Annotations.xml"
注释入口文件名。
Sourcepub const ATTACHMENTS_FILE_NAME: &'static str = "Attachments.xml"
pub const ATTACHMENTS_FILE_NAME: &'static str = "Attachments.xml"
附件入口文件名。
Sourcepub fn container_name(&self) -> String
pub fn container_name(&self) -> String
获取文档容器目录名。
Trait Implementations§
Auto Trait Implementations§
impl Freeze for DocDir
impl RefUnwindSafe for DocDir
impl Send for DocDir
impl Sync for DocDir
impl Unpin for DocDir
impl UnsafeUnpin for DocDir
impl UnwindSafe for DocDir
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