'Text encoding of document or ``None``
:returns: :class:`str` or ``None``'

@property
def encoding(self):

    if (not self._encoding):
        self._encoding = self._get_encoding()
    return self._encoding
