Class RealmsServiceClient (1.2.0)

public abstract class RealmsServiceClient

RealmsService client wrapper, for convenient use.

Inheritance

Object > RealmsServiceClient

Derived Types

Namespace

Google.Cloud.Gaming.V1

Assembly

Google.Cloud.Gaming.V1.dll

Remarks

A realm is a grouping of game server clusters that are considered interchangeable.

Properties

CreateRealmOperationsClient

public virtual OperationsClient CreateRealmOperationsClient { get; }

The long-running operations client for CreateRealm.

Property Value
TypeDescription
OperationsClient

DefaultEndpoint

public static string DefaultEndpoint { get; }

The default endpoint for the RealmsService service, which is a host of "gameservices.googleapis.com" and a port of 443.

Property Value
TypeDescription
String

DefaultScopes

public static IReadOnlyList<string> DefaultScopes { get; }

The default RealmsService scopes.

Property Value
TypeDescription
IReadOnlyList<String>
Remarks

The default RealmsService scopes are:

DeleteRealmOperationsClient

public virtual OperationsClient DeleteRealmOperationsClient { get; }

The long-running operations client for DeleteRealm.

Property Value
TypeDescription
OperationsClient

GrpcClient

public virtual RealmsService.RealmsServiceClient GrpcClient { get; }

The underlying gRPC RealmsService client

Property Value
TypeDescription
RealmsService.RealmsServiceClient

UpdateRealmOperationsClient

public virtual OperationsClient UpdateRealmOperationsClient { get; }

The long-running operations client for UpdateRealm.

Property Value
TypeDescription
OperationsClient

Methods

Create()

public static RealmsServiceClient Create()

Synchronously creates a RealmsServiceClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use RealmsServiceClientBuilder.

Returns
TypeDescription
RealmsServiceClient

The created RealmsServiceClient.

CreateAsync(CancellationToken)

public static Task<RealmsServiceClient> CreateAsync(CancellationToken cancellationToken = default(CancellationToken))

Asynchronously creates a RealmsServiceClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use RealmsServiceClientBuilder.

Parameter
NameDescription
cancellationTokenCancellationToken

The CancellationToken to use while creating the client.

Returns
TypeDescription
Task<RealmsServiceClient>

The task representing the created RealmsServiceClient.

CreateRealm(LocationName, Realm, String, CallSettings)

public virtual Operation<Realm, OperationMetadata> CreateRealm(LocationName parent, Realm realm, string realmId, CallSettings callSettings = null)

Creates a new realm in a given project and location.

Parameters
NameDescription
parentLocationName

Required. The parent resource name, in the following form: projects/{project}/locations/{location}.

realmRealm

Required. The realm resource to be created.

realmIdString

Required. The ID of the realm resource to be created.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Realm, OperationMetadata>

The RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = RealmsServiceClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
Realm realm = new Realm();
string realmId = "";
// Make the request
Operation<Realm, OperationMetadata> response = realmsServiceClient.CreateRealm(parent, realm, realmId);

// Poll until the returned long-running operation is complete
Operation<Realm, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Realm result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Realm, OperationMetadata> retrievedResponse = realmsServiceClient.PollOnceCreateRealm(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Realm retrievedResult = retrievedResponse.Result;
}

CreateRealm(CreateRealmRequest, CallSettings)

public virtual Operation<Realm, OperationMetadata> CreateRealm(CreateRealmRequest request, CallSettings callSettings = null)

Creates a new realm in a given project and location.

Parameters
NameDescription
requestCreateRealmRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Realm, OperationMetadata>

The RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = RealmsServiceClient.Create();
// Initialize request argument(s)
CreateRealmRequest request = new CreateRealmRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    RealmId = "",
    Realm = new Realm(),
};
// Make the request
Operation<Realm, OperationMetadata> response = realmsServiceClient.CreateRealm(request);

// Poll until the returned long-running operation is complete
Operation<Realm, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Realm result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Realm, OperationMetadata> retrievedResponse = realmsServiceClient.PollOnceCreateRealm(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Realm retrievedResult = retrievedResponse.Result;
}

CreateRealm(String, Realm, String, CallSettings)

public virtual Operation<Realm, OperationMetadata> CreateRealm(string parent, Realm realm, string realmId, CallSettings callSettings = null)

Creates a new realm in a given project and location.

Parameters
NameDescription
parentString

Required. The parent resource name, in the following form: projects/{project}/locations/{location}.

realmRealm

Required. The realm resource to be created.

realmIdString

Required. The ID of the realm resource to be created.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Realm, OperationMetadata>

The RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = RealmsServiceClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
Realm realm = new Realm();
string realmId = "";
// Make the request
Operation<Realm, OperationMetadata> response = realmsServiceClient.CreateRealm(parent, realm, realmId);

// Poll until the returned long-running operation is complete
Operation<Realm, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Realm result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Realm, OperationMetadata> retrievedResponse = realmsServiceClient.PollOnceCreateRealm(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Realm retrievedResult = retrievedResponse.Result;
}

CreateRealmAsync(LocationName, Realm, String, CallSettings)

public virtual Task<Operation<Realm, OperationMetadata>> CreateRealmAsync(LocationName parent, Realm realm, string realmId, CallSettings callSettings = null)

Creates a new realm in a given project and location.

Parameters
NameDescription
parentLocationName

Required. The parent resource name, in the following form: projects/{project}/locations/{location}.

realmRealm

Required. The realm resource to be created.

realmIdString

Required. The ID of the realm resource to be created.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Realm, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
Realm realm = new Realm();
string realmId = "";
// Make the request
Operation<Realm, OperationMetadata> response = await realmsServiceClient.CreateRealmAsync(parent, realm, realmId);

// Poll until the returned long-running operation is complete
Operation<Realm, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Realm result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Realm, OperationMetadata> retrievedResponse = await realmsServiceClient.PollOnceCreateRealmAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Realm retrievedResult = retrievedResponse.Result;
}

CreateRealmAsync(LocationName, Realm, String, CancellationToken)

public virtual Task<Operation<Realm, OperationMetadata>> CreateRealmAsync(LocationName parent, Realm realm, string realmId, CancellationToken cancellationToken)

Creates a new realm in a given project and location.

Parameters
NameDescription
parentLocationName

Required. The parent resource name, in the following form: projects/{project}/locations/{location}.

realmRealm

Required. The realm resource to be created.

realmIdString

Required. The ID of the realm resource to be created.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Realm, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
Realm realm = new Realm();
string realmId = "";
// Make the request
Operation<Realm, OperationMetadata> response = await realmsServiceClient.CreateRealmAsync(parent, realm, realmId);

// Poll until the returned long-running operation is complete
Operation<Realm, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Realm result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Realm, OperationMetadata> retrievedResponse = await realmsServiceClient.PollOnceCreateRealmAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Realm retrievedResult = retrievedResponse.Result;
}

CreateRealmAsync(CreateRealmRequest, CallSettings)

public virtual Task<Operation<Realm, OperationMetadata>> CreateRealmAsync(CreateRealmRequest request, CallSettings callSettings = null)

Creates a new realm in a given project and location.

Parameters
NameDescription
requestCreateRealmRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Realm, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
CreateRealmRequest request = new CreateRealmRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    RealmId = "",
    Realm = new Realm(),
};
// Make the request
Operation<Realm, OperationMetadata> response = await realmsServiceClient.CreateRealmAsync(request);

// Poll until the returned long-running operation is complete
Operation<Realm, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Realm result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Realm, OperationMetadata> retrievedResponse = await realmsServiceClient.PollOnceCreateRealmAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Realm retrievedResult = retrievedResponse.Result;
}

CreateRealmAsync(CreateRealmRequest, CancellationToken)

public virtual Task<Operation<Realm, OperationMetadata>> CreateRealmAsync(CreateRealmRequest request, CancellationToken cancellationToken)

Creates a new realm in a given project and location.

Parameters
NameDescription
requestCreateRealmRequest

The request object containing all of the parameters for the API call.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Realm, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
CreateRealmRequest request = new CreateRealmRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    RealmId = "",
    Realm = new Realm(),
};
// Make the request
Operation<Realm, OperationMetadata> response = await realmsServiceClient.CreateRealmAsync(request);

// Poll until the returned long-running operation is complete
Operation<Realm, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Realm result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Realm, OperationMetadata> retrievedResponse = await realmsServiceClient.PollOnceCreateRealmAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Realm retrievedResult = retrievedResponse.Result;
}

CreateRealmAsync(String, Realm, String, CallSettings)

public virtual Task<Operation<Realm, OperationMetadata>> CreateRealmAsync(string parent, Realm realm, string realmId, CallSettings callSettings = null)

Creates a new realm in a given project and location.

Parameters
NameDescription
parentString

Required. The parent resource name, in the following form: projects/{project}/locations/{location}.

realmRealm

Required. The realm resource to be created.

realmIdString

Required. The ID of the realm resource to be created.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Realm, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
Realm realm = new Realm();
string realmId = "";
// Make the request
Operation<Realm, OperationMetadata> response = await realmsServiceClient.CreateRealmAsync(parent, realm, realmId);

// Poll until the returned long-running operation is complete
Operation<Realm, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Realm result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Realm, OperationMetadata> retrievedResponse = await realmsServiceClient.PollOnceCreateRealmAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Realm retrievedResult = retrievedResponse.Result;
}

CreateRealmAsync(String, Realm, String, CancellationToken)

public virtual Task<Operation<Realm, OperationMetadata>> CreateRealmAsync(string parent, Realm realm, string realmId, CancellationToken cancellationToken)

Creates a new realm in a given project and location.

Parameters
NameDescription
parentString

Required. The parent resource name, in the following form: projects/{project}/locations/{location}.

realmRealm

Required. The realm resource to be created.

realmIdString

Required. The ID of the realm resource to be created.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Realm, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
Realm realm = new Realm();
string realmId = "";
// Make the request
Operation<Realm, OperationMetadata> response = await realmsServiceClient.CreateRealmAsync(parent, realm, realmId);

// Poll until the returned long-running operation is complete
Operation<Realm, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Realm result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Realm, OperationMetadata> retrievedResponse = await realmsServiceClient.PollOnceCreateRealmAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Realm retrievedResult = retrievedResponse.Result;
}

DeleteRealm(DeleteRealmRequest, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteRealm(DeleteRealmRequest request, CallSettings callSettings = null)

Deletes a single realm.

Parameters
NameDescription
requestDeleteRealmRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Empty, OperationMetadata>

The RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = RealmsServiceClient.Create();
// Initialize request argument(s)
DeleteRealmRequest request = new DeleteRealmRequest
{
    RealmName = RealmName.FromProjectLocationRealm("[PROJECT]", "[LOCATION]", "[REALM]"),
};
// Make the request
Operation<Empty, OperationMetadata> response = realmsServiceClient.DeleteRealm(request);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = realmsServiceClient.PollOnceDeleteRealm(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteRealm(RealmName, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteRealm(RealmName name, CallSettings callSettings = null)

Deletes a single realm.

Parameters
NameDescription
nameRealmName

Required. The name of the realm to delete, in the following form: projects/{project}/locations/{location}/realms/{realm}.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Empty, OperationMetadata>

The RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = RealmsServiceClient.Create();
// Initialize request argument(s)
RealmName name = RealmName.FromProjectLocationRealm("[PROJECT]", "[LOCATION]", "[REALM]");
// Make the request
Operation<Empty, OperationMetadata> response = realmsServiceClient.DeleteRealm(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = realmsServiceClient.PollOnceDeleteRealm(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteRealm(String, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteRealm(string name, CallSettings callSettings = null)

Deletes a single realm.

Parameters
NameDescription
nameString

Required. The name of the realm to delete, in the following form: projects/{project}/locations/{location}/realms/{realm}.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Empty, OperationMetadata>

The RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = RealmsServiceClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/realms/[REALM]";
// Make the request
Operation<Empty, OperationMetadata> response = realmsServiceClient.DeleteRealm(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = realmsServiceClient.PollOnceDeleteRealm(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteRealmAsync(DeleteRealmRequest, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteRealmAsync(DeleteRealmRequest request, CallSettings callSettings = null)

Deletes a single realm.

Parameters
NameDescription
requestDeleteRealmRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Empty, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
DeleteRealmRequest request = new DeleteRealmRequest
{
    RealmName = RealmName.FromProjectLocationRealm("[PROJECT]", "[LOCATION]", "[REALM]"),
};
// Make the request
Operation<Empty, OperationMetadata> response = await realmsServiceClient.DeleteRealmAsync(request);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await realmsServiceClient.PollOnceDeleteRealmAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteRealmAsync(DeleteRealmRequest, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteRealmAsync(DeleteRealmRequest request, CancellationToken cancellationToken)

Deletes a single realm.

Parameters
NameDescription
requestDeleteRealmRequest

The request object containing all of the parameters for the API call.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Empty, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
DeleteRealmRequest request = new DeleteRealmRequest
{
    RealmName = RealmName.FromProjectLocationRealm("[PROJECT]", "[LOCATION]", "[REALM]"),
};
// Make the request
Operation<Empty, OperationMetadata> response = await realmsServiceClient.DeleteRealmAsync(request);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await realmsServiceClient.PollOnceDeleteRealmAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteRealmAsync(RealmName, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteRealmAsync(RealmName name, CallSettings callSettings = null)

Deletes a single realm.

Parameters
NameDescription
nameRealmName

Required. The name of the realm to delete, in the following form: projects/{project}/locations/{location}/realms/{realm}.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Empty, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
RealmName name = RealmName.FromProjectLocationRealm("[PROJECT]", "[LOCATION]", "[REALM]");
// Make the request
Operation<Empty, OperationMetadata> response = await realmsServiceClient.DeleteRealmAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await realmsServiceClient.PollOnceDeleteRealmAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteRealmAsync(RealmName, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteRealmAsync(RealmName name, CancellationToken cancellationToken)

Deletes a single realm.

Parameters
NameDescription
nameRealmName

Required. The name of the realm to delete, in the following form: projects/{project}/locations/{location}/realms/{realm}.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Empty, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
RealmName name = RealmName.FromProjectLocationRealm("[PROJECT]", "[LOCATION]", "[REALM]");
// Make the request
Operation<Empty, OperationMetadata> response = await realmsServiceClient.DeleteRealmAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await realmsServiceClient.PollOnceDeleteRealmAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteRealmAsync(String, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteRealmAsync(string name, CallSettings callSettings = null)

Deletes a single realm.

Parameters
NameDescription
nameString

Required. The name of the realm to delete, in the following form: projects/{project}/locations/{location}/realms/{realm}.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Empty, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/realms/[REALM]";
// Make the request
Operation<Empty, OperationMetadata> response = await realmsServiceClient.DeleteRealmAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await realmsServiceClient.PollOnceDeleteRealmAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteRealmAsync(String, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteRealmAsync(string name, CancellationToken cancellationToken)

Deletes a single realm.

Parameters
NameDescription
nameString

Required. The name of the realm to delete, in the following form: projects/{project}/locations/{location}/realms/{realm}.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Empty, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/realms/[REALM]";
// Make the request
Operation<Empty, OperationMetadata> response = await realmsServiceClient.DeleteRealmAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await realmsServiceClient.PollOnceDeleteRealmAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

GetRealm(GetRealmRequest, CallSettings)

public virtual Realm GetRealm(GetRealmRequest request, CallSettings callSettings = null)

Gets details of a single realm.

Parameters
NameDescription
requestGetRealmRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Realm

The RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = RealmsServiceClient.Create();
// Initialize request argument(s)
GetRealmRequest request = new GetRealmRequest
{
    RealmName = RealmName.FromProjectLocationRealm("[PROJECT]", "[LOCATION]", "[REALM]"),
};
// Make the request
Realm response = realmsServiceClient.GetRealm(request);

GetRealm(RealmName, CallSettings)

public virtual Realm GetRealm(RealmName name, CallSettings callSettings = null)

Gets details of a single realm.

Parameters
NameDescription
nameRealmName

Required. The name of the realm to retrieve, in the following form: projects/{project}/locations/{location}/realms/{realm}.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Realm

The RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = RealmsServiceClient.Create();
// Initialize request argument(s)
RealmName name = RealmName.FromProjectLocationRealm("[PROJECT]", "[LOCATION]", "[REALM]");
// Make the request
Realm response = realmsServiceClient.GetRealm(name);

GetRealm(String, CallSettings)

public virtual Realm GetRealm(string name, CallSettings callSettings = null)

Gets details of a single realm.

Parameters
NameDescription
nameString

Required. The name of the realm to retrieve, in the following form: projects/{project}/locations/{location}/realms/{realm}.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Realm

The RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = RealmsServiceClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/realms/[REALM]";
// Make the request
Realm response = realmsServiceClient.GetRealm(name);

GetRealmAsync(GetRealmRequest, CallSettings)

public virtual Task<Realm> GetRealmAsync(GetRealmRequest request, CallSettings callSettings = null)

Gets details of a single realm.

Parameters
NameDescription
requestGetRealmRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Realm>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
GetRealmRequest request = new GetRealmRequest
{
    RealmName = RealmName.FromProjectLocationRealm("[PROJECT]", "[LOCATION]", "[REALM]"),
};
// Make the request
Realm response = await realmsServiceClient.GetRealmAsync(request);

GetRealmAsync(GetRealmRequest, CancellationToken)

public virtual Task<Realm> GetRealmAsync(GetRealmRequest request, CancellationToken cancellationToken)

Gets details of a single realm.

Parameters
NameDescription
requestGetRealmRequest

The request object containing all of the parameters for the API call.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Realm>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
GetRealmRequest request = new GetRealmRequest
{
    RealmName = RealmName.FromProjectLocationRealm("[PROJECT]", "[LOCATION]", "[REALM]"),
};
// Make the request
Realm response = await realmsServiceClient.GetRealmAsync(request);

GetRealmAsync(RealmName, CallSettings)

public virtual Task<Realm> GetRealmAsync(RealmName name, CallSettings callSettings = null)

Gets details of a single realm.

Parameters
NameDescription
nameRealmName

Required. The name of the realm to retrieve, in the following form: projects/{project}/locations/{location}/realms/{realm}.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Realm>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
RealmName name = RealmName.FromProjectLocationRealm("[PROJECT]", "[LOCATION]", "[REALM]");
// Make the request
Realm response = await realmsServiceClient.GetRealmAsync(name);

GetRealmAsync(RealmName, CancellationToken)

public virtual Task<Realm> GetRealmAsync(RealmName name, CancellationToken cancellationToken)

Gets details of a single realm.

Parameters
NameDescription
nameRealmName

Required. The name of the realm to retrieve, in the following form: projects/{project}/locations/{location}/realms/{realm}.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Realm>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
RealmName name = RealmName.FromProjectLocationRealm("[PROJECT]", "[LOCATION]", "[REALM]");
// Make the request
Realm response = await realmsServiceClient.GetRealmAsync(name);

GetRealmAsync(String, CallSettings)

public virtual Task<Realm> GetRealmAsync(string name, CallSettings callSettings = null)

Gets details of a single realm.

Parameters
NameDescription
nameString

Required. The name of the realm to retrieve, in the following form: projects/{project}/locations/{location}/realms/{realm}.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Realm>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/realms/[REALM]";
// Make the request
Realm response = await realmsServiceClient.GetRealmAsync(name);

GetRealmAsync(String, CancellationToken)

public virtual Task<Realm> GetRealmAsync(string name, CancellationToken cancellationToken)

Gets details of a single realm.

Parameters
NameDescription
nameString

Required. The name of the realm to retrieve, in the following form: projects/{project}/locations/{location}/realms/{realm}.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Realm>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/realms/[REALM]";
// Make the request
Realm response = await realmsServiceClient.GetRealmAsync(name);

ListRealms(LocationName, String, Nullable<Int32>, CallSettings)

public virtual PagedEnumerable<ListRealmsResponse, Realm> ListRealms(LocationName parent, string pageToken = null, int? pageSize = default(int? ), CallSettings callSettings = null)

Lists realms in a given project and location.

Parameters
NameDescription
parentLocationName

Required. The parent resource name, in the following form: projects/{project}/locations/{location}.

pageTokenString

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSizeNullable<Int32>

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerable<ListRealmsResponse, Realm>

A pageable sequence of Realm resources.

Example
// Create client
RealmsServiceClient realmsServiceClient = RealmsServiceClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedEnumerable<ListRealmsResponse, Realm> response = realmsServiceClient.ListRealms(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (Realm item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListRealmsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Realm item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Realm> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Realm item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListRealms(ListRealmsRequest, CallSettings)

public virtual PagedEnumerable<ListRealmsResponse, Realm> ListRealms(ListRealmsRequest request, CallSettings callSettings = null)

Lists realms in a given project and location.

Parameters
NameDescription
requestListRealmsRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerable<ListRealmsResponse, Realm>

A pageable sequence of Realm resources.

Example
// Create client
RealmsServiceClient realmsServiceClient = RealmsServiceClient.Create();
// Initialize request argument(s)
ListRealmsRequest request = new ListRealmsRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedEnumerable<ListRealmsResponse, Realm> response = realmsServiceClient.ListRealms(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (Realm item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListRealmsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Realm item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Realm> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Realm item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListRealms(String, String, Nullable<Int32>, CallSettings)

public virtual PagedEnumerable<ListRealmsResponse, Realm> ListRealms(string parent, string pageToken = null, int? pageSize = default(int? ), CallSettings callSettings = null)

Lists realms in a given project and location.

Parameters
NameDescription
parentString

Required. The parent resource name, in the following form: projects/{project}/locations/{location}.

pageTokenString

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSizeNullable<Int32>

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerable<ListRealmsResponse, Realm>

A pageable sequence of Realm resources.

Example
// Create client
RealmsServiceClient realmsServiceClient = RealmsServiceClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedEnumerable<ListRealmsResponse, Realm> response = realmsServiceClient.ListRealms(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (Realm item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListRealmsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Realm item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Realm> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Realm item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListRealmsAsync(LocationName, String, Nullable<Int32>, CallSettings)

public virtual PagedAsyncEnumerable<ListRealmsResponse, Realm> ListRealmsAsync(LocationName parent, string pageToken = null, int? pageSize = default(int? ), CallSettings callSettings = null)

Lists realms in a given project and location.

Parameters
NameDescription
parentLocationName

Required. The parent resource name, in the following form: projects/{project}/locations/{location}.

pageTokenString

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSizeNullable<Int32>

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerable<ListRealmsResponse, Realm>

A pageable asynchronous sequence of Realm resources.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedAsyncEnumerable<ListRealmsResponse, Realm> response = realmsServiceClient.ListRealmsAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((Realm item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListRealmsResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Realm item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
});

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Realm> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Realm item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListRealmsAsync(ListRealmsRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListRealmsResponse, Realm> ListRealmsAsync(ListRealmsRequest request, CallSettings callSettings = null)

Lists realms in a given project and location.

Parameters
NameDescription
requestListRealmsRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerable<ListRealmsResponse, Realm>

A pageable asynchronous sequence of Realm resources.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
ListRealmsRequest request = new ListRealmsRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedAsyncEnumerable<ListRealmsResponse, Realm> response = realmsServiceClient.ListRealmsAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((Realm item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListRealmsResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Realm item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
});

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Realm> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Realm item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListRealmsAsync(String, String, Nullable<Int32>, CallSettings)

public virtual PagedAsyncEnumerable<ListRealmsResponse, Realm> ListRealmsAsync(string parent, string pageToken = null, int? pageSize = default(int? ), CallSettings callSettings = null)

Lists realms in a given project and location.

Parameters
NameDescription
parentString

Required. The parent resource name, in the following form: projects/{project}/locations/{location}.

pageTokenString

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSizeNullable<Int32>

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerable<ListRealmsResponse, Realm>

A pageable asynchronous sequence of Realm resources.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedAsyncEnumerable<ListRealmsResponse, Realm> response = realmsServiceClient.ListRealmsAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((Realm item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListRealmsResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Realm item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
});

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Realm> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Realm item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

PollOnceCreateRealm(String, CallSettings)

public virtual Operation<Realm, OperationMetadata> PollOnceCreateRealm(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of CreateRealm.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Realm, OperationMetadata>

The result of polling the operation.

PollOnceCreateRealmAsync(String, CallSettings)

public virtual Task<Operation<Realm, OperationMetadata>> PollOnceCreateRealmAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of CreateRealm.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Realm, OperationMetadata>>

A task representing the result of polling the operation.

PollOnceDeleteRealm(String, CallSettings)

public virtual Operation<Empty, OperationMetadata> PollOnceDeleteRealm(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of DeleteRealm.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Empty, OperationMetadata>

The result of polling the operation.

PollOnceDeleteRealmAsync(String, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> PollOnceDeleteRealmAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of DeleteRealm.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Empty, OperationMetadata>>

A task representing the result of polling the operation.

PollOnceUpdateRealm(String, CallSettings)

public virtual Operation<Realm, OperationMetadata> PollOnceUpdateRealm(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of UpdateRealm.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Realm, OperationMetadata>

The result of polling the operation.

PollOnceUpdateRealmAsync(String, CallSettings)

public virtual Task<Operation<Realm, OperationMetadata>> PollOnceUpdateRealmAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of UpdateRealm.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Realm, OperationMetadata>>

A task representing the result of polling the operation.

PreviewRealmUpdate(PreviewRealmUpdateRequest, CallSettings)

public virtual PreviewRealmUpdateResponse PreviewRealmUpdate(PreviewRealmUpdateRequest request, CallSettings callSettings = null)

Previews patches to a single realm.

Parameters
NameDescription
requestPreviewRealmUpdateRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PreviewRealmUpdateResponse

The RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = RealmsServiceClient.Create();
// Initialize request argument(s)
PreviewRealmUpdateRequest request = new PreviewRealmUpdateRequest
{
    Realm = new Realm(),
    UpdateMask = new FieldMask(),
    PreviewTime = new Timestamp(),
};
// Make the request
PreviewRealmUpdateResponse response = realmsServiceClient.PreviewRealmUpdate(request);

PreviewRealmUpdateAsync(PreviewRealmUpdateRequest, CallSettings)

public virtual Task<PreviewRealmUpdateResponse> PreviewRealmUpdateAsync(PreviewRealmUpdateRequest request, CallSettings callSettings = null)

Previews patches to a single realm.

Parameters
NameDescription
requestPreviewRealmUpdateRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<PreviewRealmUpdateResponse>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
PreviewRealmUpdateRequest request = new PreviewRealmUpdateRequest
{
    Realm = new Realm(),
    UpdateMask = new FieldMask(),
    PreviewTime = new Timestamp(),
};
// Make the request
PreviewRealmUpdateResponse response = await realmsServiceClient.PreviewRealmUpdateAsync(request);

PreviewRealmUpdateAsync(PreviewRealmUpdateRequest, CancellationToken)

public virtual Task<PreviewRealmUpdateResponse> PreviewRealmUpdateAsync(PreviewRealmUpdateRequest request, CancellationToken cancellationToken)

Previews patches to a single realm.

Parameters
NameDescription
requestPreviewRealmUpdateRequest

The request object containing all of the parameters for the API call.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<PreviewRealmUpdateResponse>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
PreviewRealmUpdateRequest request = new PreviewRealmUpdateRequest
{
    Realm = new Realm(),
    UpdateMask = new FieldMask(),
    PreviewTime = new Timestamp(),
};
// Make the request
PreviewRealmUpdateResponse response = await realmsServiceClient.PreviewRealmUpdateAsync(request);

ShutdownDefaultChannelsAsync()

public static Task ShutdownDefaultChannelsAsync()

Shuts down any channels automatically created by Create() and CreateAsync(CancellationToken). Channels which weren't automatically created are not affected.

Returns
TypeDescription
Task

A task representing the asynchronous shutdown operation.

Remarks

After calling this method, further calls to Create() and CreateAsync(CancellationToken) will create new channels, which could in turn be shut down by another call to this method.

UpdateRealm(Realm, FieldMask, CallSettings)

public virtual Operation<Realm, OperationMetadata> UpdateRealm(Realm realm, FieldMask updateMask, CallSettings callSettings = null)

Patches a single realm.

Parameters
NameDescription
realmRealm

Required. The realm to be updated. Only fields specified in update_mask are updated.

updateMaskFieldMask

Required. The update mask applies to the resource. For the FieldMask definition, see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Realm, OperationMetadata>

The RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = RealmsServiceClient.Create();
// Initialize request argument(s)
Realm realm = new Realm();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<Realm, OperationMetadata> response = realmsServiceClient.UpdateRealm(realm, updateMask);

// Poll until the returned long-running operation is complete
Operation<Realm, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Realm result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Realm, OperationMetadata> retrievedResponse = realmsServiceClient.PollOnceUpdateRealm(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Realm retrievedResult = retrievedResponse.Result;
}

UpdateRealm(UpdateRealmRequest, CallSettings)

public virtual Operation<Realm, OperationMetadata> UpdateRealm(UpdateRealmRequest request, CallSettings callSettings = null)

Patches a single realm.

Parameters
NameDescription
requestUpdateRealmRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Realm, OperationMetadata>

The RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = RealmsServiceClient.Create();
// Initialize request argument(s)
UpdateRealmRequest request = new UpdateRealmRequest
{
    Realm = new Realm(),
    UpdateMask = new FieldMask(),
};
// Make the request
Operation<Realm, OperationMetadata> response = realmsServiceClient.UpdateRealm(request);

// Poll until the returned long-running operation is complete
Operation<Realm, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Realm result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Realm, OperationMetadata> retrievedResponse = realmsServiceClient.PollOnceUpdateRealm(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Realm retrievedResult = retrievedResponse.Result;
}

UpdateRealmAsync(Realm, FieldMask, CallSettings)

public virtual Task<Operation<Realm, OperationMetadata>> UpdateRealmAsync(Realm realm, FieldMask updateMask, CallSettings callSettings = null)

Patches a single realm.

Parameters
NameDescription
realmRealm

Required. The realm to be updated. Only fields specified in update_mask are updated.

updateMaskFieldMask

Required. The update mask applies to the resource. For the FieldMask definition, see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Realm, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
Realm realm = new Realm();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<Realm, OperationMetadata> response = await realmsServiceClient.UpdateRealmAsync(realm, updateMask);

// Poll until the returned long-running operation is complete
Operation<Realm, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Realm result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Realm, OperationMetadata> retrievedResponse = await realmsServiceClient.PollOnceUpdateRealmAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Realm retrievedResult = retrievedResponse.Result;
}

UpdateRealmAsync(Realm, FieldMask, CancellationToken)

public virtual Task<Operation<Realm, OperationMetadata>> UpdateRealmAsync(Realm realm, FieldMask updateMask, CancellationToken cancellationToken)

Patches a single realm.

Parameters
NameDescription
realmRealm

Required. The realm to be updated. Only fields specified in update_mask are updated.

updateMaskFieldMask

Required. The update mask applies to the resource. For the FieldMask definition, see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Realm, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
Realm realm = new Realm();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<Realm, OperationMetadata> response = await realmsServiceClient.UpdateRealmAsync(realm, updateMask);

// Poll until the returned long-running operation is complete
Operation<Realm, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Realm result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Realm, OperationMetadata> retrievedResponse = await realmsServiceClient.PollOnceUpdateRealmAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Realm retrievedResult = retrievedResponse.Result;
}

UpdateRealmAsync(UpdateRealmRequest, CallSettings)

public virtual Task<Operation<Realm, OperationMetadata>> UpdateRealmAsync(UpdateRealmRequest request, CallSettings callSettings = null)

Patches a single realm.

Parameters
NameDescription
requestUpdateRealmRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Realm, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
UpdateRealmRequest request = new UpdateRealmRequest
{
    Realm = new Realm(),
    UpdateMask = new FieldMask(),
};
// Make the request
Operation<Realm, OperationMetadata> response = await realmsServiceClient.UpdateRealmAsync(request);

// Poll until the returned long-running operation is complete
Operation<Realm, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Realm result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Realm, OperationMetadata> retrievedResponse = await realmsServiceClient.PollOnceUpdateRealmAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Realm retrievedResult = retrievedResponse.Result;
}

UpdateRealmAsync(UpdateRealmRequest, CancellationToken)

public virtual Task<Operation<Realm, OperationMetadata>> UpdateRealmAsync(UpdateRealmRequest request, CancellationToken cancellationToken)

Patches a single realm.

Parameters
NameDescription
requestUpdateRealmRequest

The request object containing all of the parameters for the API call.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Realm, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
RealmsServiceClient realmsServiceClient = await RealmsServiceClient.CreateAsync();
// Initialize request argument(s)
UpdateRealmRequest request = new UpdateRealmRequest
{
    Realm = new Realm(),
    UpdateMask = new FieldMask(),
};
// Make the request
Operation<Realm, OperationMetadata> response = await realmsServiceClient.UpdateRealmAsync(request);

// Poll until the returned long-running operation is complete
Operation<Realm, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Realm result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Realm, OperationMetadata> retrievedResponse = await realmsServiceClient.PollOnceUpdateRealmAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Realm retrievedResult = retrievedResponse.Result;
}