An action is an ordinary proceeding in a court of justice, by which a party prosecutes another party for the enforcement or protection of a right, the redress or prevention of a wrong, or the punishment of a public offense.