(a) The action of ejectment may be maintained in all cases in which the plaintiff claims the possession of the premises under or by virtue of:
(1) An entry made with the register and receiver of the proper land office of the United States;
(2) A preemption right under the laws of the United States; or
(3) When an improvement has been made by him or her on any of the public lands of the United States, whether the lands have been surveyed or not, and when any person, other than those to whom the right of action is given by subdivisions (a)(1) and (2) of this section, is in possession of the improvement.
(b) An action of trespass may also be maintained in all the cases enumerated in subsection (a) of this section.
(c) The executor or administrator of any person who has died and who in his or her lifetime made improvements on any of the public lands of the United States, whether he or she had a right of preemption to the improvements or not under the laws of the United States, or whether the lands on which the improvements may have been made have been surveyed or not, may maintain an action of ejectment for the recovery of the improvement, to the same extent and with the same restrictions as provided by subsection (a) of this section, for their testator or intestate.