public function sortByValue($sort = SORT_NUMERIC)
    {
        return $this
            ->groupBy(function (Card $card) {
                return $card->value();
            })
            ->map(function (CardCollection $valueGroup) {
                return $valueGroup->sortBySuitValue();
            })
            ->flatten()
            ->sortBy(function (Card $card) {
                return $card->value();
            }, $sort)
            ->values();
    }