<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def list_database_names(self, session=None):
 """Get a list of the names of all databases on the connected server. :Parameters: - `session` (optional):
 a :class:`~pymongo.client_session.ClientSession`. .. versionadded:: 3.6 """

        return [doc["name"]
                for doc in self.list_databases(session, nameOnly=True)]