def _trans_binary(self, value):
        try:
            conv = int(value)
        except ValueError:
            return 0

        if conv not in [0, 1]:
            return 0

        return conv
Reboots, shuts down or powers up the host.
dataset/ETHPy150Open Yelp/fullerite/src/diamond/collectors/icinga_stats/icinga_stats.py/IcingaStatsCollector._trans_binary--crossover with--dataset/ETHPy150Open BU-NU-CLOUD-SP16/Trusted-Platform-Module-nova/nova/virt/hyperv/hostops.py/HostOps.host_power_action