Sets the count to the given value if the current count is zero. If count is not zero, this method does nothing
        and returns ``false``.

        :param count: (int), the number of times count_down() must be invoked before threads can pass through await().
        :return: (bool), ``true`` if the new count was set, ``false`` if the current count is not zero.

def try_set_count(self, count):
        """
        Sets the count to the given value if the current count is zero. If count is not zero, this method does nothing
        and returns ``false``.

        :param count: (int), the number of times count_down() must be invoked before threads can pass through await().
        :return: (bool), ``true`` if the new count was set, ``false`` if the current count is not zero.
        """
        check_not_negative(count, "count can't be negative")
        return self._encode_invoke(count_down_latch_try_set_count_codec, count=count)