def get_writable_metadata(self, file_format):
        """
        Convert the metadata to a writable form.

        :param file_format: the needed format can be json or xml
        :type file_format: str
        :return: the dupled metadata
        :rtype: str
        """
        if file_format == 'json':
            metadata = self.json
        elif file_format == 'xml':
            metadata = self.xml
        else:
            raise TypeError('The requested file type (%s) is not yet supported'
                            % file_format)
        return metadata
Convert the metadata to a writable form.

        :param file_format: the needed format can be json or xml
        :type file_format: str
        :return: the dupled metadata
        :rtype: str