<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def export(self, private_key=True):
 """Exports the key in the standard JSON format. Exports the key regardless of type, if private_key is False and the key is_symmetric an exceptionis raised. :param private_key(bool):
 Whether to export the private key. Defaults to True. """

        if private_key is True:
            # Use _export_all for backwards compatibility, as this
            # function allows to export symmetrict keys too
            return self._export_all()
        else:
            return self.export_public()