(a) Except as otherwise provided in this chapter, the procedure in the action to quiet title from the commencement to the entry of judgment shall be in accordance with the rules relating to a civil action.(b) The action may be brought
(1) to compel an adverse party to commence an action of ejectment;(2) where an action of ejectment will not lie, to determine any right, lien, title or interest in the land or determine the validity or discharge of any document, obligation or deed affecting any right, lien, title or interest in land;(3) to compel an adverse party to file, record, cancel, surrender or satisfy of record, or admit the validity, invalidity or discharge of, any document, obligation or deed affecting any right, lien, title or interest in land; or(4) to obtain possession of land sold at a judicial or tax sale.