def __init__(self, alias):
    'Return a :class:`.MapperOption` that will indicate to the :class:`.Query`\n        that the main table has been aliased.\n\n        This is a seldom-used option to suit the\n        very rare case that :func:`.contains_eager`\n        is being used in conjunction with a user-defined SELECT\n        statement that aliases the parent table.  E.g.::\n\n            # define an aliased UNION called \'ulist\'\n            ulist = users.select(users.c.user_id==7).\\\n                            union(users.select(users.c.user_id>7)).\\\n                            alias(\'ulist\')\n\n            # add on an eager load of "addresses"\n            statement = ulist.outerjoin(addresses).\\\n                            select().apply_labels()\n\n            # create query, indicating "ulist" will be an\n            # alias for the main table, "addresses"\n            # property should be eager loaded\n            query = session.query(User).options(\n                                    contains_alias(ulist),\n                                    contains_eager(User.addresses))\n\n            # then get results via the statement\n            results = query.from_statement(statement).all()\n\n        :param alias: is the string name of an alias, or a\n         :class:`~.sql.expression.Alias` object representing\n         the alias.\n\n        '
    self.alias = alias
Return a :class:`.MapperOption` that will indicate to the :class:`.Query`
that the main table has been aliased.

This is a seldom-used option to suit the
very rare case that :func:`.contains_eager`
is being used in conjunction with a user-defined SELECT
statement that aliases the parent table.  E.g.::

    # define an aliased UNION called 'ulist'
    ulist = users.select(users.c.user_id==7).\
                    union(users.select(users.c.user_id>7)).\
                    alias('ulist')

    # add on an eager load of "addresses"
    statement = ulist.outerjoin(addresses).\
                    select().apply_labels()

    # create query, indicating "ulist" will be an
    # alias for the main table, "addresses"
    # property should be eager loaded
    query = session.query(User).options(
                            contains_alias(ulist),
                            contains_eager(User.addresses))

    # then get results via the statement
    results = query.from_statement(statement).all()

:param alias: is the string name of an alias, or a
 :class:`~.sql.expression.Alias` object representing
 the alias.
def __init__(self, alias):
    'Return a :class:`.MapperOption` that will indicate to the :class:`.Query`\n        that the main table has been aliased.\n\n        This is a seldom-used option to suit the\n        very rare case that :func:`.contains_eager`\n        is being used in conjunction with a user-defined SELECT\n        statement that aliases the parent table.  E.g.::\n\n            # define an aliased UNION called \'ulist\'\n            ulist = users.select(users.c.user_id==7).\\\n                            union(users.select(users.c.user_id>7)).\\\n                            alias(\'ulist\')\n\n            # add on an eager load of "addresses"\n            statement = ulist.outerjoin(addresses).\\\n                            select().apply_labels()\n\n            # create query, indicating "ulist" will be an\n            # alias for the main table, "addresses"\n            # property should be eager loaded\n            query = session.query(User).options(\n                                    contains_alias(ulist),\n                                    contains_eager(User.addresses))\n\n            # then get results via the statement\n            results = query.from_statement(statement).all()\n\n        :param alias: is the string name of an alias, or a\n         :class:`~.sql.expression.Alias` object representing\n         the alias.\n\n        '
    self.alias = alias