def Run(self, args): """This is what gets called when the user runs this command. Args: args: an argparse namespace. All the arguments that were provided to this command invocation. Returns: The specified bucket. """ return util.GetClient().projects_locations_buckets.Get( util.GetMessages().LoggingProjectsLocationsBucketsGetRequest( name=util.CreateResourceName( util.GetBucketLocationFromArgs(args), 'buckets', args.BUCKET_ID)))
def Run(self, args): """This is what gets called when the user runs this command. Args: args: an argparse namespace. All the arguments that were provided to this command invocation. Yields: The list of buckets. """ result = util.GetClient().projects_locations_buckets.List( util.GetMessages().LoggingProjectsLocationsBucketsListRequest( parent=util.GetBucketLocationFromArgs(args))) for bucket in result.buckets: yield bucket
def Run(self, args): """This is what gets called when the user runs this command. Args: args: an argparse namespace. All the arguments that were provided to this command invocation. """ util.GetClient().projects_locations_buckets_views.Delete( util.GetMessages( ).LoggingProjectsLocationsBucketsViewsDeleteRequest( name=util.CreateResourceName( util.CreateResourceName( util.GetBucketLocationFromArgs(args), 'buckets', args.bucket), 'views', args.VIEW_ID))) log.DeletedResource(args.VIEW_ID)