File: constants.py

package info (click to toggle)
python-xsdata 24.1-2
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 2,936 kB
  • sloc: python: 29,257; xml: 404; makefile: 27; sh: 6
file content (20 lines) | stat: -rw-r--r-- 435 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
import sys
from typing import Any, Dict, Sequence, Tuple

EMPTY_MAP: Dict = {}
EMPTY_SEQUENCE: Sequence = []
EMPTY_TUPLE: Tuple = ()

XML_FALSE = sys.intern("false")
XML_TRUE = sys.intern("true")
DEFAULT_ATTR_NAME = "value"


def return_true(*_: Any) -> bool:
    """A dummy function that always returns true."""
    return True


def return_input(obj: Any) -> Any:
    """A dummy function that always returns input."""
    return obj