@see https://docs.easypay.pt/?workflow=notification

@param  integer $key
@return string
515805
public function getXmlResponse($key)
    {
        $xml =<<<EOF
<!--?xml version="1.0" encoding="ISO-8859-1"?-->
<getautomb_key>
    <ep_status>ok0</ep_status>
    <ep_message>generated document</ep_message>
    <ep_cin>%s</ep_cin>
    <ep_user>%s</ep_user>
    <ep_doc>%s</ep_doc>
    <ep_key>%s</ep_key>
</getautomb_key>
EOF;

        return trim(sprintf($xml, $this->cin, $this->user, $this->doc, $key));
    }
772022
public static function getTranslation($key)
  {
    $_key = strtoupper($key);
    if ( isset(self::$translations[$_key]) ){
      return self::$translations[$_key];
    }
    
    return $key;
  }
829611
public function isLazy($key= '') {
        $lazy = false;
        if (empty($key)) {
            $lazy = (count($this->_lazy) > 0);
        } else {
            $key = $this->getField($key, true);
            if ($key !== false) {
                $lazy = in_array($key, $this->_lazy);
            }
        }
        return $lazy;
    }
315887
public function getMessageData($key)
    {
        if ($this->{$key}) {
            return $this->{$key};
        }

        $data_key = str_replace(['text_body', 'html_body'], ['txt_path', 'html_path'], $key);

        $data = $this->retrieveMessageData($data_key);

        if (!$data) {
            return '';
        }

        $this->{$key} = $data;

        return $data;
    }
558643
public function get(string $key)
    {
        if (array_key_exists($key, $this->get)) {
            return $this->get[$key];
        }

        return '';
    }
826049
private function getCode(string $key): string
    {
        $ret = '';

        $this->checkResource($key);

        /** @var string[] $resources */
        $resources = $this->asseticNodes[$key];
        foreach ($resources as $resource) {
            $ret .= $this->resourceToString($resource);
        }

        return $ret;
    }
41403
public function sFlush($key) {
        $this->_redis->multi();
        $this->_redis->sMembers($key);
        $this->_redis->del($key);
        return $this->_redis->exec()[0];
    }
782551
public function file_error_message( $key ) {
		if ( $this->file_info( $key ) ) {
			return '';
		} elseif ( ! isset( $_FILES[ $key ] ) ) {
			return $this->__( 'File is not specified.' );
		} else {
			switch ( $_FILES[ $key ]['error'] ) {
				case UPLOAD_ERR_FORM_SIZE:
				case UPLOAD_ERR_INI_SIZE:
					return $this->__( 'Uploaded file size exceeds allowed limit.' );
					break;
				default:
					return $this->__( 'Failed to upload' );
					break;
			}
		}
	}
454925
public function get($key) {
        $file = $this->key2file($key);
        if (is_file($file)) {
            /** @noinspection PhpIncludeInspection */
            $r = require $file;
            if (!empty($r) && $key === $r['key'] && (0 === $r['expiration'] || time() <= $r['expiration'])) {
                X::logger()->trace("CCache hit $key");
                return $r['data'];
            }
        }
        X::logger()->trace("CCache miss $key");
        return false;
    }
1263103
protected function getPreparedKey($key)
    {
        $preparedKey = strtolower(preg_replace('/([a-z])([A-Z])/', '$1_$2', $key));
        $template = "add_paydata[KEY]";
        return str_replace('KEY', $preparedKey, $template);
    }
389759
public function getIntroMessageParts($key)
    {
        $parts = array(
            'PublishDateIntro' => array(
                'INTRO'=>_t(
                    'WorkflowEmbargoExpiryExtension.REQUESTED_PUBLISH_DATE_INTRO',
                    'Enter a date and/or time to specify embargo and expiry dates.'
                ),
                'BULLET_1'=>_t(
                    'WorkflowEmbargoExpiryExtension.REQUESTED_PUBLISH_DATE_INTRO_BULLET_1',
                    'These settings won\'t take effect until any approval actions are run'
                ),
                'BULLET_2'=>_t(
                    'WorkflowEmbargoExpiryExtension.REQUESTED_PUBLISH_DATE_INTRO_BULLET_2',
                    'If an embargo is already set, adding a new one prior to that date\'s passing will overwrite it'
                )
            )
        );
        // If there's no effective workflow, no need for the first bullet-point
        if (!$this->getIsWorkflowInEffect()) {
            $parts['PublishDateIntro']['BULLET_1'] = false;
        }
        return $parts[$key];
    }
1082166
public function getKeyValue($key)
    {
        foreach ($this->array as $k => $v) {
            if (strtolower($key) == strtolower($k)) {
                return $v;
            }
        }

        return '';
    }
207332
protected function getCustomMessageFromTranslator($key)
    {
        if (($message = $this->translator->trans($key)) !== $key) {
            return $message;
        }

        // If an exact match was not found for the key, we will collapse all of these
        // messages and loop through them and try to find a wildcard match for the
        // given key. Otherwise, we will simply return the key's value back out.
        $shortKey = preg_replace(
            '/^validation\.custom\./', '', $key
        );

        return $this->getWildcardCustomMessages(Arr::dot(
            (array) $this->translator->trans('validation.custom')
        ), $shortKey, $key);
    }
758828
static function getWorkflowState($workflow_key) {
        $status = self::STATUS_COMPLETED;
        $created_after = "-20 years";
        $data = DataStore::retrieveMostCurrentWorkflowJobByAgeAndStatus($workflow_key, $status, $created_after);
        if ($data) {
            return $data["end_state"];
        } else {
            $workflow = DataStore::retrieveWorkflow($workflow_key);
            if (!$workflow) {
                throw new \Exception("Error retrieving workflow for key $workflow_key can't determine state.");
            }
            $data = $workflow->getData();
            return $data[self::CONF_INITIAL_STATE];
        }
    }
347991
protected function getConditionsFromKey($key)
    {
        if (is_int($key) || ctype_digit($key)) {
            return array(self::MATCH_USERGROUP_ID => $key);
        }
        return array(self::MATCH_CONTENT_REMOTE_ID => $key);
    }
115955
public function get(string $key): string
    {
        return $this->handle->hGet($this->name, $key);
    }
227278
public function getMenuEntryForKey($key)
    {
        foreach ($this->menuEntries as $location => $priorities) {
            foreach ($priorities as $priority=> $menuEntries) {
                $result = $this->searchMenuEntryForKey($menuEntries, $key);
            
                if ($result !== false) {
                    return $result;
                }
            }
        }
        
        return false;
    }