MCPcopy Index your code
hub / github.com/dropbox/dropbox-sdk-python / ExportFormat

Class ExportFormat

dropbox/paper.py:450–495  ·  view source on GitHub ↗

The desired export format of the Paper doc. This class acts as a tagged union. Only one of the ``is_*`` methods will return true. To get the associated value of a tag (if one exists), use the corresponding ``get_*`` method. :ivar paper.ExportFormat.html: The HTML export format

Source from the content-addressed store, hash-verified

448DocSubscriptionLevel_validator = bv.Union(DocSubscriptionLevel)
449
450class ExportFormat(bb.Union):
451 """
452 The desired export format of the Paper doc.
453
454 This class acts as a tagged union. Only one of the ``is_*`` methods will
455 return true. To get the associated value of a tag (if one exists), use the
456 corresponding ``get_*`` method.
457
458 :ivar paper.ExportFormat.html: The HTML export format.
459 :ivar paper.ExportFormat.markdown: The markdown export format.
460 """
461
462 _catch_all = 'other'
463 # Attribute is overwritten below the class definition
464 html = None
465 # Attribute is overwritten below the class definition
466 markdown = None
467 # Attribute is overwritten below the class definition
468 other = None
469
470 def is_html(self):
471 """
472 Check if the union tag is ``html``.
473
474 :rtype: bool
475 """
476 return self._tag == 'html'
477
478 def is_markdown(self):
479 """
480 Check if the union tag is ``markdown``.
481
482 :rtype: bool
483 """
484 return self._tag == 'markdown'
485
486 def is_other(self):
487 """
488 Check if the union tag is ``other``.
489
490 :rtype: bool
491 """
492 return self._tag == 'other'
493
494 def _process_custom_annotations(self, annotation_type, field_path, processor):
495 super(ExportFormat, self)._process_custom_annotations(annotation_type, field_path, processor)
496
497ExportFormat_validator = bv.Union(ExportFormat)
498

Callers 1

paper.pyFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected