Factory/FeaturedFactory.php
public function createFeaturedStreams(array $featureds)
    {
        $tmp = [];
        foreach ($featureds as $entry) {
            $featured = FeaturedStream::create();

            if (isset($entry['stream'])) {
                $featured->setStream((new StreamFactory())->createEntity($entry['stream']));
            }

            if (isset($entry['image'])) {
                $featured->setImage($entry['image']);
            }

            if (isset($entry['text'])) {
                $featured->setText($entry['text']);
            }

            if (isset($entry['title'])) {
                $featured->setTitle($entry['title']);
            }

            if (isset($entry['sponsored'])) {
                $featured->setSponsored($entry['sponsored']);
            }

            if (isset($entry['scheduled'])) {
                $featured->setScheduled($entry['scheduled']);
            }

            $tmp[] = $featured;
        }

        return $tmp;
    }
public function createFeaturedStreams(array $featureds)
    {
        $tmp = [];
        foreach ($featureds as $entry) {
            $featured = FeaturedStream::create();

            if (isset($entry['stream'])) {
                $featured->setStream((new StreamFactory())->createEntity($entry['stream']));
            }

            if (isset($entry['image'])) {
                $featured->setImage($entry['image']);
            }

            if (isset($entry['text'])) {
                $featured->setText($entry['text']);
            }

            if (isset($entry['title'])) {
                $featured->setTitle($entry['title']);
            }

            if (isset($entry['sponsored'])) {
                $featured->setSponsored($entry['sponsored']);
            }

            if (isset($entry['scheduled'])) {
                $featured->setScheduled($entry['scheduled']);
            }

            $tmp[] = $featured;
        }

        return $tmp;
    }
@param array $featureds

@return array