Code of Civil Procedure § 1908.5
ARTICLE 2. Public Writings
When a judgment or order of a court is conclusive, the judgment or order must be alleged in the pleadings if there be an opportunity to do so; if there be no such opportunity, the judgment or order may be used as evidence.