import logging
import requests
import json
from operator import itemgetter
import urllib.parse
from .Exceptions import UnsupportedBDVersion

logger = logging.getLogger(__name__)

def get_file_matches_for_bom_component(self, bom_component, limit=1000):
    self._check_version_compatibility()
    url = self.get_link(bom_component, "matched-files")
    paramstring = self.get_limit_paramstring(limit)
    logger.debug("GET {}".format(url))
    response = self.execute_get(url)
    jsondata = response.json()
    return jsondata

