public Object[] getAllEdges(Object[] cells)
	{
		List<Object> edges = new ArrayList<Object>();

		if (cells != null)
		{
			for (int i = 0; i < cells.length; i++)
			{
				int edgeCount = model.getEdgeCount(cells[i]);

				for (int j = 0; j < edgeCount; j++)
				{
					edges.add(model.getEdgeAt(cells[i], j));
				}

				// Recurses
				Object[] children = mxGraphModel.getChildren(model, cells[i]);
				edges.addAll(Arrays.asList(getAllEdges(children)));
			}
		}

		return edges.toArray();
	}