class bigquery_job_service

Properties

static protected $instances
static protected $config

Methods

static bigquery_job
get_instance(int $id = 0)

No description

static array
get_list_jobs_data(int $id)

Retrieves a list of job data, formatted with detailed information such as timestamps and status.

static bool
cleanup(int $itemid, bool|int $now = false, bool|object $config = false)

Cleans up files based on retention policies for hours, days, and months.

static false|stored_file
get_file(context $context, int $itemid)

Retrieves a file associated with a specific context and item ID.

static bool
delete_file()

Cleans up files based on retention policies for hours, days, and months.

Details

at line 37
static bigquery_job get_instance(int $id = 0)

No description

Parameters

int $id

Return Value

bigquery_job

at line 58
static array get_list_jobs_data(int $id)

Retrieves a list of job data, formatted with detailed information such as timestamps and status.

Parameters

int $id

the parent identifier used to fetch the related jobs

Return Value

array

an array containing job information, including creation time, start time, end time, quantity, status, and HTML link to associated files

at line 108
static bool cleanup(int $itemid, bool|int $now = false, bool|object $config = false)

Cleans up files based on retention policies for hours, days, and months.

Parameters

int $itemid
bool|int $now

The current timestamp to use for retention checks. Defaults to the current time.

bool|object $config

Configuration object containing retention policy settings. Defaults to fetching configuration.

Return Value

bool

returns true if the file was successfully deleted, false otherwise

Exceptions

dml_exception

at line 183
static protected false|stored_file get_file(context $context, int $itemid)

Retrieves a file associated with a specific context and item ID.

Parameters

context $context

the context in which to search for the file

int $itemid

the item ID associated with the file

Return Value

false|stored_file

the stored file if found, otherwise false

Exceptions

coding_exception

at line 201
static protected bool delete_file()

Cleans up files based on retention policies for hours, days, and months.

Return Value

bool

returns true if the file was successfully deleted, false otherwise