def paper_status(self):
status = self.query_status(RT_STATUS_PAPER)<EOL>if len(status) == <NUM_LIT:0>:<EOL><INDENT>return <NUM_LIT:2><EOL><DEDENT>if (status[<NUM_LIT:0>] & RT_MASK_NOPAPER == RT_MASK_NOPAPER):<EOL><INDENT>return <NUM_LIT:0><EOL><DEDENT>if (status[<NUM_LIT:0>] & RT_MASK_LOWPAPER == RT_MASK_LOWPAPER):<EOL><INDENT>return <NUM_LIT:1><EOL><DEDENT>if (status[<NUM_LIT:0>] & RT_MASK_PAPER == RT_MASK_PAPER):<EOL><INDENT>return <NUM_LIT:2><EOL><DEDENT>
Queries the paper status of the printer.

Returns 2 if there is plenty of paper, 1 if the paper has arrived to
the near-end sensor and 0 if there is no paper.

:returns: 2: Paper is adequate. 1: Paper ending. 0: No paper.
:rtype: int