public function get_consumers_mapped_to_tool($toolid) {
        global $DB;

        $consumers = [];
        $consumerrecords = $DB->get_records('enrol_lti_tool_consumer_map', ['toolid' => $toolid], '', 'consumerid');
        foreach ($consumerrecords as $record) {
            $consumers[] = ToolConsumer::fromRecordId($record->consumerid, $this);
        }
        return $consumers;
    }