'Check the existence of an object before insertion.
If the insertion isn\'t applied, a LWTException is raised.'

def if_not_exists(self):

    if self.model._has_counter:
        raise IfNotExistsWithCounterColumn('if_not_exists    cannot    be    used    with    tables    containing    counter    columns')
    clone = copy.deepcopy(self)
    clone._if_not_exists = True
    return clone
