Пример #1
0
    def bucket_exist(self, bucket_name: str) -> bool:
        """

        :param bucket_name:
        :return:
        """
        return MinioStorage(self).bucket_exist(bucket_name)
Пример #2
0
 def list_objects_in_bucket(self, bucket_name: str) -> dict:
     """
     returns a list of all objects stored in the specified Minio bucket
     :param bucket_name:
     :return:
     """
     return MinioStorage(self).list_objects_in_bucket(bucket_name)
Пример #3
0
 def get_object(self, bucket_name: str, object_name: str) -> object:
     """
     Returns stored object (HttpResponse)
     :param bucket_name:
     :param object_name:
     :return:
     """
     return MinioStorage(self).get_object(bucket_name, object_name)
Пример #4
0
 def get_object_stat(self, bucket_name: str, object_name: str) -> dict:
     """
     Returns properties (e.g., object type, last modified etc.) of an object stored in a specified bucket
     :param bucket_name:
     :param object_name:
     :return:
     """
     return MinioStorage(self).get_object_stat(bucket_name, object_name)
Пример #5
0
 def list_buckets(self) -> dict:
     """
     Fetch all available buckets from Minio
     :return:
     """
     return MinioStorage(self).list_buckets()