Did I find the right examples for you? yes no

All Samples(16)  |  Call(8)  |  Derive(0)  |  Import(8)
Return all versioned column properties for given versioned SQLAlchemy
declarative model object.

:param obj: SQLAlchemy declarative model object

        def versioned_column_properties(obj_or_class):
    """
    Return all versioned column properties for given versioned SQLAlchemy
    declarative model object.

    :param obj: SQLAlchemy declarative model object
    """
    manager = get_versioning_manager(obj_or_class)

    cls = obj_or_class if isclass(obj_or_class) else obj_or_class.__class__

    for prop in sa.inspect(cls).attrs.values():
        if not isinstance(prop, ColumnProperty):
            continue
        if not manager.is_excluded_column(obj_or_class, prop.columns[0]):
            yield prop
        


src/s/q/SQLAlchemy-Continuum-1.0-b4/sqlalchemy_continuum/plugins/null_delete.py   SQLAlchemy-Continuum(Download)
from .base import Plugin
from ..operation import Operation
from ..utils import versioned_column_properties, is_internal_column
 
 
    def after_create_version_object(self, uow, parent_obj, version_obj):
        for prop in versioned_column_properties(parent_obj):
            if self.should_nullify_column(version_obj, prop):
                setattr(version_obj, prop.key, None)
 

src/s/q/sqlalchemy-continuum-HEAD/sqlalchemy_continuum/plugins/null_delete.py   sqlalchemy-continuum(Download)
from .base import Plugin
from ..operation import Operation
from ..utils import versioned_column_properties, is_internal_column
 
 
    def after_create_version_object(self, uow, parent_obj, version_obj):
        for prop in versioned_column_properties(parent_obj):
            if self.should_nullify_column(version_obj, prop):
                setattr(version_obj, prop.key, None)
 

src/s/q/SQLAlchemy-Continuum-1.0-b4/sqlalchemy_continuum/reverter.py   SQLAlchemy-Continuum(Download)
import sqlalchemy as sa
from .operation import Operation
from .utils import versioned_column_properties, parent_class
 
 
    def revert_properties(self):
        for prop in versioned_column_properties(self.parent_class):
            setattr(
                self.version_parent,
                prop.key,

src/s/q/sqlalchemy-continuum-HEAD/sqlalchemy_continuum/reverter.py   sqlalchemy-continuum(Download)
import sqlalchemy as sa
from .operation import Operation
from .utils import versioned_column_properties, parent_class
 
 
    def revert_properties(self):
        for prop in versioned_column_properties(self.parent_class):
            setattr(
                self.version_parent,
                prop.key,

src/s/q/SQLAlchemy-Continuum-1.0-b4/sqlalchemy_continuum/unit_of_work.py   SQLAlchemy-Continuum(Download)
from .fetcher import parent_criteria
from .operation import Operations
from .utils import (
    end_tx_column_name,
    version_class,
            Version object to assign the attribute values to
        """
        for prop in versioned_column_properties(parent_obj):
            value = getattr(parent_obj, prop.key)
            setattr(version_obj, prop.key, value)

src/s/q/sqlalchemy-continuum-HEAD/sqlalchemy_continuum/unit_of_work.py   sqlalchemy-continuum(Download)
from .fetcher import parent_criteria
from .operation import Operations
from .utils import (
    end_tx_column_name,
    version_class,
            Version object to assign the attribute values to
        """
        for prop in versioned_column_properties(parent_obj):
            value = getattr(parent_obj, prop.key)
            setattr(version_obj, prop.key, value)

src/s/q/SQLAlchemy-Continuum-1.0-b4/sqlalchemy_continuum/plugins/property_mod_tracker.py   SQLAlchemy-Continuum(Download)
from sqlalchemy_utils.functions import has_changes
from .base import Plugin
from ..utils import versioned_column_properties
 
 
    def after_create_version_object(self, uow, parent_obj, version_obj):
        for prop in versioned_column_properties(parent_obj):
            if has_changes(parent_obj, prop.key):
                setattr(
                    version_obj,

src/s/q/sqlalchemy-continuum-HEAD/sqlalchemy_continuum/plugins/property_mod_tracker.py   sqlalchemy-continuum(Download)
from sqlalchemy_utils.functions import has_changes
from .base import Plugin
from ..utils import versioned_column_properties
 
 
    def after_create_version_object(self, uow, parent_obj, version_obj):
        for prop in versioned_column_properties(parent_obj):
            if has_changes(parent_obj, prop.key):
                setattr(
                    version_obj,