Crossfit seeks to increase fitness in many domains simultaneously. This includes training different metabolic pathways and increasing overall strength and agility. Crossfitters would say that an elite marathoner who can not lift an average amount of weight is not really fit. Similarly, an elite weightlifter who has trouble with a 5k is also not fit.
Although it isn't mentioned as much these days, one of the driving ideas behind crossfit was how to get as fit as possible with the least amount of work. By changing the workouts constantly, crossfit hopes to gain from physical adaptation before you become really good at something, your body is more efficient at it, and it takes more time to make smaller gains.
Crossfit tends to turn people into very good generalists who can do well in most situations. Crossfit is not a methodology which creates elite athletes in a particular discipline by itself (though it is used by olympic rowers, UFC competitors, NFL athletes, and others) because it is not specific. But it does help provide a very strong base to build upon for practically any sport.
There is not an official template on how to do crossfit, but an average 1 hour class might be made up of 30 minutes of focused strength work (squats, dead lift, press, olympic lifting), followed by a metabolic conditioning workout that combines multiple types of lower weight work.
The strength portion of the workout can follow methodologies such as Wendler 5-3-1 or West Side barbell. Sets and reps at my gym might be 3x5@80%, 3x3@85%, or 5x1@90% with timed rest between sets.
The metabolic conditioning workouts will range in length from 2 minute sprints to 60+ minute endurance workouts, which intentionally train different metabolic pathways and different aspects of muscular strength, power and endurance. These are timed workouts which are compared for improvement by either the increase in weight used, the number of reps performed, or the time to completion. Some classic workouts include the couplet 21-15-9 95lbs thrusters/pullups, 3 rounds of Run 400m/21 kettlebell swings/12 pullups, 1 mile run/100 pullups/200 push-ups/300 squats/1 mile run.
Good crossfit coaches keep up with current exercise research and use cycles to build a base, increase strength, increase speed, and deload. This is both a strength and a weakness of crossfit; because coaches have control over methodology, they can adapt and improve, but bad coaches can also do a poor job with programming.