public static function hydrate(stdClass $setting)
    {
        $hydrated = new SettingEntity();

        if (isset($setting->key)) {
            $hydrated->setKey($setting->key);
        }

        if (isset($setting->value)) {
            $hydrated->setValue($setting->value);
        }

        if (isset($setting->created_at)) {
            $hydrated->setCreatedAt(new DateTime($setting->created_at));
        }

        return $hydrated;
    }
public static function hydrate(stdClass $setting)
    {
        $hydrated = new SettingEntity();

        if (isset($setting->key)) {
            $hydrated->setKey($setting->key);
        }

        if (isset($setting->value)) {
            $hydrated->setValue($setting->value);
        }

        if (isset($setting->created_at)) {
            $hydrated->setCreatedAt(new DateTime($setting->created_at));
        }

        return $hydrated;
    }
public static function hydrate ( stdClass $ setting ) { $ hydrated = new SettingEntity ( ) ; if ( isset ( $ setting -> key ) ) { $ hydrated -> setKey ( $ setting -> key ) ; } if ( isset ( $ setting -> value ) ) { $ hydrated -> setValue ( $ setting -> value ) ; } if ( isset ( $ setting -> created_at ) ) { $ hydrated -> setCreatedAt ( new DateTime ( $ setting -> created_at ) ) ; } return $ hydrated ; }
Hydrate a setting object into a SettingEntity

@param \stdClass $setting
@return SettingEntity
Hydrate a setting object into a SettingEntity