How to Find Vertices of Specific class with Tinkerpop Frames
问题 I have a FramedGraph object with Vertices of different classes, for instance Person and Location. I would like to retrieve all vertices of the "Person" class. Here is my current method. public List<Person> listPeople() { List<Person> people = new ArrayList<Person>(); Iterator iterator = g.getVertices().iterator(); while (iterator.hasNext()) { Vertex v = (Vertex) iterator.next(); Person p = (Person) g.getVertex(v.getId(), Person.class); people.add(p); } return people; } This feels terrifically