<?php

namespace FiloBlu\Storelocator\Model\Config\Source;

use Magento\Framework\Data\OptionSourceInterface;

/**
 *
 */
class Autocompletetype implements OptionSourceInterface
{
    /**
     * Options getter
     *
     * @return array
     */
    public function toOptionArray()
    {
        return [
            [
                'value' => '',
                'label' => 'all'
            ],
            [
                'value' => 'address',
                'label' => 'address'
            ],
            [
                'value' => 'establishment',
                'label' => 'establishment'
            ],
            [
                'value' => 'geocode',
                'label' => 'geocode'
            ],
        ];
    }

    /**
     * Get options in "key-value" format
     *
     * @return array
     */
    public function toArray()
    {
        return [
            'all'           => '',
            'address'       => 'address',
            'establishment' => 'establishment',
            'terrain'       => 'geocode',
        ];
    }
}
