Defines visitor symbols used for internal traversal. The :class:`.InternalTraversal` class is used in two ways. One is that it can serve as the superclass for an object that implements the various visit methods of the class. The other is that the symbols themselves of :class:`.InternalTraversal` are used within the ``_traverse_internals`` collection. Such as, the :class:`.Case` object defines ``_traverse_internals`` as :: _traverse_internals = [ ("value", InternalTraversal.dp_clauseelement), ("whens", InternalTraversal.dp_clauseelement_tuples), ("else_", InternalTraversal.dp_clauseelement), ] Above, the :class:`.Case` class indicates its internal state as the attributes named ``value``, ``whens``, and ``else_``. They each link to an :class:`.InternalTraversal` method which indicates the type of datastructure referred towards. Using the ``_traverse_internals`` structure, objects of type :class:`.InternalTraversible` will have the following methods automatically implemented: * :meth:`.HasTraverseInternals.get_children` * :meth:`.HasTraverseInternals._copy_internals` * :meth:`.HasCacheKey._gen_cache_key` Subclasses can also implement these methods directly, particularly for the :meth:`.HasTraverseInternals._copy_internals` method, when special steps are needed. .. versionadded:: 1.4
Class Variable | dp |
Visit the _annotations_cache_key element. |
Class Variable | dp |
Visit a potentially "anonymized" string value. |
Class Variable | dp |
Visit a boolean value. |
Class Variable | dp |
Visit a :class:`_expression.ClauseElement` object. |
Class Variable | dp |
Visit a list of :class:`_expression.ClauseElement` objects. |
Class Variable | dp |
Visit a tuple of :class:`_expression.ClauseElement` objects. |
Class Variable | dp |
Visit a list of tuples which contain :class:`_expression.ClauseElement` objects. |
Class Variable | dp |
Visit a dialect options structure. |
Class Variable | dp |
Visit the values() multi-valued list of dictionaries of an :class:`_expression.Insert` object. |
Class Variable | dp |
Visit the values() ordered tuple list of an :class:`_expression.Update` object. |
Class Variable | dp |
Visit the values() dictionary of a :class:`.ValuesBase` (e.g. Insert or Update) object. |
Class Variable | dp |
Undocumented |
Class Variable | dp |
Visit a :class:`_expression.FromClause` object in the context of the ``columns`` attribute. |
Class Variable | dp |
Visit an ordered set of :class:`_expression.FromClause` objects. |
Class Variable | dp |
Visit a :class:`.HasCacheKey` object. |
Class Variable | dp |
Visit a list of :class:`.HasCacheKey` objects. |
Class Variable | dp |
Visit a list of tuples which contain :class:`.HasCacheKey` objects. |
Class Variable | dp |
Specify an object that should be ignored entirely. |
Class Variable | dp |
Visit an inspectable object where the return value is a :class:`.HasCacheKey` object. |
Class Variable | dp |
Visit a list of inspectable objects which upon inspection are HasCacheKey objects. |
Class Variable | dp |
Undocumented |
Class Variable | dp |
Visit an object that may be a :class:`.HasCacheKey` or may be a plain hashable object. |
Class Variable | dp |
Visit a tuple containing elements that may be :class:`.HasCacheKey` or may be a plain hashable object. |
Class Variable | dp |
Visit a simple named DDL element. |
Class Variable | dp |
Visit an operator. |
Class Variable | dp |
Visit a dictionary with string keys. |
Class Variable | dp |
Visit a plain python object. |
Class Variable | dp |
Visit the sequence represented by :class:`_expression.HasPrefixes` or :class:`_expression.HasSuffixes`. |
Class Variable | dp |
Visit the propagate attrs dict. This hardcodes to the particular elements we care about right now. |
Class Variable | dp |
Undocumented |
Class Variable | dp |
Visit the ``_statement_hints`` collection of a :class:`_expression.Select` object. |
Class Variable | dp |
Visit a plain string value. |
Class Variable | dp |
Visit a dictionary of string keys to :class:`_expression.ClauseElement` objects. |
Class Variable | dp |
Visit a list of strings. |
Class Variable | dp |
Visit a dictionary of string keys to values which may either be plain immutable/hashable or :class:`.HasCacheKey` objects. |
Class Variable | dp |
Visit the ``_hints`` collection of a :class:`_expression.Select` object. |
Class Variable | dp |
Visit a :class:`.TypeEngine` object |
Class Variable | dp |
Visit an unknown structure. |
Class Variable | dp |
Undocumented |
Visit the _annotations_cache_key element. This is a dictionary of additional information about a ClauseElement that modifies its role. It should be included when comparing or caching objects, however generating this key is relatively expensive. Visitors should check the "_annotations" dict for non-None first before creating this key.
Visit a potentially "anonymized" string value. The string value is considered to be significant for cache key generation.
Visit a :class:`_expression.FromClause` object in the context of the ``columns`` attribute. The column collection is "canonical", meaning it is the originally defined location of the :class:`.ColumnClause` objects. Right now this means that the object being visited is a :class:`_expression.TableClause` or :class:`_schema.Table` object only.
Specify an object that should be ignored entirely. This currently applies function call argument caching where some arguments should not be considered to be part of a cache key.
Visit a tuple containing elements that may be :class:`.HasCacheKey` or may be a plain hashable object.
Visit a simple named DDL element. The current object used by this method is the :class:`.Sequence`. The object is only considered to be important for cache key generation as far as its name, but not any other aspects of it.
Visit an operator. The operator is a function from the :mod:`sqlalchemy.sql.operators` module. The operator value is considered to be significant for cache key generation.
Visit a dictionary with string keys. The keys of the dictionary should be strings, the values should be immutable and hashable. The dictionary is considered to be significant for cache key generation.
Visit a plain python object. The value should be immutable and hashable, such as an integer. The value is considered to be significant for cache key generation.
Visit the sequence represented by :class:`_expression.HasPrefixes` or :class:`_expression.HasSuffixes`.
Visit a plain string value. Examples include table and column names, bound parameter keys, special keywords such as "UNION", "UNION ALL". The string value is considered to be significant for cache key generation.
Visit a dictionary of string keys to values which may either be plain immutable/hashable or :class:`.HasCacheKey` objects.