returns true or false
18684
function _connect($argHostname, $argUsername, $argPassword, $argDatabasename)
	{
		if (!function_exists('sqlite_open')) {
			return null;
		}
		if (empty($argHostname) && $argDatabasename) {
			$argHostname = $argDatabasename;
		}

		$this->_connectionID = sqlite_open($argHostname);
		if ($this->_connectionID === false) {
			return false;
		}
		$this->_createFunctions();
		return true;
	}
192858
def __assert_false(returned):
        '''
        
        '''
        result = "Pass"
        if isinstance(returned, str):
            try:
                returned = bool(returned)
            except ValueError:
                raise
        try:
            assert (returned is False), "{0} not False".format(returned)
        except AssertionError as err:
            result = "Fail: " + six.text_type(err)
        return result
874146
def truthy(value):
    
    if value is None or value == '':
        return False
    value = str(value)
    try:
        return (int(value) != 0)
    except:
        pass
    return (truthy_true_yes.match(value) is not None)
312553
def _parse_boolean(value, default=False):
    
    if value is None:
        return default
    try:
        return bool(value)
    except ValueError:
        return default
53280
protected function validate()
    {
        $returnValue = (bool) false;

        
		
		$this->valid = true;
		
		foreach($this->elements as $element){
			if(!$element->validate()){
				$this->valid = false;
			}
		}
		
        

        return (bool) $returnValue;
    }
359090
def visit_Boolean(self, node):
        """"""
        if node.value == 'true':
            return Bool(True)
        elif node.value == 'false':
            return Bool(False)
1120849
public function isCorrect()
    {
        if ($this->hasCorrectResponse() === true) {
            $correctResponse = $this->getCorrectResponse();

            if ($correctResponse instanceof Comparable) {
                return $correctResponse->equals($this->getValue());
            } else {
                return $correctResponse === $this->getValue();
            }
        }

        return false;
    }
613172
def bool(self):
        
        v = self.squeeze()
        if isinstance(v, (bool, np.bool_)):
            return bool(v)
        elif is_scalar(v):
            raise ValueError("bool cannot act on a non-boolean single element "
                             "{0}".format(self.__class__.__name__))

        self.__nonzero__()
1144007
def _and(ctx, *logical):
    
    for arg in logical:
        if not conversions.to_boolean(arg, ctx):
            return False
    return True
1302338
function result()
    {
        if ($this->result == null || count($this->result) == 0) {
            return false;
        }
        return $this->result;
    }
1203989
def get_bool(self, key, default=None):
        
        """
        return self.get_converted(
            key, ConversionTypeEnum.BOOL, default=default)
1207078
def bool_input(message):
    '''
    
    '''

    while True:
        suffix = ' (true or false): '
        inp = input(message + suffix)
        if inp.lower() == 'true':
            return True
        elif inp.lower() == 'false':
            return False
        else:
            print(colored('Must be either true or false, try again!', 'red'))
1180123
def boolean(text):
    

    tmp = text.lower()
    if tmp.isdigit():
        return bool(int(tmp))
    elif tmp in ('t', 'true', 'on', 'yes'):
        return True
    elif tmp in ('f', 'false', 'off', 'no'):
        return False

    raise ValueError("invalid Boolean value %r" % text)
136917
function isBoolean(value) {
    return value === true || value === false ||
      value && typeof value == 'object' && toString.call(value) == boolClass || false;
  }
909712
public function isBoolean()
    {
        $columnType = $this->getColumnType();

        if (
            DatatypeConverterInterface::USERDATATYPE_BOOL == $columnType ||
            DatatypeConverterInterface::USERDATATYPE_BOOLEAN == $columnType ||
            (
                DatatypeConverterInterface::DATATYPE_TINYINT == $columnType &&
                preg_match('/^(is|has|can)_/', $this->getColumnName())
            )
        ) {
            return true;
        }

        return false;
    }
439586
def get_bool_value(self, section, option, default=True):
        """"""
        try:
            return self.parser.getboolean(section, option)
        except NoOptionError:
            return bool(default)
360031
def _get_boolean(self, source, bitarray):
        '''  '''
        raw_value = self._get_raw(source, bitarray)
        return {
            source['shortcut']: {
                'description': source.get('description'),
                'unit': source.get('unit', ''),
                'value': True if raw_value else False,
                'raw_value': raw_value,
            }
        }