Added a class for encapsulating the triangle data.