created a pile class