Implement generics across the board

Change implementation to use generics to indicate type of Id (e.g. Guid,
long, uint, etc.)