发布uid信息.

@param $uid

@return mixed|null

@throws \Exception
191644
public function getUidInfo($uid)
    {
        $fd = $this->getFdFromUid($uid);
        if (empty($fd)) {
            if (!$this->isCluster()) {
                return [];
            } else {
                $fdInfo = ProcessManager::getInstance()->getRpcCall(ClusterProcess::class)->my_getUidInfo($uid);

                return $fdInfo;
            }
        } else {
            $fdInfo = $this->getFdInfo($fd);
            $fdInfo['node'] = getNodeName();

            return $fdInfo;
        }
    }
1133004
public function serverGetByUid($uid)
  {
    foreach($this->serverList() as $server)
    {
      if($server["virtualserver_unique_identifier"] == $uid) return $server;
    }

    throw new Exception("invalid serverID", 0x400);
  }
920686
public static function getTagGroupByUid(string $uid): TagGroup
    {
        $query = TagGroup::find();
        $query->andWhere(['uid' => $uid]);
        return $query->one() ?? new TagGroup();
    }
1278216
public function getUid()
    {
        if (!array_key_exists(self::UID, $this->passwd)) {
            throw new \Exception('Could not get user id from passwd.');
        }
        return $this->passwd[self::UID];
    }
1195517
public function getHeader( $uid = '' )
	{
		$view = $this->getObject()->addData( $this->getView() );

		$content = '';
		foreach( $this->getSubClients() as $subclient ) {
			$content .= $subclient->setView( $view )->getHeader( $uid );
		}
		$view->subscriptionHeader = $content;


		$addr = $view->extAddressItem;

		$msg = $view->mail();
		$msg->addHeader( 'X-MailGenerator', 'Aimeos' );
		$msg->addTo( $addr->getEMail(), $addr->getFirstName() . ' ' . $addr->getLastName() );


		/** client/html/email/from-name
		 * @see client/html/email/subscription/from-email
		 */
		$fromName = $view->config( 'client/html/email/from-name' );

		/** client/html/email/subscription/from-name
		 * Name used when sending subscription e-mails
		 *
		 * The name of the person or e-mail subscription that is used for sending all
		 * shop related subscription e-mails to customers. This configuration option
		 * overwrite the name set in "client/html/email/from-name".
		 *
		 * @param string Name shown in the e-mail
		 * @since 2018.04
		 * @category User
		 * @see client/html/email/from-name
		 * @see client/html/email/from-email
		 * @see client/html/email/reply-email
		 * @see client/html/email/bcc-email
		 */
		$fromNameSubscription = $view->config( 'client/html/email/subscription/from-name', $fromName );

		/** client/html/email/from-email
		 * @see client/html/email/subscription/from-email
		 */
		$fromEmail = $view->config( 'client/html/email/from-email' );

		/** client/html/email/subscription/from-email
		 * E-Mail address used when sending subscription e-mails
		 *
		 * The e-mail address of the person or subscription that is used for sending
		 * all shop related product notification e-mails to customers. This configuration option
		 * overwrites the e-mail address set via "client/html/email/from-email".
		 *
		 * @param string E-mail address
		 * @since 2018.04
		 * @category User
		 * @see client/html/email/subscription/from-name
		 * @see client/html/email/from-email
		 * @see client/html/email/reply-email
		 * @see client/html/email/bcc-email
		 */
		if( ( $fromEmailSubscription = $view->config( 'client/html/email/subscription/from-email', $fromEmail ) ) != null ) {
			$msg->addFrom( $fromEmailSubscription, $fromNameSubscription );
		}


		/** client/html/email/reply-name
		 * @see client/html/email/subscription/reply-email
		 */
		$replyName = $view->config( 'client/html/email/reply-name', $fromName );

		/** client/html/email/subscription/reply-name
		 * Recipient name displayed when the customer replies to subscription e-mails
		 *
		 * The name of the person or e-mail subscription the customer should
		 * reply to in case of subscription related questions or problems. This
		 * configuration option overwrites the name set via
		 * "client/html/email/reply-name".
		 *
		 * @param string Name shown in the e-mail
		 * @since 2018.04
		 * @category User
		 * @see client/html/email/subscription/reply-email
		 * @see client/html/email/reply-name
		 * @see client/html/email/reply-email
		 * @see client/html/email/from-email
		 * @see client/html/email/bcc-email
		 */
		$replyNameSubscription = $view->config( 'client/html/email/subscription/reply-name', $replyName );

		/** client/html/email/reply-email
		 * @see client/html/email/subscription/reply-email
		 */
		$replyEmail = $view->config( 'client/html/email/reply-email', $fromEmail );

		/** client/html/email/subscription/reply-email
		 * E-Mail address used by the customer when replying to subscription e-mails
		 *
		 * The e-mail address of the person or e-mail subscription the customer
		 * should reply to in case of subscription related questions or problems.
		 * This configuration option overwrites the e-mail address set via
		 * "client/html/email/reply-email".
		 *
		 * @param string E-mail address
		 * @since 2018.04
		 * @category User
		 * @see client/html/email/subscription/reply-name
		 * @see client/html/email/reply-email
		 * @see client/html/email/from-email
		 * @see client/html/email/bcc-email
		 */
		if( ( $replyEmailSubscription = $view->config( 'client/html/email/subscription/reply-email', $replyEmail ) ) != null ) {
			$msg->addReplyTo( $replyEmailSubscription, $replyNameSubscription );
		}


		/** client/html/email/bcc-email
		 * @see client/html/email/subscription/bcc-email
		 */
		$bccEmail = $view->config( 'client/html/email/bcc-email' );

		/** client/html/email/subscription/bcc-email
		 * E-Mail address all subscription e-mails should be also sent to
		 *
		 * Using this option you can send a copy of all subscription related e-mails
		 * to a second e-mail subscription. This can be handy for testing and checking
		 * the e-mails sent to customers.
		 *
		 * It also allows shop owners with a very small volume of orders to be
		 * notified about subscription changes. Be aware that this isn't useful if the
		 * order volumne is high or has peeks!
		 *
		 * This configuration option overwrites the e-mail address set via
		 * "client/html/email/bcc-email".
		 *
		 * @param string|array E-mail address or list of e-mail addresses
		 * @since 2018.04
		 * @category User
		 * @category Developer
		 * @see client/html/email/bcc-email
		 * @see client/html/email/reply-email
		 * @see client/html/email/from-email
		 */
		if( ( $bccEmailSubscription = $view->config( 'client/html/email/subscription/bcc-email', $bccEmail ) ) != null )
		{
			foreach( (array) $bccEmailSubscription as $emailAddr ) {
				$msg->addBcc( $emailAddr );
			}
		}


		/** client/html/email/subscription/standard/template-header
		 * Relative path to the HTML header template of the subscription e-mail client.
		 *
		 * The template file contains the HTML code and processing instructions
		 * to generate the HTML code that is inserted into the HTML page header
		 * of the rendered page in the frontend. The configuration string is the
		 * path to the template file relative to the templates directory (usually
		 * in client/html/templates).
		 *
		 * You can overwrite the template file configuration in extensions and
		 * provide alternative templates. These alternative templates should be
		 * named like the default one but with the string "standard" replaced by
		 * an unique name. You may use the name of your project for this. If
		 * you've implemented an alternative client class as well, "standard"
		 * should be replaced by the name of the new class.
		 *
		 * The product notification e-mail HTML client allows to use a different template for
		 * each subscription status value. You can create a template for each subscription
		 * status and store it in the "email/subscription/<status number>/" directory
		 * below the "templates" directory (usually in client/html/templates). If no
		 * specific layout template is found, the common template in the
		 * "email/subscription/" directory is used.
		 *
		 * @param string Relative path to the template creating code for the HTML page head
		 * @since 2018.04
		 * @category Developer
		 * @see client/html/email/subscription/standard/template-body
		 */
		$tplconf = 'client/html/email/subscription/standard/template-header';

		return $view->render( $view->config( $tplconf, 'email/subscription/header-standard' ) ); ;
	}
911749
public function getProcessByPid($pid)
    {
        foreach ($this->processes as $process) {
            if ($process->getPid() == $pid) {
                return $process;
            }
        }

        return null;
    }
1013034
public static function getClientIdByUid($uid)
    {
        $gateway_data             = GatewayProtocol::$empty;
        $gateway_data['cmd']      = GatewayProtocol::CMD_GET_CLIENT_ID_BY_UID;
        $gateway_data['ext_data'] = $uid;
        $client_list              = array();
        $all_buffer_array         = self::getBufferFromAllGateway($gateway_data);
        foreach ($all_buffer_array as $local_ip => $buffer_array) {
            foreach ($buffer_array as $local_port => $connection_id_array) {
                if ($connection_id_array) {
                    foreach ($connection_id_array as $connection_id) {
                        $client_list[] = Context::addressToClientId($local_ip, $local_port, $connection_id);
                    }
                }
            }
        }
        return $client_list;
    }
464444
public function get_body($uid, $part = 1)
    {
        $headers = $this->get_message_headers($uid);
        return rcube_charset::convert($this->get_message_part($uid, $part, null),
            $headers->charset ?: $this->default_charset);
    }
144150
public function reverseTransform($uID)
    {
        if (!is_numeric($uID) || $uID == 0) {
            return null;
        }

        $rep = $this->entityManager->getRepository('Concrete\Core\User\User');

        $u = $rep->find($uID);
        if (!is_object($u) || $u->isError()) {
            throw new TransformationFailedException('Invalid user ID.');
        }

        return $u;
    }
839038
public static function getById($uid)
    {    
		if ($uid == USER_ANONYMOUS) return new User\Anonymous();
        $fields = self::getDbConnection()->fetchAssoc( 'SELECT * FROM '.User::TABLE.' WHERE id = ?', array( $uid ) );
        if (!$fields) throw new \Exception('User:'.$uid.' is not found'); 
        return self::fetch($fields);    
  	}
361175
public function getPage(int $uid, int $languageUid = null) {
    $page   = null;
    $record = $this->pageRepository->getPage($uid);

    if (is_array($record) && !empty($record)) {
      if (in_array($record['doktype'], self::PAGE_DOKTYPES)) {
        $page        = $record;
        $languageUid = isset($languageUid) ? $languageUid : $this->languageService->getLanguageUid();

        if ($languageUid > 0) {
          $page = $this->pageRepository->getPageOverlay($page, $languageUid);
        }
      }
    }

    return $page;
  }
958429
public function updateUid($uid, $sid) {
		$sql = 'UPDATE '. self::tableName .' SET uid=:uid WHERE session_id=:session_id';
		
		$params = array(
			'uid'			=> $uid,
			'session_id'	=> $sid
		);
		
		try {
			$retval = $this->db->run_query($sql, $params);
		}
		catch(Exception $e) {
			$this->exception_handler($e->getMessage());
		}
		
		return($retval);
	}
976574
public static function getRootLine($uid = null)
    {
        if ($uid === null) {
            #################
            # Current rootline
            #################
            if (empty(self::$rootlineCache['__CURRENT__'])) {
                // Current rootline
                $rootline = $GLOBALS['TSFE']->tmpl->rootLine;

                // Filter rootline by siteroot
                $rootline = self::filterRootlineBySiteroot((array)$rootline);

                self::$rootlineCache['__CURRENT__'] = $rootline;
            }

            $ret = self::$rootlineCache['__CURRENT__'];
        } else {
            #################
            # Other rootline
            #################
            if (empty(self::$rootlineCache[$uid])) {
                // Fetch full rootline to TYPO3 root (0)
                $rootline = self::getSysPageObj()->getRootLine($uid);

                // Filter rootline by siteroot
                $rootline = self::filterRootlineBySiteroot((array)$rootline);

                self::$rootlineCache[$uid] = $rootline;
            }

            $ret = self::$rootlineCache[$uid];
        }

        return $ret;
    }
1344117
protected function getUserInfo($uid) {
        static $userinfo=array();
        if(!isset($userinfo[$uid])){
             $userinfo[$uid]=M()->where(array('uid'=>$uid))->table($this->_config['AUTH_USER'])->find();
        }
        return $userinfo[$uid];
    }
766680
public function clientGetByUid($uid)
  {
    foreach($this->clientList() as $client)
    {
      if($client["client_unique_identifier"] == $uid) return $client;
    }

    throw new Exception("invalid clientID", 0x200);
  }
58749
public function my_removeUid($uid)
    {
        if (get_instance()->isCluster()) {
            $this->map[$this->node_name]->remove($uid);
            foreach ($this->client as $client) {
                $client->removeNodeUid($this->node_name, $uid);
            }
            if (Start::isLeader()) {
                get_instance()->pub('$SYS/uidcount', $this->countOnline());
            }
        }
        $this->my_clearUidSub($uid);
    }
1271041
public function getPidFromUid($uid = 0)
    {
        $queryBuilder = self::getQueryBuilder();
        $triggerElement = $queryBuilder
            ->select('pid')
            ->from('tt_content')
            ->where(
                $queryBuilder->expr()->eq(
                    'uid',
                    $queryBuilder->createNamedParameter(abs($uid), \PDO::PARAM_INT)
                )
            )
            ->execute()
            ->fetch();
        $pid = (int)$triggerElement['pid'];
        return is_array($triggerElement) && $pid ? $pid : 0;
    }