Commit b1c5766d authored by Yuxin Wu's avatar Yuxin Wu

set_chief_only in callbacks.

parent c3a47386
......@@ -201,6 +201,13 @@ class Callback(object):
def chief_only(self, v):
self._chief_only = v
def set_chief_only(self, v=True):
"""
Set chief_only property, and returns the callback itself.
"""
self._chief_only = v
return self
def __str__(self):
return type(self).__name__
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment