checks whether this graph is complete (every vertex has an edge to any other vertex)

@return boolean
@uses Graph::getVertices()
@uses Vertex::hasEdgeTo()
551702
public function isComplete()
    {
        // copy of array (separate iterator but same vertices)
        $c = $vertices = $this->graph->getVertices()->getVector();
        // from each vertex
        foreach ($vertices as $vertex) {
            // to each vertex
            foreach ($c as $other) {
                // missing edge => fail
                if ($other !== $vertex && !$vertex->hasEdgeTo($other)) {
                    return false;
                }
            }
        }

        return true;
    }
664922
def is_complete(self):
        
        return all(
            [node.route_allocation() is not None for node in list(self._nodes.values()) if node != self._problem.depot()]
        )
834575
public function getEdgesOut()
    {
        $that = $this;

        return $this->getEdges()->getEdgesMatch(function (Edge $edge) use ($that) {
            return $edge->hasVertexStart($that);
        });
    }
547982
public function has()
    {
        if (!Request::has('position')) {
            return false;
        }

        if (isset($this->item->position)) {
            return true;
        }

        if (!empty($this->pivot) && isset($this->pivot->position)) {
            return true;
        }

        return false;
    }
194412
public function hasUndirected()
    {
        foreach ($this->set->getEdges() as $edge) {
            if ($edge instanceof EdgeUndirected) {
                return true;
            }
        }

        return false;
    }
474170
private function getSingleUndirectedRelation()
    {
        $ed = $this->getEdgeDefinitions();
        if (count($ed) > 0) {
            $a = $ed[0];
            $b = $a->getFromCollections();
            $c = $a->getToCollections();
        }
        if (count($ed) > 1 ||
            (
                count($ed) === 1 && (
                    count($a->getFromCollections()) > 1 ||
                    count($a->getToCollections()) > 1 ||
                    $b[0] !== $c[0]

                )
            )
        ) {
            throw new ClientException('This operation only supports graphs with one undirected single collection relation');
        }
        if (count($ed) === 1) {
            $eD                     = $ed[0];
            $this->_edgeDefinitions = [];
        } else {
            $eD = new EdgeDefinition();
        }

        return $eD;
    }
809620
boolean hasIncomingEdgesWithLabel(AtlasVertex vertex, String label) throws AtlasBaseException {
        boolean foundEdges = false;
        Iterator<AtlasEdge> inEdges = vertex.getEdges(AtlasEdgeDirection.IN).iterator();

        while (inEdges.hasNext()) {
            AtlasEdge edge = inEdges.next();

            if (label.equals(edge.getLabel())) {
                foundEdges = true;
                break;
            }
        }
        return foundEdges;
    }
1018940
public function getAlternatingSequence()
    {
        $edges    = $this->edges->getVector();
        $vertices = $this->vertices->getVector();

        $ret = array();
        for ($i = 0, $l = count($this->edges); $i < $l; ++$i) {
            $ret []= $vertices[$i];
            $ret []= $edges[$i];
        }
        $ret[] = $vertices[$i];

        return $ret;
    }
1365475
def exist_edge(self, graph, orig, dest, idx, branch, turn, tick, extant):
        """"""
        if (branch, turn, tick) in self._btts:
            raise TimeError
        self._btts.add((branch, turn, tick))
        graph, orig, dest = map(self.pack, (graph, orig, dest))
        self._edges2set.append((graph, orig, dest, idx, branch, turn, tick, extant))
1126945
public function getIsComplete ()
		{
			if ($this->_isComplete)
				return true;

			for ($i = 1; $i <= $this->_params[ 'totalChunks' ]; $i++)
			{
				if (!$this->chunkIsUploaded($i))
				{
					$this->_isComplete = false;

					return false;
				}
			}

			$this->_isComplete = true;

			return true;
		}
782978
public function getInDegree()
    {

        if (!is_a($this->nodeGraph, "\Platform\Graph")):
            throw new \Exception("Unkown node parent graph. Cannot calculate InDegree of NODE:" . $this->getId(), PLATFORM_ERROR); //Unkonwn graph type;
        endif;

        $graph = $this->getGraph();
        $arcIds = $graph->getArcSet();

        //If this graph is undirected, then we can't calculate the  indegree to this node;
        if (empty($arcIds))
            return $this->getDegree();

        $edges = $graph->getEdgeSet();
        $incidence = 0;

        //search for all arcs with this node as tail
        foreach ($arcIds as $arc):
            $edge = $edges[$arc];
            if ($edge->getTail()->getId() == $this->getId()) {
                $incidence++;
                //if head is the same as self, as is the case in cycled edges then we have one more indegree,
                //looped vertices have an indegree of two;
                if ($edge->getHead()->getId() == $this->getId())
                    $incidence++;
            }
        endforeach;

        return $incidence;
    }
1136989
protected function checkBrowserEdge()
    {
        if (stripos($this->_agent, 'edge') !== false) {
            $aresult = explode('/', stristr($this->_agent, 'Edge'));
            $aversion = explode(' ', $aresult[1]);
            $this->setVersion($aversion[0]);
            $this->setBrowser(self::BROWSER_EDGE);

            return true;

        }

        return false;
    }
804199
public function isCoherent()
	{
		$nodes = $this->getNodes();
		foreach( $nodes as $source )
		{
			foreach( $nodes as $target )
			{
				if( $source != $target )
				{
					$forward = $this->isPath( $source, $target );
					$backward = $this->isPath( $target, $source );
					if( !$forward && !$backward )
						return false;
				}
			}
		}
		return true;
	}
91942
public function getEdgeLast()
    {
        if (!$this->edges) {
            throw new UnderflowException('Does not contain any edges');
        }
        end($this->edges);

        return current($this->edges);
    }
791247
public function show(){
	        $output = "";
	        
	        //It prepares graph name
            $output .= "<br>================================<br>";
            $output .= "Graph Name: ".$this->name."<br>";
            $output .= "================================";
	        
	        //It prepares vertex set
	        $output .= "<br>V = { ";
	        foreach($this->vertexSet as $vertex){
	            $output .= $vertex->getId().", ";
	        }
	        $output = substr($output, 0, -2);
	        $output .= " }";
	        
	        //It prepares edge set
	        $output .= "<br>E = {";
	        foreach($this->edgeSet as $edge){
	            $output .= $edge->show() .", ";
	        }
	        $output = substr($output, 0, -2);
	        $output .= " }<br>";
	        $output .= "================================<br>";
	        
	        echo $output;   //It shows on browser
	    }
933802
def has_edge(self, node1_name, node2_name, account_for_direction=True):
        
        return self.__has_edge(node1_name=node1_name, node2_name=node2_name, account_for_direction=account_for_direction)
1345874
public function isClosed(): bool {
        foreach ($this->geometries as $geometry) {
            if (!$geometry->isClosed()) {
                return false;
            }
        }
        return true;
    }