Added Support for custom types