Added delete, count and exists functions.