Any railroad company now having in operation a line of railroad, or branches, sidings, or spurs thereof, upon any property in this state in use by the University of Washington for university purposes, or as a part of the grounds set aside or devoted to university purposes, may have such right-of-way confirmed to it, its successors and assigns, upon the following terms and conditions: Such railroad company shall file with the board of regents of said university a plat showing the right-of-way desired, and shall file a duplicate thereof with the commissioner of public lands; and any railroad company or streetcar company desiring hereafter to construct a railroad or streetcar line, or extensions thereof, with branches, sidings, or spurs, upon any property in this state in use by the University of Washington for university purposes, or as a part of the ground set aside or devoted to university purposes, may have such right-of-way confirmed to it, its successors and assigns, upon the following terms and conditions: Such railroad company or streetcar company shall file with the board of regents of said university a plat showing the right-of-way desired, and shall file a duplicate thereof with the commissioner of public lands.