Rules of law are general maxims, formed by the courts, who having observed what is common to many particular cases, announce this conformity by a maxim, which is called a rule; because in doubtful and unforeseen cases, it is a rule for their decision; it embraces particular cases within general principles.