Get a list of the mapping user fields in an associative array.

@return array
517699
protected function get_userinfo_mapping() {
        $fields = user_field_mapping::get_records(['issuerid' => $this->issuer->get('id')]);

        $map = [];
        foreach ($fields as $field) {
            $map[$field->get('externalfield')] = $field->get('internalfield');
        }
        return $map;
    }
717372
private function _getKeyIdMap(): array
    {
        // lazily build mapping
        if (!isset($this->_keyIdMap)) {
            $this->_keyIdMap = array();
            foreach ($this->_certs as $cert) {
                $id = self::_getCertKeyId($cert);
                if (!isset($this->_keyIdMap[$id])) {
                    $this->_keyIdMap[$id] = array();
                }
                array_push($this->_keyIdMap[$id], $cert);
            }
        }
        return $this->_keyIdMap;
    }
948033
private function getAssociations() : array
    {
        $result = [];
        foreach ($this->getQueryFields() as $field) {
            $association = $this->getAssociationByField($field);
            if (null === $association) {
                continue;
            }

            if (array_key_exists($association->getName(), $result)) {
                continue;
            }

            $result[$association->getName()] = $association;
        }

        return $result;
    }
710162
public function asArray()
    {
        $fields = [
            '@type' => $this->type(),
            '@key'  => $this->key(),
        ];

        foreach ($this->fields as $name => $field) {
            $fields[$name] = $field->value;
        }

        return $fields;
    }
868410
public function getGroups()
    {
        if (!is_array($this->fields['groups'])) {
            $this->fields['groups'] = [GROUP_ALL];
            if ($this->id == ADMIN_ID) $this->fields['groups'][] = GROUP_ADMIN;
            $r = self::getDbConnection()->fetchAll('SELECT group_id FROM users_groups_membership WHERE user_id='.$this->id);
            foreach ($r as $f) $this->fields['groups'][] = $f['group_id'];
        }
        return $this->fields['groups'];
    }
1088770
public function toArray()
    {
        $result = [];
        $result['id']            = $this->id;
        $result['toUserName']    = $this->toUserName;
        $result['fromUserName']  = $this->fromUserName;
        $result['createTime']    = $this->createTime;
        $result['msgType']       = $this->msgType;
        return $result;
    }
1343933
public function getFields()
    {
        $fields = $this->getInput('fields');

        if (! is_array($fields)) {
            return [];
        }

        return array_map(function ($fields) {
            return explode(',', $fields);
        }, $fields);
    }
538481
public function getMappedAttributes()
    {
        $mappedArrayForApiRequest = [];
        $requestAttributes = $this->request->getData();
        foreach ($requestAttributes as $key => $value) {
            if (array_key_exists($key, $this->mappingRequestToOtherRequestAttributes)) {
                $mappedArrayForApiRequest[$this->mappingRequestToOtherRequestAttributes[$key]] = $value;
            }
        }

        return $mappedArrayForApiRequest;
    }
1246043
public function toMappedArray()
    {
        $values = $this->toArray();
        $mappedValues = [];
        foreach ($values as $key => $value) {
            $mappedValues[$key] = $this->readMapped($key);
        }

        return $mappedValues;
    }
483410
public function toArray()
    {
        $userParameters = [];

        foreach ($this->tsProperty as $property => $tsPropObj) {
            $userParameters[$property] = $tsPropObj->getValue();
        }

        return $userParameters;
    }
1005375
public function getFields()
	{
		$list	= array();
		foreach( $this->fields as $name => $fields )
				if( count( $fields ) )
					foreach( $fields as $field )
						$list[]	= $field;
		return $list;
	}
22733
public function getFieldDatabaseNameArray()
    {
        $fields = [];
        foreach ($this->fields as $field) {
            $fields[] = $field->toSelectString();
        }
        return $fields;
    }
718342
public function getUserMapper()
    {
        if (null === $this->userMapper) {
            $this->userMapper = $this->getServiceManager()->get('zfcuser_user_mapper');
        }
        return $this->userMapper;
    }
372384
public function getAssociationReferenceNames()
    {
        $referenceNames = array();
        foreach ($this->associationMappings as $assoc) {
            $referenceNames[] = $assoc->getReferenceField($this->getManagerIdentifier()) ?: $assoc->getField();
        }

        return $referenceNames;
    }
366490
protected function getFieldsAsArrays()
    {
        $fields = [];

        foreach ($this->getFields() as $field) {
            $fields[] = $field->toArray();
        }

        return $fields;
    }
867051
public static function getUsers()
	{
		if ( ! is_array( self::$auth ) ) throw new Exception( 'Authentication not initialized' );

		if ( isset( self::$auth['users'] ) ) {
			return self::$auth['users'];
		} else {
			return array();
		}
	}
436486
public function getUserMapper()
    {
        if (!$this->userMapper) {
            $this->userMapper = $this->getServiceLocator()->get('zfcuser_user_mapper');
        }

        return $this->userMapper;
    }