public function getBiggestPartner($Key)
    {
        if (!isset($this->Data[$Key]["Connections"])) {
            return "";
        }

        $MaxWeight = 0;
        $Result = "";
        foreach ($this->Data[$Key]["Connections"] as $Key => $PeerID) {
            if ($this->Data[$PeerID]["Weight"] > $MaxWeight) {
                $MaxWeight = $this->Data[$PeerID]["Weight"];
                $Result = $PeerID;
            }
        }
        return $Result;
    }
public function getBiggestPartner($Key)
    {
        if (!isset($this->Data[$Key]["Connections"])) {
            return "";
        }

        $MaxWeight = 0;
        $Result = "";
        foreach ($this->Data[$Key]["Connections"] as $Key => $PeerID) {
            if ($this->Data[$PeerID]["Weight"] > $MaxWeight) {
                $MaxWeight = $this->Data[$PeerID]["Weight"];
                $Result = $PeerID;
            }
        }
        return $Result;
    }
public function getBiggestPartner ( $ Key ) { if ( ! isset ( $ this -> Data [ $ Key ] [ "Connections" ] ) ) { return "" ; } $ MaxWeight = 0 ; $ Result = "" ; foreach ( $ this -> Data [ $ Key ] [ "Connections" ] as $ Key => $ PeerID ) { if ( $ this -> Data [ $ PeerID ] [ "Weight" ] > $ MaxWeight ) { $ MaxWeight = $ this -> Data [ $ PeerID ] [ "Weight" ] ; $ Result = $ PeerID ; } } return $ Result ; }
Return the ID of the attached partner with the biggest weight
@param string $Key
@return string
Return the ID of the attached partner with the biggest weight