def replace(elem):
    for (_orm_only, adapter) in adapters:
        if ((not _orm_only) or ('_orm_adapt' in elem._annotations) or ('parententity' in elem._annotations)):
            e = adapter(elem)
            if (e is not None):
                return e
def replace(elem):
    for (_orm_only, adapter) in adapters:
        if ((not _orm_only) or ('_orm_adapt' in elem._annotations) or ('parententity' in elem._annotations)):
            e = adapter(elem)
            if (e is not None):
                return e