return an array of String which contains deviceName and his state.

@return String[]
491270
public String[] getDeviceStateArray() {
	final String[] array = new String[deviceStateMap.size()];
	int i = 0;
	for (final Map.Entry<String, DevState> deviceStateEntry : deviceStateMap.entrySet()) {

	    final String deviceName = deviceStateEntry.getKey();
	    final DevState deviceState = deviceStateEntry.getValue();
	    array[i++] = deviceName + " - " + StateUtilities.getNameForState(deviceState);
	}
	return array;
    }
363029
protected function getRegexes()
    {
        if (empty($this->regexList)) {
            $cacheKey = 'DeviceDetector-'.DeviceDetector::VERSION.'regexes-'.$this->getName();
            $cacheKey = preg_replace('/([^a-z0-9_-]+)/i', '', $cacheKey);
            $this->regexList = $this->getCache()->fetch($cacheKey);
            if (empty($this->regexList)) {
                $this->regexList = $this->getYamlParser()->parseFile(
                    $this->getRegexesDirectory().DIRECTORY_SEPARATOR.$this->fixtureFile
                );
                $this->getCache()->save($cacheKey, $this->regexList);
            }
        }
        return $this->regexList;
    }
374782
public List<String> getDeviceIDs() {
        final List<String> ids = new ArrayList<>();
        for (final File deviceDir : getDeviceDirs()) {
            ids.add(deviceDir.getName());
        }
        /*
         * //for (final W1Device device: devices) { ids.add(device.getId());
         */
        return ids;
    }
191084
public function toArray()
    {
        return [
            'userAgent'          => $this->userAgent,
            'browser'            => $this->browser,
            'version'            => $this->version,
            'majorVersion'       => $this->majorVersion,
            'minorVersion'       => $this->minorVersion,
            'browserWithVersion' => $this->browserWithVersion,
            'publisher'          => $this->publisher,
            'platform'           => $this->platform,
            'device'             => $this->device,
            'devicePointer'      => $this->devicePointer,
            'isMobile'           => $this->isMobile,
            'isTablet'           => $this->isTablet(),
            'isCrawler'          => $this->isCrawler,
        ];
    }
802683
private function getScsi(): array
	{
		$get_type = false;
		$device = null;
		$scsi = [];
		$data = $this->readFile('/proc/scsi/scsi');

		if ($data !== null) {
			$bufe = preg_split("/\n/", $data, -1, PREG_SPLIT_NO_EMPTY);
			foreach ($bufe as $buf) {
				if (preg_match('/Vendor: (.*) Model: (.*) Rev: (.*)/i', $buf, $devices)) {
					$get_type = true;
					$device = $devices;
					continue;
				}
				if ($get_type) {
					preg_match('/Type:\s+(\S+)/i', $buf, $dev_type);
					$dev = new Obj;
					$dev->name = trim($device[1]) . ' ' . trim($device[2]);
					$dev->type = trim($dev_type[1]);
					$scsi[] = $dev;
					$get_type = false;
				}
			}
		}
		return $scsi;
	}
421764
public static function getDeviceSuffix(){
		if(empty(self::$devicesuffix)){
			$device=self::detectDevice();
			if($device==DEVICE_TYPE_MPHONE){
				self::$devicesuffix='.m';
				}
			elseif($device==DEVICE_TYPE_TABLET){
				self::$devicesuffix='.m';
				}else{
				self::$devicesuffix='.d';
				}
			}
		return self::$devicesuffix;
		}
1189598
public function getFunctions()
    {
        $functions = array(
            new \Twig_SimpleFunction('get_available_devices', array($this, 'getAvailableDevices')),
            new \Twig_SimpleFunction('is_mobile', array($this, 'isMobile')),
            new \Twig_SimpleFunction('is_tablet', array($this, 'isTablet'))
        );

        foreach ($this->getAvailableDevices() as $device => $fixedName) {
            $methodName = 'is'.$device;
            $twigFunctionName = 'is_'.$fixedName;
            $functions[] = new \Twig_SimpleFunction($twigFunctionName, array($this, $methodName));
        }

        return $functions;
    }
809118
public static function getUserOperatingSystemName()
    {
        $info = self::getUserWebBrowserInfo();

        $knownSystems = [
            'Linux' => 'Linux',
            'Win'   => 'Windows',
            'Mac'   => 'Mac OS',
        ];

        foreach ($knownSystems as $pattern => $systemName) {
            $matches = [];
            $matchCount = preg_match(sprintf('|%s|', $pattern), $info, $matches);

            if ($matchCount > 0) {
                return $systemName;
            }
        }

        return '';
    }
1338899
public function getDeviceCategory()
    {
        $dates = $this->getStartEndDate();

        $data = LaravelAnalytics::performQuery($dates['start'], $dates['end'], 'ga:sessions', [
            'dimensions' => 'ga:deviceCategory'
        ]);

        $items = [];
        foreach ($data->rows as $k => $item) {
            $items[] = $this->getPieDataSet(ucfirst($item[0]), $item[1]);
        }

        return $items;
    }
1310823
public function mapDeviceName(?string $deviceName): ?string
    {
        if (null === $deviceName) {
            return null;
        }

        $marketingName = null;

        switch (mb_strtolower($deviceName)) {
            case '':
            case 'unknown':
            case 'other':
            case 'various':
            case 'android 1.6':
            case 'android 2.0':
            case 'android 2.1':
            case 'android 2.2':
            case 'android 2.3':
            case 'android 3.0':
            case 'android 3.1':
            case 'android 3.2':
            case 'android 4.0':
            case 'android 4.1':
            case 'android 4.2':
            case 'android 4.3':
            case 'android 4.4':
            case 'android 5.0':
            case 'android 2.2 tablet':
            case 'android 4 tablet':
            case 'android 4.1 tablet':
            case 'android 4.2 tablet':
            case 'android 4.3 tablet':
            case 'android 4.4 tablet':
            case 'android 5.0 tablet':
            case 'disguised as macintosh':
            case 'mini 1':
            case 'mini 4':
            case 'mini 5':
            case 'windows mobile 6.5':
            case 'windows mobile 7':
            case 'windows mobile 7.5':
            case 'windows phone 7':
            case 'windows phone 8':
            case 'fennec tablet':
            case 'tablet on android':
            case 'fennec':
            case 'opera for series 60':
            case 'opera mini for s60':
            case 'windows mobile (opera)':
            case 'mobi for android':
            case 'nokia unrecognized ovi browser':
            case 'mozilla firefox for android':
            case 'firefox for android tablet':
            case 'firefox for android':
                $marketingName = null;
                break;
            // Acer
            case 'acer e320':
                $marketingName = 'Liquid Express';
                break;
            // HP
            case 'touchpad':
                $marketingName = 'Touchpad';
                break;
            // Medion
            case 'p9514':
            case 'lifetab p9514':
                $marketingName = 'LifeTab P9514';
                break;
            case 'lifetab s9512':
                $marketingName = 'LifeTab S9512';
                break;
            // HTC
            case 'htc desire sv':
                $marketingName = 'Desire SV';
                break;
            // Apple
            case 'ipad':
                $marketingName = 'iPad';
                break;
            case 'iphone':
                $marketingName = 'iPhone';
                break;
            case 'e610':
                $marketingName = 'Optimus L5';
                break;
            default:
                // nothing to do here
                break;
        }

        return $marketingName;
    }
1187240
def get_state(self) -> str:
        ''''''
        output, error = self._execute('get-state')
        if error:
            raise DeviceConnectionException(error.split(':', 1)[-1].strip())
        return output.strip()
760234
public function getStates()
    {
        $appID = App::getCurrentID();
        $complementID = self::getCurrentID();
        $states = $this->getStatesFromFile();

        if (isset($states[$appID][$complementID])) {
            return $this->states = $states[$appID][$complementID];
        }

        return $this->states = [];
    }
579259
public static function getStates()
    {
        return array(
            self::STATE_SENT,
            self::STATE_ACCEPTED,
            self::STATE_REJECTED,
            self::STATE_DELIVERED,
            self::STATE_FAILED,
        );
    }
140693
public function getStates()
    {
        $states = [];

        if (self::STATE_OFFLINE === $this->_state) {
            $states[] = self::STATE_OFFLINE;
        } elseif (self::STATE_HIDDEN === $this->_state) {
            $states[] = self::STATE_OFFLINE;
            $states[] = self::STATE_HIDDEN;
        } else {
            foreach (self::$STATES as $value) {
                if (0 !== ($this->_state & $value)) {
                    $states[] = $value;
                }
            }
        }

        return $states;
    }
65355
def get_state_all(self):
        """"""
        state_dict = {}
        for device in self.get_device_names().keys():
            state_dict[device] = self.get_state(device)
        return state_dict
946209
public function getDeviceCategory()
    {
        $period = $this->analyticsDuration();

        $data = Analytics::performQuery($period, 'ga:sessions', [
            'dimensions' => 'ga:deviceCategory'
        ]);

        $items = [];
        foreach ($data->rows as $k => $item) {
            $items[] = $this->getPieDataSet(ucfirst($item[0]), $item[1]);
        }

        return $items;
    }
113443
public function getDeviceType()
    {
        if ($this->deviceType === null) {
            $this->setDeviceType($this->detectDeviceType());
        }

        return $this->deviceType;
    }