pub struct CT_Permission {
pub printable: bool,
pub editable: bool,
pub annotatable: bool,
pub print: Option<Print>,
pub valid_period: Option<ValidPeriod>,
}Expand description
权限容器。
对应 Java: org.ofdrw.core.basicStructure.doc.permission.CT_Permission
等价于 crate::doc::permission::CtPermission。
对应 Java: org.ofdrw.core.basicStructure.CT_Permission
文档权限控制容器,定义文档的打印权限和有效期。
Fields§
§printable: bool是否可打印。默认 true。
editable: bool是否可编辑。默认 true。
annotatable: bool是否可注释。默认 true。
print: Option<Print>打印权限详情。可选。
valid_period: Option<ValidPeriod>有效期。可选。
Implementations§
Source§impl CtPermission
impl CtPermission
Sourcepub fn with_print(self, print: Print) -> Self
pub fn with_print(self, print: Print) -> Self
设置打印权限。
Sourcepub fn with_valid_period(self, period: ValidPeriod) -> Self
pub fn with_valid_period(self, period: ValidPeriod) -> Self
设置有效期。
Sourcepub fn to_xml_string(&self) -> String
pub fn to_xml_string(&self) -> String
序列化为 XML 字符串。
Trait Implementations§
Source§impl Clone for CtPermission
impl Clone for CtPermission
Source§fn clone(&self) -> CtPermission
fn clone(&self) -> CtPermission
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 moreSource§impl Debug for CtPermission
impl Debug for CtPermission
Auto Trait Implementations§
impl Freeze for CtPermission
impl RefUnwindSafe for CtPermission
impl Send for CtPermission
impl Sync for CtPermission
impl Unpin for CtPermission
impl UnsafeUnpin for CtPermission
impl UnwindSafe for CtPermission
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