# Path: ethronsoft/gcspypi/exceptions/repository_errors.py
# class RepositoryError(Exception):
#     pass
# 
# Path: ethronsoft/gcspypi/exceptions/boundary_errors.py
# class NotFound(Exception):
#     pass
# 
# Path: ethronsoft/gcspypi/repository/object_metadata.py
# class ObjectMetadata(object):
#     """ObjectMetadata represents the metadata associated with a repository Object
#     """
# 
#     def __init__(self, mime, md5_hash, time_created):
#         """ObjectMetadata constructor
#         
#         Arguments:
#             mime {str} -- MIME type of object
#             md5_hash {str} -- Hash representing the object. Can be used to determine content equality
#             time_created {datetime} -- Timestamp for the object creation
#         """
# 
#         self.mime = mime
#         self.md5 = md5_hash
#         self.time_created = time_created


from google.cloud import storage
from ethronsoft.gcspypi.exceptions import RepositoryError, NotFound
from .object_metadata import ObjectMetadata
import six
import sys
import warnings
            return blob.delete() is not None
        except Exception:
            pass

    def exists(self, object_name):
        """Checks whether object `object_name` exists

        Arguments:
            object_name {str} -- Name of object to check for existence

        Returns:
            bool -- flag for existence
        """

        return self.bucket.blob(object_name).exists()

    def metadata(self, object_name):
        """[summary]

        Arguments:
            object_name Name of object to get metadata for

        Raises:
            cpm.exceptions.NotFound -- If the object does not exist

        Returns:
            cpm.repository.ObjectMetadata -- The object Metadata
        """

        if not self.bucket.blob(object_name).exists():

# Path: ethronsoft/gcspypi/exceptions/repository_errors.py
# class RepositoryError(Exception):
#     pass
# 
# Path: ethronsoft/gcspypi/exceptions/boundary_errors.py
# class NotFound(Exception):
#     pass
# 
# Path: ethronsoft/gcspypi/repository/object_metadata.py
# class ObjectMetadata(object):
#     """ObjectMetadata represents the metadata associated with a repository Object
#     """
# 
#     def __init__(self, mime, md5_hash, time_created):
#         """ObjectMetadata constructor
#         
#         Arguments:
#             mime {str} -- MIME type of object
#             md5_hash {str} -- Hash representing the object. Can be used to determine content equality
#             time_created {datetime} -- Timestamp for the object creation
#         """
# 
#         self.mime = mime
#         self.md5 = md5_hash
#         self.time_created = time_created


# Path: ethronsoft/gcspypi/repository/gcloud_remote.py
from google.cloud import storage
from ethronsoft.gcspypi.exceptions import RepositoryError, NotFound
from .object_metadata import ObjectMetadata
import six
import sys
import warnings

            return blob.delete() is not None
        except Exception:
            pass

    def exists(self, object_name):
        """Checks whether object `object_name` exists

        Arguments:
            object_name {str} -- Name of object to check for existence

        Returns:
            bool -- flag for existence
        """

        return self.bucket.blob(object_name).exists()

    def metadata(self, object_name):
        """[summary]

        Arguments:
            object_name Name of object to get metadata for

        Raises:
            cpm.exceptions.NotFound -- If the object does not exist

        Returns:
            cpm.repository.ObjectMetadata -- The object Metadata
        """

        if not self.bucket.blob(object_name).exists():

            raise NotFound("{0} does not exist".format(object_name))