Add method to get OrgDoc property.
This commit is contained in:
parent
72d5cadb96
commit
3b6358c195
1 changed files with 7 additions and 0 deletions
|
@ -1292,6 +1292,13 @@ class OrgDoc:
|
|||
for content in self.contents:
|
||||
yield from get_links_from_content(content)
|
||||
|
||||
def get_property(self, name: str, default=None):
|
||||
for prop in self.keywords:
|
||||
if prop.key == name:
|
||||
return prop.value
|
||||
|
||||
return default
|
||||
|
||||
def getProperties(self):
|
||||
return self.keywords
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue