コード例 #1
0
    def adapt(self, cls, **kw):
        """Produce an "adapted" form of this type, given an "impl" class 
        to work with. 

        This method is used internally to associate generic 
        types with "implementation" types that are specific to a particular
        dialect.
        """
        return util.constructor_copy(self, cls, **kw)
コード例 #2
0
ファイル: base.py プロジェクト: Noura/storytime
 def adapt(self, cls, **kw):
     if self._storage_format:
         kw["storage_format"] = self._storage_format
     if self._reg:
         kw["regexp"] = self._reg
     return util.constructor_copy(self, cls, **kw)
コード例 #3
0
 def adapt(self, cls, **kw):
     if self._storage_format:
         kw["storage_format"] = self._storage_format
     if self._reg:
         kw["regexp"] = self._reg
     return util.constructor_copy(self, cls, **kw)