@Override
	protected Match addInitialMatch(Edge e, Edge eP, String matchID)
	{
		Match m = new Match(graph, pattern, e, eP, matchID);

		// get neighbor edges in pattern and all matches containing these neighbor edges
		Set<Edge> neighborEdgePs = new HashSet<Edge>();
		neighborEdgePs.addAll(pattern.getInEdges(eP.getFrom()));
		neighborEdgePs.addAll(pattern.getOutEdges(eP.getFrom()));
		neighborEdgePs.addAll(pattern.getInEdges(eP.getTo()));
		neighborEdgePs.addAll(pattern.getOutEdges(eP.getTo()));
		Set<Match> nMatches = new HashSet<Match>();
		for(Edge neP : neighborEdgePs)
			if(ePMatchIndex.containsKey(neP))
				for(Iterator<Match> it = ePMatchIndex.get(neP).iterator(); it.hasNext();)
				{
					Match mc = it.next();
					if(mc.isValid())
						nMatches.add(mc);
					else
						it.remove();
				}
		// add other matches to candidates list
		for(Match mi : nMatches)
			m.considerCandidate(mi, eMatchIndex, ePMatchIndex, monitor);
		// add to indexes
		if(!eMatchIndex.containsKey(e))
			eMatchIndex.put(e, new HashSet<Match>());
		eMatchIndex.get(e).add(m);
		if(!ePMatchIndex.containsKey(eP))
			ePMatchIndex.put(eP, new HashSet<Match>());
		ePMatchIndex.get(eP).add(m);
		// add to global lists
		matchQueue.add(m);
		allMatches.add(m);
		return m;
	}