Class: Uniword::Ooxml::CustomProperty
- Inherits:
-
Lutaml::Model::Serializable
- Object
- Lutaml::Model::Serializable
- Uniword::Ooxml::CustomProperty
- Defined in:
- lib/uniword/ooxml/custom_properties.rb
Overview
Custom Document Properties (docProps/custom.xml)
XSD: shared-documentPropertiesCustom.xsd Namespace: schemas.openxmlformats.org/officeDocument/2006/custom-properties
Each property has a name, fmtid (GUID), pid (int), and exactly one vt:* value element (lpwstr, i4, bool, etc.).
Instance Method Summary collapse
-
#has_value? ⇒ Boolean
Check if any variant type value is set.
-
#value ⇒ Object
Get the value from whichever variant type is set.
Instance Method Details
#has_value? ⇒ Boolean
Check if any variant type value is set
110 111 112 |
# File 'lib/uniword/ooxml/custom_properties.rb', line 110 def has_value? !!value || !!empty || !!null || !!vector || !!array end |
#value ⇒ Object
Get the value from whichever variant type is set
100 101 102 103 104 105 106 107 |
# File 'lib/uniword/ooxml/custom_properties.rb', line 100 def value lpwstr&.value || lpstr&.value || bstr&.value || i4&.value || i8&.value || i2&.value || i1&.value || int&.value || ui4&.value || ui8&.value || ui2&.value || ui1&.value || uint&.value || r4&.value || r8&.value || decimal&.value || bool&.value || date&.value || filetime&.value || cy&.value || error&.value || clsid&.value end |