def name(self, name):
        """Set the enum name."""
        success = idaapi.set_enum_name(self.eid, name)
        if not success:
            raise exceptions.CantRenameEnum("Cant rename enum {!r} to {!r}.".format(self.name, name))
Set the enum name.