Add a boolean field to the schema

@param $str_name
@param bool $bol_index
@return Schema
320286
public function addBoolean($str_name, $bol_index = TRUE)
    {
        return $this->addProperty($str_name, self::PROPERTY_BOOLEAN, $bol_index);
    }
1007061
public function addAutoField($str_name, $mix_value)
    {
        switch(gettype($mix_value)) {
            case 'integer':
            case 'double':
                $this->addNumber($str_name);
                break;

            case 'object':
                if($mix_value instanceof \DateTime) {
                    $this->addDate($str_name);
                } elseif (method_exists($mix_value, '__toString')) {
                    $this->addText($str_name);
                } else {
                    // @todo consider exception
                }
                break;

            case 'array': // @todo consider exception
            case 'string':
            case 'boolean': // @todo consider exception / numeric
            case 'resource': // @todo consider exception
            case 'null':
            case 'unknown type': // @todo consider exception
            default:
                $this->addText($str_name);
        }
        return $this;
    }
984739
public RowBuilder bool(String name)
  {
    ColumnBool column = new ColumnBool(_columns.size(), name, _offset);
    
    _offset += column.length();
    _columns.add(column);
    
    return this;
  }
1282346
public function addInteger($str_name, $bol_index = TRUE)
    {
        return $this->addProperty($str_name, self::PROPERTY_INTEGER, $bol_index);
    }
165133
public function mapBasicField(array &$values, $field_name) {
    $item = $this->item;
    if (!empty($item[$field_name])) {
      $values[$field_name] = $item[$field_name];
    }
  }
1266896
public function setCondition($field_name, $value, $operation = '=')
    {
        $this->condition[$field_name] = [
            'value' => $value,
            'operation' => $operation
        ];

        return $this;
    }
625020
public function fetchByName($str_name)
    {
        return $this->obj_gateway
            ->withSchema($this->obj_schema)
            ->withTransaction($this->str_transaction_id)
            ->fetchByName($str_name);
    }
22894
def _convert_simple_value_boolean_query_to_and_boolean_queries(tree, keyword):
    """"""

    def _create_operator_node(value_node):
        """Creates a KeywordOp or a ValueOp node."""
        base_node = value_node.op if isinstance(value_node, NotOp) else value_node
        updated_base_node = KeywordOp(keyword, base_node) if keyword else ValueOp(base_node)

        return NotOp(updated_base_node) if isinstance(value_node, NotOp) else updated_base_node

    def _get_bool_op_type(bool_op):
        return AndOp if isinstance(bool_op, And) else OrOp

    new_tree_root = _get_bool_op_type(tree.bool_op)(None, None)
    current_tree = new_tree_root
    previous_tree = tree

    while True:  # Walk down the tree while building the new AndOp queries subtree.
        current_tree.left = _create_operator_node(previous_tree.left)

        if not isinstance(previous_tree.right, SimpleValueBooleanQuery):
            current_tree.right = _create_operator_node(previous_tree.right)
            break

        previous_tree = previous_tree.right
        current_tree.right = _get_bool_op_type(previous_tree.bool_op)(None, None)
        current_tree = current_tree.right

    return new_tree_root
810009
function addFieldBaseToDoc( ezfSolrDocumentFieldBase $fieldBase, eZSolrDoc $doc, $boost = false )
    {
        $fieldBaseData = $fieldBase->getData();
        if ( empty( $fieldBaseData ) )
        {
            if ( is_object( $fieldBase ) )
            {
                $contentClassAttribute = $fieldBase->ContentObjectAttribute->attribute( 'contentclass_attribute' );
                $fieldName = $fieldBase->getFieldName( $contentClassAttribute );
                $errorMessage = 'empty array for ' . $fieldName;
            }
            else
            {
                $errorMessage = '$fieldBase not an object';
            }
            eZDebug::writeNotice( $errorMessage , __METHOD__ );
            return false;
        }
        else
        {
           foreach ( $fieldBaseData as $key => $value )
           {
               // since ezfind 2.3, a NULL value returned from $fieldBase in the $value elements is used as a flag not to index
               if ( !is_null( $value ) )
               {
                   $doc->addField( $key, $value, $boost );
               }
           }
           return true;
        }

    }
647482
public boolean getBoolean(int columnIndex) {
		Object fieldValue = data[columnIndex];
		if (fieldValue == null) {
			return Boolean.FALSE;
		}
		if (fieldValue instanceof Boolean) {
			return (Boolean) fieldValue;
		}
		throw new DBFException("Unsupported type for Boolean at column:" + columnIndex + " "
				+ fieldValue.getClass().getCanonicalName());
	}
660384
public function isFieldValid(string $field_name) : bool
    {
        if (false === $this->validated) {
            $this->validate();
        }
        return (false === $this->getErrorByFieldName($field_name));
    }
389967
def boolean(attr, metadata={})
      add_attribute(attr, :boolean, metadata)
      define_method("#{attr}=") do |arg|
        v = case arg
        when String then BOOLEAN_TRUE_STRINGS.include?(arg.downcase)
        when Numeric then arg == 1
        when nil then nil
        else !!arg
        end
        instance_variable_set("@#{attr}", v)
      end
      alias_method "#{attr}?", attr
    end
1308830
void addField(final String name, final boolean value)
            throws IllegalStateException {

        addField(name, Boolean.toString(value));

    }
1027314
public Boolean getBoolean(int index, boolean strict) throws JsonException {
        JsonElement el = get(index);
        Boolean res = null;
        if (strict && !el.isBoolean()) {
            throw Util.typeMismatch(index, el, "boolean", true);
        }
        if (el.isBoolean()) {
            res = el.asBoolean();
        }
        if (el.isString()) {
            res = Util.toBoolean(el.asString());
        }
        if (res == null)
            throw Util.typeMismatch(index, el, "boolean", strict);
        return res;
    }
558490
def _set_bool_prop(self, name, value):
        
        rPr = self._element.get_or_add_rPr()
        rPr._set_bool_val(name, value)
1324697
@NotNull
    public static Key<Boolean> booleanKey(@NotNull String name) {
        return create(name, Boolean.class);
    }
318838
def get_bool(_bytearray, byte_index, bool_index):
    
    index_value = 1 << bool_index
    byte_value = _bytearray[byte_index]
    current_value = byte_value & index_value
    return current_value == index_value