Role of an entity state in a component based system?
So, I've heard a bit about a model of game programming that involves creating entities and then attaching different components to them to change their behaviour. So, an enemy entity might have attached components of AI, collision physics, etc. This seems like an excellent way to solve a lot of the problems in creating an engine, but I don't really have a precise idea of what exactly an entity or component is.
So my question then: what exactly should an entity object encapsulate? How would I go about attaching components to it?