亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? interfaces.py

?? SQLAlchemy. 經(jīng)典的Python ORM框架。學(xué)習(xí)必看。
?? PY
?? 第 1 頁 / 共 2 頁
字號:
# interfaces.py# Copyright (C) 2005, 2006, 2007, 2008 Michael Bayer mike_mp@zzzcomputing.com## This module is part of SQLAlchemy and is released under# the MIT License: http://www.opensource.org/licenses/mit-license.php"""Semi-private implementation objects which form the basisof ORM-mapped attributes, query options and mapper extension.Defines the [sqlalchemy.orm.interfaces#MapperExtension] class,which can be end-user subclassed to add event-based functionalityto mappers.  The remainder of this module is generally private to theORM."""from itertools import chainfrom sqlalchemy import exceptions, loggingfrom sqlalchemy.sql import expressionclass_mapper = None__all__ = ['EXT_CONTINUE', 'EXT_STOP', 'EXT_PASS', 'MapperExtension',           'MapperProperty', 'PropComparator', 'StrategizedProperty',           'build_path', 'MapperOption',           'ExtensionOption', 'PropertyOption',           'AttributeExtension', 'StrategizedOption', 'LoaderStrategy' ]EXT_CONTINUE = EXT_PASS = object()EXT_STOP = object()class MapperExtension(object):    """Base implementation for customizing Mapper behavior.    For each method in MapperExtension, returning a result of EXT_CONTINUE    will allow processing to continue to the next MapperExtension in line or    use the default functionality if there are no other extensions.    Returning EXT_STOP will halt processing of further extensions handling    that method.  Some methods such as ``load`` have other return    requirements, see the individual documentation for details.  Other than    these exception cases, any return value other than EXT_CONTINUE or    EXT_STOP will be interpreted as equivalent to EXT_STOP.    EXT_PASS is a synonym for EXT_CONTINUE and is provided for backward    compatibility.    """    def instrument_class(self, mapper, class_):        return EXT_CONTINUE    def init_instance(self, mapper, class_, oldinit, instance, args, kwargs):        return EXT_CONTINUE    def init_failed(self, mapper, class_, oldinit, instance, args, kwargs):        return EXT_CONTINUE    def get_session(self):        """Retrieve a contextual Session instance with which to        register a new object.        Note: this is not called if a session is provided with the        `__init__` params (i.e. `_sa_session`).        """        return EXT_CONTINUE    def load(self, query, *args, **kwargs):        """Override the `load` method of the Query object.        The return value of this method is used as the result of        ``query.load()`` if the value is anything other than EXT_CONTINUE.        """        return EXT_CONTINUE    def get(self, query, *args, **kwargs):        """Override the `get` method of the Query object.        The return value of this method is used as the result of        ``query.get()`` if the value is anything other than EXT_CONTINUE.        """        return EXT_CONTINUE    def get_by(self, query, *args, **kwargs):        """Override the `get_by` method of the Query object.        The return value of this method is used as the result of        ``query.get_by()`` if the value is anything other than        EXT_CONTINUE.        DEPRECATED.        """        return EXT_CONTINUE    def select_by(self, query, *args, **kwargs):        """Override the `select_by` method of the Query object.        The return value of this method is used as the result of        ``query.select_by()`` if the value is anything other than        EXT_CONTINUE.        DEPRECATED.        """        return EXT_CONTINUE    def select(self, query, *args, **kwargs):        """Override the `select` method of the Query object.        The return value of this method is used as the result of        ``query.select()`` if the value is anything other than        EXT_CONTINUE.        DEPRECATED.        """        return EXT_CONTINUE    def translate_row(self, mapper, context, row):        """Perform pre-processing on the given result row and return a        new row instance.        This is called as the very first step in the ``_instance()``        method.        """        return EXT_CONTINUE    def create_instance(self, mapper, selectcontext, row, class_):        """Receive a row when a new object instance is about to be        created from that row.        The method can choose to create the instance itself, or it can return        EXT_CONTINUE to indicate normal object creation should take place.        mapper          The mapper doing the operation        selectcontext          SelectionContext corresponding to the instances() call        row          The result row from the database        class\_          The class we are mapping.        return value          A new object instance, or EXT_CONTINUE        """        return EXT_CONTINUE    def append_result(self, mapper, selectcontext, row, instance, result, **flags):        """Receive an object instance before that instance is appended        to a result list.        If this method returns EXT_CONTINUE, result appending will proceed        normally.  if this method returns any other value or None,        result appending will not proceed for this instance, giving        this extension an opportunity to do the appending itself, if        desired.        mapper          The mapper doing the operation.        selectcontext          SelectionContext corresponding to the instances() call.        row          The result row from the database.        instance          The object instance to be appended to the result.        result          List to which results are being appended.        \**flags          extra information about the row, same as criterion in          `create_row_processor()` method of [sqlalchemy.orm.interfaces#MapperProperty]        """        return EXT_CONTINUE    def populate_instance(self, mapper, selectcontext, row, instance, **flags):        """Receive a newly-created instance before that instance has        its attributes populated.        The normal population of attributes is according to each        attribute's corresponding MapperProperty (which includes        column-based attributes as well as relationships to other        classes).  If this method returns EXT_CONTINUE, instance        population will proceed normally.  If any other value or None        is returned, instance population will not proceed, giving this        extension an opportunity to populate the instance itself, if        desired.        """        return EXT_CONTINUE    def before_insert(self, mapper, connection, instance):        """Receive an object instance before that instance is INSERTed        into its table.        This is a good place to set up primary key values and such        that aren't handled otherwise.        Column-based attributes can be modified within this method which will        result in the new value being inserted.  However *no* changes to the overall        flush plan can be made; this means any collection modification or        save() operations which occur within this method will not take effect        until the next flush call.        """        return EXT_CONTINUE    def after_insert(self, mapper, connection, instance):        """Receive an object instance after that instance is INSERTed."""        return EXT_CONTINUE    def before_update(self, mapper, connection, instance):        """Receive an object instance before that instance is UPDATEed.        Note that this method is called for all instances that are marked as        "dirty", even those which have no net changes to their column-based        attributes.  An object is marked as dirty when any of its column-based        attributes have a "set attribute" operation called or when any of its        collections are modified.  If, at update time, no column-based attributes        have any net changes, no UPDATE statement will be issued.  This means        that an instance being sent to before_update is *not* a guarantee that        an UPDATE statement will be issued (although you can affect the outcome        here).        To detect if the column-based attributes on the object have net changes,        and will therefore generate an UPDATE statement, use        ``object_session(instance).is_modified(instance, include_collections=False)``.        Column-based attributes can be modified within this method which will        result in their being updated.  However *no* changes to the overall        flush plan can be made; this means any collection modification or        save() operations which occur within this method will not take effect        until the next flush call.        """        return EXT_CONTINUE    def after_update(self, mapper, connection, instance):        """Receive an object instance after that instance is UPDATEed."""        return EXT_CONTINUE    def before_delete(self, mapper, connection, instance):        """Receive an object instance before that instance is DELETEed.        Note that *no* changes to the overall        flush plan can be made here; this means any collection modification,        save() or delete() operations which occur within this method will        not take effect until the next flush call.        """        return EXT_CONTINUE    def after_delete(self, mapper, connection, instance):        """Receive an object instance after that instance is DELETEed."""        return EXT_CONTINUEclass MapperProperty(object):    """Manage the relationship of a ``Mapper`` to a single class    attribute, as well as that attribute as it appears on individual    instances of the class, including attribute instrumentation,    attribute access, loading behavior, and dependency calculations.    """    def setup(self, querycontext, **kwargs):        """Called by Query for the purposes of constructing a SQL statement.        Each MapperProperty associated with the target mapper processes the        statement referenced by the query context, adding columns and/or        criterion as appropriate.        """        pass    def create_row_processor(self, selectcontext, mapper, row):        """Return a 3-tuple consiting of two row processing functions and an instance post-processing function.        Input arguments are the query.SelectionContext and the *first*        applicable row of a result set obtained within        query.Query.instances(), called only the first time a particular        mapper's populate_instance() method is invoked for the overall result.        The settings contained within the SelectionContext as well as the        columns present in the row (which will be the same columns present in        all rows) are used to determine the presence and behavior of the        returned callables.  The callables will then be used to process all        rows and to post-process all instances, respectively.        Callables are of the following form::            def new_execute(instance, row, **flags):                # process incoming instance and given row.  the instance is                # "new" and was just created upon receipt of this row.                # flags is a dictionary containing at least the following                # attributes:                #   isnew - indicates if the instance was newly created as a                #           result of reading this row                #   instancekey - identity key of the instance                # optional attribute:                #   ispostselect - indicates if this row resulted from a                #                  'post' select of additional tables/columns            def existing_execute(instance, row, **flags):                # process incoming instance and given row.  the instance is                # "existing" and was created based on a previous row.            def post_execute(instance, **flags):                # process instance after all result rows have been processed.                # this function should be used to issue additional selections                # in order to eagerly load additional properties.            return (new_execute, existing_execute, post_execute)        Either of the three tuples can be ``None`` in which case no function        is called.        """        raise NotImplementedError()    def cascade_iterator(self, type, object, recursive=None, halt_on=None):        """Iterate through instances related to the given instance along        a particular 'cascade' path, starting with this MapperProperty.        See PropertyLoader for the related instance implementation.        """        return iter([])    def get_criterion(self, query, key, value):        """Return a ``WHERE`` clause suitable for this        ``MapperProperty`` corresponding to the given key/value pair,        where the key is a column or object property name, and value        is a value to be matched.  This is only picked up by

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产精品欧美一级免费| 成人深夜福利app| 亚洲国产毛片aaaaa无费看| 亚洲免费观看在线观看| 一区在线观看免费| 综合网在线视频| 最新热久久免费视频| 中文字幕在线观看不卡| 日韩理论片网站| 一区二区理论电影在线观看| 亚洲免费观看高清完整版在线观看| 亚洲婷婷综合色高清在线| 一区二区三区四区国产精品| 一区二区三区成人在线视频 | 婷婷丁香久久五月婷婷| 亚洲一区二区高清| 欧美a级理论片| 精品亚洲成a人在线观看| 国产精品资源在线| 91视频一区二区三区| 在线视频一区二区三区| 4438x成人网最大色成网站| 日韩色在线观看| 国产亚洲婷婷免费| 亚洲男人的天堂一区二区| 性久久久久久久久| 麻豆91在线看| 成人精品国产免费网站| 色婷婷av一区二区三区大白胸| 欧美精品在线一区二区三区| 久久综合色播五月| 中文字幕日本乱码精品影院| 亚洲第四色夜色| 韩国欧美国产一区| 99久久婷婷国产| 欧美色手机在线观看| 久久综合九色综合97婷婷女人| 亚洲国产精华液网站w| 亚洲一区在线视频观看| 国产综合久久久久久鬼色| 97久久人人超碰| 欧美精品成人一区二区三区四区| 久久久亚洲精华液精华液精华液| 亚洲欧美日韩成人高清在线一区| 日本午夜精品视频在线观看| 国产99久久久国产精品潘金| 97久久精品人人澡人人爽| 色综合久久综合中文综合网| 91精品国产色综合久久久蜜香臀| 26uuu精品一区二区在线观看| 自拍偷拍国产亚洲| 久久av资源站| 欧美中文字幕久久| 国产日韩欧美综合一区| 亚洲国产日韩a在线播放| 国产成人啪免费观看软件 | 亚洲色图丝袜美腿| 久久精品国产一区二区三区免费看| 成人国产亚洲欧美成人综合网| 欧美日韩在线综合| 国产精品久久久久一区| 美女www一区二区| 91极品美女在线| 久久精品在线观看| 婷婷中文字幕一区三区| 成人h动漫精品| 精品日产卡一卡二卡麻豆| 亚洲国产视频a| 成人av免费在线观看| 日韩精品专区在线| 亚洲成va人在线观看| 99精品久久只有精品| 国产三级欧美三级| 久久国产生活片100| 欧美日韩你懂得| 亚洲精品综合在线| 成人精品小蝌蚪| 欧美精品一区二区三区在线播放| 亚洲综合图片区| 91在线视频观看| 中文字幕免费观看一区| 韩国女主播一区二区三区| 777久久久精品| 亚洲国产成人91porn| 色欧美日韩亚洲| 亚洲乱码国产乱码精品精的特点 | 日本欧洲一区二区| 欧美日韩一级二级| 亚洲图片自拍偷拍| 91国偷自产一区二区三区成为亚洲经典| 中文字幕av一区二区三区高 | 欧美一区二区三区在线观看视频| 夜夜嗨av一区二区三区| 91视频精品在这里| 亚洲视频在线一区| 91丝袜呻吟高潮美腿白嫩在线观看| 欧美高清在线一区| 成人美女在线观看| 国产精品污网站| 波多野结衣欧美| 综合久久给合久久狠狠狠97色| 成人一区在线看| 1024国产精品| 色综合久久久久综合99| 一区二区三区资源| 欧美日韩中文一区| 日本欧美加勒比视频| 日韩一区二区三区精品视频| 日韩在线观看一区二区| 欧美一区中文字幕| 久久99这里只有精品| 26uuu精品一区二区在线观看| 国产综合色视频| 中文字幕欧美激情| 色婷婷久久久综合中文字幕| 亚洲一区二区3| 欧美日韩国产另类一区| 蜜桃视频在线观看一区二区| 日韩精品在线一区| 国产超碰在线一区| 亚洲区小说区图片区qvod| 在线观看日韩毛片| 日本亚洲一区二区| 国产亚洲精品超碰| 成人免费黄色大片| 亚洲成人中文在线| 精品久久久久av影院| 成人avav在线| 亚洲一区二区高清| 精品国产髙清在线看国产毛片| 丁香天五香天堂综合| 尤物视频一区二区| 欧美变态凌虐bdsm| proumb性欧美在线观看| 亚洲综合丝袜美腿| 精品国产一区久久| 成人av免费观看| 日韩精品久久久久久| 久久久蜜桃精品| 在线观看免费亚洲| 国内精品在线播放| 一区二区三区国产精华| 精品国产精品一区二区夜夜嗨| 99久久综合狠狠综合久久| 五月婷婷激情综合网| 久久精品人人做人人综合| 91福利小视频| 国产精品99久久久久久久女警| 亚洲欧美二区三区| 欧美本精品男人aⅴ天堂| 成人国产精品视频| 日韩精品五月天| 中文字幕中文乱码欧美一区二区 | 亚洲国产精品一区二区www在线| 日韩精品最新网址| 色妞www精品视频| 国产在线一区观看| 亚洲大型综合色站| 国产精品剧情在线亚洲| 欧美一区二区三区视频免费播放| 成人综合婷婷国产精品久久免费| 亚洲大片一区二区三区| 国产精品免费看片| 精品久久人人做人人爽| 欧美少妇bbb| 成人福利在线看| 麻豆成人91精品二区三区| 一区二区三区四区精品在线视频| 国产丝袜欧美中文另类| 日韩一区二区不卡| 欧美视频精品在线| 97se亚洲国产综合自在线观| 精品一区二区三区蜜桃| 亚洲国产精品一区二区久久恐怖片| 亚洲国产精品高清| 2023国产精华国产精品| 91.麻豆视频| 欧美性三三影院| 色综合中文字幕国产| 极品少妇一区二区三区精品视频 | 日韩影院免费视频| 亚洲综合小说图片| 亚洲天堂中文字幕| 国产精品美女久久久久aⅴ| 欧美成人一区二区三区片免费| 欧美日韩成人一区| 欧美网站一区二区| 在线欧美一区二区| 一本一本久久a久久精品综合麻豆| 国产精品综合一区二区三区| 裸体健美xxxx欧美裸体表演| 天天免费综合色| 亚洲成人av在线电影| 亚洲国产欧美一区二区三区丁香婷| 国产精品久久久久桃色tv| 国产精品你懂的在线| 国产精品理论在线观看| 国产日韩欧美精品一区| 久久精品视频在线免费观看| 久久丝袜美腿综合|