public function bind($src, $replaceNulls = false)
    {
        // If the source value is not an array or object return false.
        if (!is_object($src) && !is_array($src)) {
            throw new \InvalidArgumentException(sprintf('%s::bind(*%s*)', get_class($this), gettype($src)));
        }

        if ($src instanceof \Traversable) {
            $src = iterator_to_array($src);
        }

        // If the source value is an object, get its accessible properties.
        if (is_object($src)) {
            $src = get_object_vars($src);
        }

        $fields = $this->getFields();

        // Event
        $this->triggerEvent(
            'onBefore' . ucfirst(__FUNCTION__),
            [
                'src' => &$src,
                'fields' => $fields,
                'replaceNulls' => &$replaceNulls,
            ]
        );

        // Bind the source value, excluding the ignored fields.
        foreach ($src as $k => $v) {
            if ($v === null && !$replaceNulls) {
                continue;
            }

            $this->$k = $v;
        }

        // Event
        $this->triggerEvent('onAfter' . ucfirst(__FUNCTION__));

        return $this;
    }