gem5.resources.client_api.jsonclient module

class gem5.resources.client_api.jsonclient.JSONClient(path: str)

Bases: AbstractClient

get_all_resources(gem5_version: str) List[Dict[str, Any]]

Get all resources compatible with the specified gem5 version.

Parameters:

gem5_version – The gem5 version to match against.

Returns:

A list of resources compatible with the given gem5 version.

get_resources(client_queries: List[ClientQuery]) Dict[str, Any]
Parameters:
  • client_queries – A list of client queries containing the information to query the resources. Each ClientQuery object can contain the following information: - resource_id: The ID of the Resource. - resource_version: The version of the Resource. - gem5_version: The version of gem5.

  • resource_version – The version of the Resource. Optional, if not set, all resource versions will be returned. Note: If resource_id is not set, this parameter will be ignored.

  • gem5_version – The version of gem5. Optional, if not set, all versions will be returned.

Returns:

A list of all the Resources with the given ID.

get_resources_json() List[Dict[str, Any]]

Returns a JSON representation of the resources.