PHP 클래스 Google\Cloud\BigQuery\Dataset

파일 보기 프로젝트 열기: GoogleCloudPlatform/gcloud-php

공개 메소드들

메소드 설명
__construct ( Google\Cloud\BigQuery\Connection\ConnectionInterface $connection, string $id, string $projectId, array $info = [] )
createTable ( $id, array $options = [] ) : Google\Cloud\BigQuery\Table Creates a table.
delete ( array $options = [] ) Delete the dataset.
exists ( ) : boolean Check whether or not the dataset exists.
id ( ) : string Retrieves the dataset's ID.
identity ( ) : array Retrieves the dataset's identity.
info ( array $options = [] ) : array Retrieves the dataset's details. If no dataset data is cached a network request will be made to retrieve it.
reload ( array $options = [] ) : array Triggers a network request to reload the dataset's details.
table ( string $id ) : Dataset Lazily instantiates a table. There are no network requests made at this point. To see the operations that can be performed on a dataset please see {@see Google\Cloud\BigQuery\Table}.
tables ( array $options = [] ) : Generator Fetches tables in the dataset.
update ( array $metadata, array $options = [] ) Update the dataset.

메소드 상세

__construct() 공개 메소드

public __construct ( Google\Cloud\BigQuery\Connection\ConnectionInterface $connection, string $id, string $projectId, array $info = [] )
$connection Google\Cloud\BigQuery\Connection\ConnectionInterface Represents a connection to BigQuery.
$id string The dataset's ID.
$projectId string The project's ID.
$info array [optional] The dataset's metadata.

createTable() 공개 메소드

Example: $table = $dataset->createTable('aTable');
또한 보기: https://cloud.google.com/bigquery/docs/reference/v2/tables/insert Tables insert API documentation.
public createTable ( $id, array $options = [] ) : Google\Cloud\BigQuery\Table
$options array [optional] { Configuration options. @type array $metadata The available options for metadata are outlined at the [Table Resource API docs](https://cloud.google.com/bigquery/docs/reference/v2/tables#resource) }
리턴 Google\Cloud\BigQuery\Table

delete() 공개 메소드

Example: $dataset->delete();
또한 보기: https://cloud.google.com/bigquery/docs/reference/v2/datasets/delete Datasets delete API documentation.
public delete ( array $options = [] )
$options array [optional] { Configuration options. @type bool $deleteContents If true, delete all the tables in the dataset. If false and the dataset contains tables, the request will fail. **Defaults to** `false`. }

exists() 공개 메소드

Example: echo $dataset->exists();
public exists ( ) : boolean
리턴 boolean

id() 공개 메소드

Example: echo $dataset->id();
public id ( ) : string
리턴 string

identity() 공개 메소드

An identity provides a description of resource that is nested in nature. Example: echo $dataset->identity()['projectId'];
public identity ( ) : array
리턴 array

info() 공개 메소드

Example: $info = $dataset->info(); echo $info['friendlyName'];
또한 보기: https://cloud.google.com/bigquery/docs/reference/v2/datasets#resource Datasets resource documentation.
public info ( array $options = [] ) : array
$options array [optional] Configuration options.
리턴 array

reload() 공개 메소드

Example: $dataset->reload(); $info = $dataset->info(); echo $info['friendlyName'];
또한 보기: https://cloud.google.com/bigquery/docs/reference/v2/datasets/get Datasets get API documentation.
public reload ( array $options = [] ) : array
$options array [optional] Configuration options.
리턴 array

table() 공개 메소드

Example: $table = $dataset->table('myTableId');
public table ( string $id ) : Dataset
$id string The id of the table to request.
리턴 Dataset

tables() 공개 메소드

Example: $tables = $dataset->tables(); foreach ($tables as $table) { echo $table->id() . PHP_EOL; }
또한 보기: https://cloud.google.com/bigquery/docs/reference/v2/tables/list Tables list API documentation.
public tables ( array $options = [] ) : Generator
$options array [optional] { Configuration options. @type int $maxResults Maximum number of results to return. }
리턴 Generator

update() 공개 메소드

Example: $dataset->update([ 'friendlyName' => 'A fanciful dataset.' ]);
또한 보기: https://cloud.google.com/bigquery/docs/reference/v2/datasets/patch Datasets patch API documentation.
public update ( array $metadata, array $options = [] )
$metadata array The available options for metadata are outlined at the [Dataset Resource API docs](https://cloud.google.com/bigquery/docs/reference/v2/datasets#resource)
$options array [optional] Configuration options.