''

def __init__(self, layer, database=None, username=None, password=None, hostname=None):

    self.layer = layer
    self.dbkwargs = {}
    if hostname:
        self.dbkwargs['host'] = hostname
    if username:
        self.dbkwargs['user'] = username
    if database:
        self.dbkwargs['database'] = database
    if password:
        self.dbkwargs['password'] = password
