[][src]Struct google_pubsub1_beta2::ProjectMethods

pub struct ProjectMethods<'a, C, A> where
    C: 'a,
    A: 'a, 
{ /* fields omitted */ }

A builder providing access to all methods supported on project resources. It is not used directly, but through the Pubsub hub.

Example

Instantiate a resource builder

extern crate hyper;
extern crate hyper_rustls;
extern crate yup_oauth2 as oauth2;
extern crate google_pubsub1_beta2 as pubsub1_beta2;
 
use std::default::Default;
use oauth2::{Authenticator, DefaultAuthenticatorDelegate, ApplicationSecret, MemoryStorage};
use pubsub1_beta2::Pubsub;
 
let secret: ApplicationSecret = Default::default();
let auth = Authenticator::new(&secret, DefaultAuthenticatorDelegate,
                              hyper::Client::with_connector(hyper::net::HttpsConnector::new(hyper_rustls::TlsClient::new())),
                              <MemoryStorage as Default>::default(), None);
let mut hub = Pubsub::new(hyper::Client::with_connector(hyper::net::HttpsConnector::new(hyper_rustls::TlsClient::new())), auth);
// Usually you wouldn't bind this to a variable, but keep calling *CallBuilders*
// like `subscriptions_acknowledge(...)`, `subscriptions_create(...)`, `subscriptions_delete(...)`, `subscriptions_get(...)`, `subscriptions_get_iam_policy(...)`, `subscriptions_list(...)`, `subscriptions_modify_ack_deadline(...)`, `subscriptions_modify_push_config(...)`, `subscriptions_pull(...)`, `subscriptions_set_iam_policy(...)`, `subscriptions_test_iam_permissions(...)`, `topics_create(...)`, `topics_delete(...)`, `topics_get(...)`, `topics_get_iam_policy(...)`, `topics_list(...)`, `topics_publish(...)`, `topics_set_iam_policy(...)`, `topics_subscriptions_list(...)` and `topics_test_iam_permissions(...)`
// to build up your call.
let rb = hub.projects();

Methods

impl<'a, C, A> ProjectMethods<'a, C, A>[src]

pub fn topics_list(&self, project: &str) -> ProjectTopicListCall<'a, C, A>[src]

Create a builder to help you perform the following task:

Lists matching topics.

Arguments

  • project - The name of the cloud project that topics belong to.

pub fn subscriptions_pull(
    &self,
    request: PullRequest,
    subscription: &str
) -> ProjectSubscriptionPullCall<'a, C, A>
[src]

Create a builder to help you perform the following task:

Pulls messages from the server. Returns an empty list if there are no messages available in the backlog. The server may return UNAVAILABLE if there are too many concurrent pull requests pending for the given subscription.

Arguments

  • request - No description provided.
  • subscription - The subscription from which messages should be pulled.

pub fn topics_create(
    &self,
    request: Topic,
    name: &str
) -> ProjectTopicCreateCall<'a, C, A>
[src]

Create a builder to help you perform the following task:

Creates the given topic with the given name.

Arguments

  • request - No description provided.
  • name - The name of the topic. It must have the format "projects/{project}/topics/{topic}". {topic} must start with a letter, and contain only letters ([A-Za-z]), numbers ([0-9]), dashes (-), underscores (_), periods (.), tildes (~), plus (+) or percent signs (%). It must be between 3 and 255 characters in length, and it must not start with "goog".

pub fn topics_test_iam_permissions(
    &self,
    request: TestIamPermissionsRequest,
    resource: &str
) -> ProjectTopicTestIamPermissionCall<'a, C, A>
[src]

Create a builder to help you perform the following task:

Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a NOT_FOUND error.

Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may "fail open" without warning.

Arguments

  • request - No description provided.
  • resource - REQUIRED: The resource for which the policy detail is being requested. See the operation documentation for the appropriate value for this field.

pub fn subscriptions_modify_push_config(
    &self,
    request: ModifyPushConfigRequest,
    subscription: &str
) -> ProjectSubscriptionModifyPushConfigCall<'a, C, A>
[src]

Create a builder to help you perform the following task:

Modifies the PushConfig for a specified subscription.

This may be used to change a push subscription to a pull one (signified by an empty PushConfig) or vice versa, or change the endpoint URL and other attributes of a push subscription. Messages will accumulate for delivery continuously through the call regardless of changes to the PushConfig.

Arguments

  • request - No description provided.
  • subscription - The name of the subscription.

pub fn topics_publish(
    &self,
    request: PublishRequest,
    topic: &str
) -> ProjectTopicPublishCall<'a, C, A>
[src]

Create a builder to help you perform the following task:

Adds one or more messages to the topic. Returns NOT_FOUND if the topic does not exist. The message payload must not be empty; it must contain either a non-empty data field, or at least one attribute.

Arguments

  • request - No description provided.
  • topic - The messages in the request will be published on this topic.

pub fn topics_get(&self, topic: &str) -> ProjectTopicGetCall<'a, C, A>[src]

Create a builder to help you perform the following task:

Gets the configuration of a topic.

Arguments

  • topic - The name of the topic to get.

pub fn topics_get_iam_policy(
    &self,
    resource: &str
) -> ProjectTopicGetIamPolicyCall<'a, C, A>
[src]

Create a builder to help you perform the following task:

Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.

Arguments

  • resource - REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field.

pub fn subscriptions_modify_ack_deadline(
    &self,
    request: ModifyAckDeadlineRequest,
    subscription: &str
) -> ProjectSubscriptionModifyAckDeadlineCall<'a, C, A>
[src]

Create a builder to help you perform the following task:

Modifies the ack deadline for a specific message. This method is useful to indicate that more time is needed to process a message by the subscriber, or to make the message available for redelivery if the processing was interrupted. Note that this does not modify the subscription-level ackDeadlineSeconds used for subsequent messages.

Arguments

  • request - No description provided.
  • subscription - The name of the subscription.

pub fn subscriptions_delete(
    &self,
    subscription: &str
) -> ProjectSubscriptionDeleteCall<'a, C, A>
[src]

Create a builder to help you perform the following task:

Deletes an existing subscription. All pending messages in the subscription are immediately dropped. Calls to Pull after deletion will return NOT_FOUND. After a subscription is deleted, a new one may be created with the same name, but the new one has no association with the old subscription, or its topic unless the same topic is specified.

Arguments

  • subscription - The subscription to delete.

pub fn topics_set_iam_policy(
    &self,
    request: SetIamPolicyRequest,
    resource: &str
) -> ProjectTopicSetIamPolicyCall<'a, C, A>
[src]

Create a builder to help you perform the following task:

Sets the access control policy on the specified resource. Replaces any existing policy.

Arguments

  • request - No description provided.
  • resource - REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field.

pub fn subscriptions_create(
    &self,
    request: Subscription,
    name: &str
) -> ProjectSubscriptionCreateCall<'a, C, A>
[src]

Create a builder to help you perform the following task:

Creates a subscription to a given topic. If the subscription already exists, returns ALREADY_EXISTS. If the corresponding topic doesn't exist, returns NOT_FOUND.

If the name is not provided in the request, the server will assign a random name for this subscription on the same project as the topic. Note that for REST API requests, you must specify a name.

Arguments

  • request - No description provided.
  • name - The name of the subscription. It must have the format "projects/{project}/subscriptions/{subscription}". {subscription} must start with a letter, and contain only letters ([A-Za-z]), numbers ([0-9]), dashes (-), underscores (_), periods (.), tildes (~), plus (+) or percent signs (%). It must be between 3 and 255 characters in length, and it must not start with "goog".

pub fn subscriptions_acknowledge(
    &self,
    request: AcknowledgeRequest,
    subscription: &str
) -> ProjectSubscriptionAcknowledgeCall<'a, C, A>
[src]

Create a builder to help you perform the following task:

Acknowledges the messages associated with the ack_ids in the AcknowledgeRequest. The Pub/Sub system can remove the relevant messages from the subscription.

Acknowledging a message whose ack deadline has expired may succeed, but such a message may be redelivered later. Acknowledging a message more than once will not result in an error.

Arguments

  • request - No description provided.
  • subscription - The subscription whose message is being acknowledged.

pub fn subscriptions_get_iam_policy(
    &self,
    resource: &str
) -> ProjectSubscriptionGetIamPolicyCall<'a, C, A>
[src]

Create a builder to help you perform the following task:

Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.

Arguments

  • resource - REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field.

pub fn subscriptions_test_iam_permissions(
    &self,
    request: TestIamPermissionsRequest,
    resource: &str
) -> ProjectSubscriptionTestIamPermissionCall<'a, C, A>
[src]

Create a builder to help you perform the following task:

Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a NOT_FOUND error.

Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may "fail open" without warning.

Arguments

  • request - No description provided.
  • resource - REQUIRED: The resource for which the policy detail is being requested. See the operation documentation for the appropriate value for this field.

pub fn topics_delete(&self, topic: &str) -> ProjectTopicDeleteCall<'a, C, A>[src]

Create a builder to help you perform the following task:

Deletes the topic with the given name. Returns NOT_FOUND if the topic does not exist. After a topic is deleted, a new topic may be created with the same name; this is an entirely new topic with none of the old configuration or subscriptions. Existing subscriptions to this topic are not deleted, but their topic field is set to _deleted-topic_.

Arguments

  • topic - Name of the topic to delete.

pub fn subscriptions_get(
    &self,
    subscription: &str
) -> ProjectSubscriptionGetCall<'a, C, A>
[src]

Create a builder to help you perform the following task:

Gets the configuration details of a subscription.

Arguments

  • subscription - The name of the subscription to get.

pub fn topics_subscriptions_list(
    &self,
    topic: &str
) -> ProjectTopicSubscriptionListCall<'a, C, A>
[src]

Create a builder to help you perform the following task:

Lists the name of the subscriptions for this topic.

Arguments

  • topic - The name of the topic that subscriptions are attached to.

pub fn subscriptions_list(
    &self,
    project: &str
) -> ProjectSubscriptionListCall<'a, C, A>
[src]

Create a builder to help you perform the following task:

Lists matching subscriptions.

Arguments

  • project - The name of the cloud project that subscriptions belong to.

pub fn subscriptions_set_iam_policy(
    &self,
    request: SetIamPolicyRequest,
    resource: &str
) -> ProjectSubscriptionSetIamPolicyCall<'a, C, A>
[src]

Create a builder to help you perform the following task:

Sets the access control policy on the specified resource. Replaces any existing policy.

Arguments

  • request - No description provided.
  • resource - REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field.

Trait Implementations

impl<'a, C, A> MethodsBuilder for ProjectMethods<'a, C, A>[src]

Auto Trait Implementations

impl<'a, C, A> !Send for ProjectMethods<'a, C, A>

impl<'a, C, A> Unpin for ProjectMethods<'a, C, A>

impl<'a, C, A> !Sync for ProjectMethods<'a, C, A>

impl<'a, C, A> !UnwindSafe for ProjectMethods<'a, C, A>

impl<'a, C, A> !RefUnwindSafe for ProjectMethods<'a, C, A>

Blanket Implementations

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Typeable for T where
    T: Any

fn get_type(&self) -> TypeId

Get the TypeId of this object.