In terms of strategic importance in a game, the priorities of a batsman are, in order of importance:
1. Do not get out.
2. Score runs
3. Do not get injured
Whereas in one-day cricket, the prime objective is to score runs quickly, in Test Match cricket self preservation will allow the batsman to score runs for longer, but in terms of the team's goal in winning the game it is more important not to get out. This is because an injured batsman can leave the game temporarily and resume batting in the same innings once recovered, whereas an out batsman cannot bat again in the same innings.
This contrasts with baseball, in which the primary goal of batting is scoring runs. This is reflected in the difference in terminology of attack and defence between the sports. In baseball, batting is considered the offensive role, whereas in cricket batting has a defensive role. However, the growth of the modern game over the past two decades has made batting in its aggressive form more popular, there is usually a batsmen or two in each of the top teams who specialises in attacking play.