The types of classes i have noticed that are essential to winning are:
-one medic (healing others keeps them alive longer which means a stronger frontline)
-one heavy (very armored-like and coupled with a medic makes them like a tank.)
-one engy (makes portals to transport other to the frontline faster and hold the frontline)
Without anyone of these it will be very difficult for you to win. Though it completly depends on the map :3
My team: 3 Medics
1 Heavy
2 Engies
Medic: One time I was the only Medic, it got so stressful I was glad to see the arrow piercing my head.
Heavy: If you have one good Heavy, and one decent Medic, you can do a lot of damage to the other team. You really only need 1 or 2 of these big guys.
Engineers: You need more than 1 specific place to set stuff up, if you have 1 dispenser, 1 sentry gun, in 1 place, you won't accomplish much.
That's just my opinion :3