Implemented types method.

Signed off by: Alessandro Palmeira <alessandro.palmeira@gmail.com>