On the motion of the government attorney, the court may dismiss a civil action notwithstanding the objection of the person who initiated the action if the government attorney has notified the person of the filing of the motion to dismiss and the court has given the person an opportunity to oppose the motion and present evidence at a hearing.
§ 17-8-407, MCA