本文整理汇总了Python中couchbase._libcouchbase.Connection.unlock_multi方法的典型用法代码示例。如果您正苦于以下问题:Python Connection.unlock_multi方法的具体用法?Python Connection.unlock_multi怎么用?Python Connection.unlock_multi使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类couchbase._libcouchbase.Connection
的用法示例。
在下文中一共展示了Connection.unlock_multi方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: unlock_multi
# 需要导入模块: from couchbase._libcouchbase import Connection [as 别名]
# 或者: from couchbase._libcouchbase.Connection import unlock_multi [as 别名]
def unlock_multi(self, keys):
"""Unlock multiple keys
Multi variant of :meth:`unlock`
:param dict keys: the keys to unlock
:return: a :class:`MultiResult` object
The value of the ``keys`` argument should be either the CAS, or a
previously returned :class:`Result` object from a :meth:`lock` call.
Effectively, this means you may pass a :class:`MultiResult` as the
``keys`` argument.
Thus, you can do something like ::
keys = (....)
rvs = cb.lock_multi(keys, ttl=5)
# do something with rvs
cb.unlock_multi(rvs)
.. seealso::
:meth:`unlock`
"""
return _Base.unlock_multi(self, keys)