Vertex class for graph algorithms