
576 N.W.2d 334 (1998)
Christine BAILEY, Appellant,
v.
Michael BATCHELDER, Appellee,
Michael BATCHELDER, Third-Party Plaintiff,
v.
Meril BAILEY, Third-Party Defendant.
No. 96-1316.
Supreme Court of Iowa.
March 25, 1998.
*335 Sara Riley Brown of Tom Riley Law Firm, P.C., Cedar Rapids, for appellant.
Kevin Collins and William H. Courter of Shuttleworth & Ingersoll, P.C., Cedar Rapids, for appellee.
*336 Considered by McGIVERIN, C.J., and HARRIS, LAVORATO, NEUMAN, and TERNUS, JJ.
LAVORATO, Justice.
In this negligence action, the plaintiff alleges she was injured when a co-employee's car collided with a car in which the plaintiff was a passenger. The collision happened in a parking lot adjacent to their place of employment while both were arriving early for work. The employer provided the parking lot for its employees. The principal issue on appeal is whether the plaintiff's exclusive remedy was under the Workers' Compensation Act. We agree with the district court's summary judgment ruling that it was and affirm the court's dismissal of the plaintiff's action for lack of subject matter jurisdiction.

I. Facts.

The following facts gleaned from depositions and pleadings are essentially undisputed. Christine and Meril Bailey are married. Both are employed at Amana Refrigeration in Main Amana, Iowa.
On February 9, 1994, Christine suffered injuries in an automobile collision that happened in the parking lot owned by their employer. Meril was driving and Christine was a passenger. Michael Batchelder, a co-employee, was driving the other vehicle involved in the collision.
Batchelder and the Baileys were scheduled to begin work at 3:30 p.m. The Baileys arrived at the parking lot at 2:40 p.m. The Baileys arrived early to retrieve a videotape from Christine's father's vehicle and to find a convenient parking space close to the entrance of the employer's plant. The collision happened shortly thereafter. Like the Baileys, Batchelder was also searching for a parking space.

II. Proceedings.

Later, Christine sued Batchelder, alleging ordinary negligence. Batchelder answered and asserted a cross-claim against Meril.
Following the filing of these pleadings, Batchelder filed a motion for summary judgment. Batchelder alleged the following facts which he claimed entitled him to a judgment as a matter of law:
5. The accident occurred in the Amana Refrigeration parking lot while all three employees were attempting to find parking spots and begin working at 3:30 p.m.
6. All three parties were in the "zone of employment" at the time of the accident, and co-employees are not liable to each other for negligent conduct causing injury unless such conduct constituted "gross negligence."
7. The plaintiff has not pled and there is no genuine issue of material fact regarding whether Mr. Batchelder's conduct constituted gross negligence.
8. Defendant/third-party [plaintiff], Michael Batchelder, is entitled to the protection of the Iowa Workers' Compensation statute 85.20.
9. No genuine issues of material fact exist regarding the plaintiff's negligence claim against defendant Michael Batchelder, and, therefore, Michael Batchelder is entitled to judgment as a matter of law.
These allegations effectively interposed the Workers' Compensation Act as Christine's sole remedy, obviously alerting the district court to a lack of subject matter jurisdiction issue.
In resisting the motion for summary judgment, Christine contended that the exclusivity of the Workers' Compensation Act was an affirmative defense that Batchelder had to plead pursuant to Iowa Rule of Civil Procedure 101. The district court noted that if the facts showed an employer/employee relationship, it had no subject matter jurisdiction because of the exclusivity of the Workers' Compensation Act. Subject matter jurisdiction, the court pointed out, could be raised at any time. Thus, a failure to plead exclusivity was, according to the court, "not germane to the court's consideration of the [exclusivity] issue."
The court concluded that employee injuries sustained in parking lots provided by the employer are an exception to the "going and coming" rule and are therefore exclusively covered under the Workers' Compensation Act. Applying the rule to the facts of this *337 case, the court further concluded the Workers' Compensation Act governed Christine's claim and the Act was her exclusive remedy. For this reason, the court found itself without subject matter jurisdiction and accordingly sustained the motion for summary judgment.
Christine appeals from this ruling. She again contends Batchelder's failure to plead exclusivity of the Workers' Compensation Act barred that "defense." In addition, she contends this court has adopted no exception to the "going and coming rule," which would apply to the facts here.

III. Scope of Review.

We review district court summary judgment rulings for correction of errors at law. Hagen v. Texaco Ref. & Mktg. Inc., 526 N.W.2d 531, 534 (Iowa 1995). We summarized the principles governing the review of grants of summary judgment in Knapp v. Simmons, 345 N.W.2d 118, 121 (Iowa 1984):
Summary judgment is proper when there is no genuine issue of [material] fact and the moving party is entitled to the judgment as a matter of law. The burden of showing the nonexistence of a material fact is upon the moving party. While an adverse party generally cannot rest upon his pleadings when the moving party has supported his motion, summary judgment is still not proper if reasonable minds could draw different inferences and conclusions from the undisputed facts. In this respect, summary judgment is functionally akin to a directed verdict; every legitimate inference that reasonably can be deduced from the evidence should be afforded the nonmoving party, and a fact question is generated if reasonable minds could differ on how the issues should be resolved.
(Citations omitted.)

IV. Exclusivity and Subject Matter Jurisdiction.

The injured employee's right to workers' compensation is the employee's exclusive remedy against the employer. Iowa Code §§ 85.3(1), 85.20 (1993); Glenn v. Farmland Foods, Inc., 344 N.W.2d 240, 242 (Iowa 1984). Christine does not dispute this. Nor does she dispute that the district court lacks subject matter jurisdiction over claims arising under chapter 85. Rather, she contends exclusivity of the Workers' Compensation Act is an affirmative defense, which Batchelder was required to plead pursuant to Iowa Rule of Civil Procedure 101.
Rule 101 requires that "any defense ... which admits the facts of the adverse pleading[s] but seeks to avoid their legal effect, must be specifically pleaded." Because Batchelder did not plead exclusivity, Christine insists such failure bars the "defense."
Christine believes Batchelder had a duty to raise the exclusivity issue because the statute of limitations had run on her workers' compensation claim by the time Batchelder filed his motion for summary judgment. This is especially true, Christine argues, when Batchelder acknowledges this court has never addressed the issue of injuries caused by a co-employee occurring in parking lots as the co-employees report to work.
We think the Act's exclusivity goes to the heart of the district court's jurisdiction. Jurisdiction is the inherent power of the court to decide a case. State v. Bosworth, 145 W.Va. 753, 117 S.E.2d 610, 619 (1960). Jurisdiction is of two sortsjurisdiction of the subject matter and jurisdiction of the person. Id. Here we are dealing with subject matter jurisdiction.
Subject matter jurisdiction is the authority of a court to hear and determine cases of the general class to which the proceedings belong, not merely the particular case then occupying the court's attention. Christie v. Rolscreen Co., 448 N.W.2d 447, 450 (Iowa 1989). Because an injured employee's exclusive remedy falls under chapter 85, our district courts do not have authority to hear workers' compensation cases. Such cases are not of the general class of cases the district court has authority to hear.
In addition, lack of subject matter jurisdiction may be raised at any time:
Every court has inherent power to determine whether it has jurisdiction over the subject matter of the proceedings before it. It makes no difference how the question *338 comes to its attention. Once raised, the question must be disposed of, no matter in what manner or form or stage presented. The court on its own motion will examine grounds of its jurisdiction before proceeding further.
Tigges v. City of Ames, 356 N.W.2d 503, 510 (Iowa 1984) (quoting Walles v. International Bhd. of Elec. Workers, 252 N.W.2d 701, 710 (Iowa 1977)); see also Iowa R. Civ. P. 104(a) (1997) ("[T]he court shall dismiss the action at any time it finds, by suggestion of the parties or otherwise, that the court lacks jurisdiction of the subject matter.") (substance of this portion of Iowa R. Civ. P. 104(a) is now included in Iowa R. Civ. P. 88(a), (d) (1998)). Unlike jurisdiction of the person, the parties cannot waive or vest subject matter jurisdiction. In re Estate of Dull, 303 N.W.2d 402, 406 (Iowa 1981).
Thus, contrary to Christine's arguments, the Act's exclusivity is not an affirmative defense which a party must assert. This is so because the Act's exclusivity means the district court has no subject matter jurisdiction over a workers' compensation case. Once a court discovers it does not have subject matter jurisdiction, it has no choice but to dismiss the case, no matter where in the stage of the proceedings this jurisdictional defect comes to light. The district court correctly considered the lack-of-subject-matter-jurisdiction issue even though Batchelder did not raise the exclusivity issue in his pleadings.

V. Parking Lot Injuries as an Exception to the "Going and Coming" Rule.

A. "Arising out of and in the course of employment." Iowa Code section 85.3(1) provides:
Every employer, not specifically excepted by the provisions of this chapter, shall provide, secure, and pay compensation according to the provisions of this chapter for any and all personal injuries sustained by an employee arising out of and in the course of the employment.

(Emphasis added.)
For the Workers' Compensation Act to apply, the proponent must show by a preponderance of the evidence that the employee's injuries arose out of and in the course of the employment. Waterhouse Water Conditioning, Inc. v. Waterhouse, 561 N.W.2d 55, 57 (Iowa 1997). An injury "arises out of" the employment provided there is a causal connection between the employment and the injury. Id. The injury arises "in the course of" the employment when the injury and the employment coincide as to time, place, and circumstances. Id. Thus, the proponent must satisfy a twoprong test: the "arises out of" and the "arises in the course of" prongs.
More specifically as to the "in the course of" prong, we have said:
[a]n injury [arises] in the course of the employment when it is within the period of employment at a place where the employee reasonably may be in performing his duties, and while he is fulfilling those duties or engaged in doing something incidental thereto. An injury [arising] in the course of employment embraces all injuries received while employed in furthering the employer's business and injuries received on the employer's premises, provided that the employee's presence must ordinarily be required at the place of the injury, or, if not so required, the employee's departure from the usual place of employment must not amount to an abandonment of employment or be an act wholly foreign to his usual work. An employee does not cease to be in the course of his employment merely because he is not actually engaged in doing some specifically prescribed task, if, in the course of his employment, he does some act which he deems necessary for the benefit or interest of his employer.
Id. (quoting Bushing v. Iowa Ry. & Light Co., 208 Iowa 1010, 1018, 226 N.W. 719, 723 (1929)). In short, the "in the course of" prong demands that the proponent establish "the injury [arose] within the time and space boundaries of the employment, and in the course of an activity whose purpose is related to the employment." 1 Arthur Larson & Lex K. Larson, The Law of Workmen's Compensation § 14.00, at 4-1 (1994) [hereinafter Larson].
*339 B. The going and coming rule. With a few exceptions not relevant here, under "the going and coming" rule, workers' compensation does not cover an injury occurring off of the employer's premises, on the way to or from work. Frost v. S.S. Kresge Co., 299 N.W.2d 646, 648 (Iowa 1980). Pursuant to this rule, "the hazards encountered by the employee in going to or returning from work are not ordinarily incident to his employment within the meaning of the phrase as used in the work[ers'] compensation law." Quaker Oats Co. v. Ciha, 552 N.W.2d 143, 150-51 (Iowa 1996) (quoting Bulman v. Sanitary Farm Dairies, 247 Iowa 488, 492, 73 N.W.2d 27, 29 (1955)); see also Pribyl v. Standard Elec. Co., 246 Iowa 333, 339, 67 N.W.2d 438, 443 (1954) ("Ordinarily an employee whose work begins when he arrives in the morning is engaged in his own business when he travels to work at the regular time. He is not then pursuing his master's business."). Thus, "the course of employment commences after the employee reaches the premises when his actual work begins and is carried on and ceases when he leaves." Otto v. Independent Sch. Dist., 237 Iowa 991, 994, 23 N.W.2d 915, 916 (1946). The rule, however, applies only to employees who have both a fixed place and fixed hours of work. Waterhouse, 561 N.W.2d at 57-58.
In Frost, we recognized that conceptually "the employment is the cause of injuries in going and coming" because "if not for the job there would be no reason in most cases to approach or leave the premises." 299 N.W.2d at 648 (citing Larson § 15.00, at 4-12). Thus, the "going and coming" rule applies only to the second prong of the test for workers' compensation coverage: the injury must arise "in the course of" the employment. Id. The rule measures the work connection of the incident as to time, place, and activity. Id.
C. The premises rule. On the other hand, courts are nearly unanimous in holding that "for an employee having fixed hours and place of work, going to and from work is covered  on the employer's premises." Larson § 15.00, at 4-3-4-5. This is known as the premises rule. Id. § 15.00, at 4-3. The premises rule is a compromise between two extremes: the concept that "the employment is the cause of the workmen's journey between his home and the factory" and the concept that "workmen's compensation was not intended to protect him against all the perils of that journey." Id. Although the premises rule is somewhat arbitrary, there is logic behind it: "[W]hile the employee is on the employer's premises, the connection with the employment environment is physical and tangible." Id. § 15.00, at 4-11.
1. The premises rule extended. In recognizing several exceptions to the "going and coming" rule, courts have in effect extended "the employer's premises under certain circumstances when it would be unduly restrictive to limit coverage of compensation statutes to the physical perimeters of the employer's premises." Frost, 299 N.W.2d at 648-49. Underlying these exceptions to the going and coming rule is the notion that the course of employment should extend to any injury that occurs at a point where the employee is within the range of dangers associated with the employment. Larson § 15.00, at 4-3. In Frost, an employee fell on a public sidewalk between twelve and twenty feet from the entrance to the employer's store which she intended to enter to attend a birthday breakfast prior to a store meeting. An accumulation of ice caused the fall. This court held she was entitled to workers' compensation benefits. Frost, 299 N.W.2d at 649-50.
The court gave two reasons for holding so. The court's primary reason was because the fall "was so closely connected in time, location, and employee usage to the work premises itself to entitle [the injured employee] to the protection of our workers' compensation statute." Id. The court based the holding upon the fact that "the nexus of the work relationship is so strong that protection under chapter 85 is appropriate without regard to any formalistic exception to the going and coming rule." Id. at 649 (emphasis added).
The secondary reason for finding coverage was rooted in an exception to the going and coming rule. Id. at 650. That exception is "based upon an employer's exercise of control over adjacent areas, such as sidewalks." Id. There was evidence in Frost that the *340 employer had exercised control over the sidewalk by removing ice and snow. Id. This court held as a matter of law that the employer's "exercise of control over the sidewalk co-extensively extended its work premises for workers' compensation purposes." Id. We noted that such an extension was especially suited to the facts of the case because the employer's acts of controlremoval of ice and snowhad such a close bearing upon the cause of the claimant's injury. Id.
a. Parking lots. Most jurisdictions that have considered the question now recognize that employee parking lots are part of the employer's premises for purposes of applying the "going and coming" rule and its "premises exception." Larson § 15.42(a), at X-XXX-X-XXX; see also Alan Stephens, Annotation, Workers' Compensation: Coverage of Injury Occurring in Parking Lot Provided by Employer, While Employee Was Going to or Coming from Work, 4 A.L.R.5th 443, 463 (1992). Thus, under the premises exception to the going and coming rule, once an employee reaches the premises of the employer, the Workers' Compensation Act governs. We think the rule is sound and join those jurisdictions that have adopted it.
2. The parking lot premises rule applied. Our adoption of the rule, however, does not end the inquiry under the facts here. For workers' compensation to apply, Christine contends, a parking lot accident resulting in injury to an employee must happen "within a reasonable time before or after work." Fifty minutes, Christine argues, is not a reasonable time before work.
In addition, Christine contends she was injured while on a mission for her sole convenience: She arrived at work fifty minutes early to (1) retrieve a videotape and (2) get a parking space. In support of this contention, Christine argues that her employer provides sufficient parking to accommodate all employees, but she and Batchelder like to park as close to the building as possible for their own comfort and convenience. From this, Christine concludes her employer receives no benefit simply because she and Batchelder arrive almost one hour before their shift just to park yardsrather than blocksaway from the building. The early arrival, Christine concludes, is for their benefit, not for their employer's benefit.
All of these contentions raise the question whether the district court erred in holding as a matter of law that Christine's injury arose in the course of her employment.
a. Is arriving for work fifty minutes early within the course of employment? This question has arisen before and courts have used a common-sense approach in resolving it: "[T]he hours of employment include a reasonable amount of time before and after the scheduled work hours." Rose v. Cadillac Fairview Shopping Ctr. Properties, 668 A.2d 782, 788 (Del.Super.Ct.1995); accord North Am. Rockwell Corp. v. Workmen's Comp. Appeals Bd., 9 Cal.App.3d 154, 160, 87 Cal.Rptr. 774 (1970); Brooks v. Carter, 102 Ill.App.3d 635, 58 Ill.Dec. 534, 536, 430 N.E.2d 566, 568 (1981); Starrett v. Pier Foundry, 488 N.W.2d 273, 274 (Minn.1992); Carter v. Volunteer Apparel, Inc., 833 S.W.2d 492, 494 (Tenn.1992); Brown v. Reed, 209 Va. 562, 165 S.E.2d 394, 397 (1969).
What constitutes a reasonable amount of time depends "not only on the length of time involved but also on the circumstances occasioning the interval and the nature of the employee's activity." Carter, 833 S.W.2d at 494. For example, in Rose, the employee arrived about fifty to fifty-five minutes before her shift was to begin. 668 A.2d at 785. She had intended to go into the break room to read the paper until then. Id. After parking, the employee was about to get out of her car when an unknown male robbed and abducted her. The court sustained a summary judgment motion barring the employee's tort suit against her employer because of the exclusivity provision of the workers' compensation law. Id. at 790-91. In doing so the court reasoned:
In the case at bar, the plaintiff testified that she intended to go into the break room in Sears and read the paper until her shift was to begin. She stated that in the past she has arrived at work early on Sundays and used the break room to eat her lunch or read the paper. Such acts constitute reasonable necessary acts of *341 personal comfort that are incident to her employment. In addition, it is not unreasonable for plaintiff to arrive well in advance to perform such functions. Case law from around the country creates a reasonable span of time before and after work which is included within the work day for the purposes of worker's compensation. Under the facts of this case, 50 to 55 minutes is not unreasonable. She arrived at the parking lot with the express purpose of parking and proceeding directly into Sears to wait for the beginning of her shift. There is no evidence of any other personal purpose not connected with employment. The facts lead only to the conclusion that when plaintiff arrived at Sears she was contemplating the upcoming work day and was in the course of her employment when she was attacked.
Id. at 789.
Other cases have held that arrival before work in a time span between thirty to sixty minutes was not so unreasonable as to take the injuries outside the "course of employment" prong. See, e.g., Winn Dixie Stores, Inc. v. Akin, 533 So.2d 829, 830 (Fla.Dist.Ct. App.1988) (thirty minutes before work); Christman v. Industrial Comm'n, 159 Ill. App.3d 479, 111 Ill.Dec. 415, 417, 512 N.E.2d 804, 806 (1987) (one hour before work); Serean v. Kaiser Aluminum & Chem. Corp., 277 So.2d 732, 734 (La.Ct.App.1973) (forty-five minutes before work); Smith v. General Motors Assembly Div., 18 Md.App. 478, 307 A.2d 725, 727 (1973) (thirty to forty minutes before work); Horan's Case, 346 Mass. 128, 190 N.E.2d 399, 400-01 (1963) (thirty to thirty-five minutes before work); Starrett, 488 N.W.2d at 274 (within one hour before work); Montanaro v. Guild Metal Prods., Inc., 108 R.I. 362, 275 A.2d 634, 636 (1971) (one hour); Carter, 833 S.W.2d at 495-96 (fifty minutes).
Christine was in the parking lot fifty minutes before her shift. We hold as a matter of law this was reasonable and thus within the course of employment, given the size of the Amana Refrigeration employee population and the desirability of securing a convenient parking place. From the employer's perspective, where parking is troublesome and an inconvenient parking space may make an employee tardy, early arrival should be encouraged. See Barnes v. Stokes, 233 Va. 249, 355 S.E.2d 330, 332 (1987) ("[A] parking area adjacent to a work site is a valuable fringe benefit for employees. Because that convenience reduces tardiness and enhances the desirability of a particular workplace, such a facility also benefits the employer."); accord Brown, 165 S.E.2d at 398; see also Montanaro, 275 A.2d at 636 (holding that period of employment expands if employer derives benefit from employee's activities during interval before work begins).
b. Sole mission. As to her "sole mission" contention, Christine relies heavily on Fouts v. Anderson, 219 Va. 666, 250 S.E.2d 746 (1979). We can easily distinguish Fouts. The plaintiff there left the parking lot after work, remembered he had agreed to meet a co-employee, returned to the lot, and was involved in a collision in the lot. Fouts, 250 S.E.2d at 747. The court held there was no connection between plaintiff's work and his injury: the plaintiff had completed his work when he left the company's parking lot and his reentry into the lot was not related to or in any way connected with his employment. Id. at 748. He incurred the risk of injury while he was "solely on a mission for his own convenience," and for that reason the injury "did not [arise] `in the course of his employment.'" Id.
In contrast, Christine was on the employer's premises and had already picked up the videotape when the collision happened. She was there to go to work. She was therefore not solely on a mission for her own convenience. Picking up the videotape was incidental to her main mission: presenting herself for work in a timely manner. See Brooks, 58 Ill.Dec. at 536, 430 N.E.2d at 568 ("An accidental injury is received in the course of employment at a place where the employee may reasonably be in the performance of his duties and while he is fulfilling those duties or engaged in something incidental thereto.") (emphasis added); see also Winn Dixie Stores, 533 So.2d at 830 ("Arriving thirty minutes early for punctuality's sake is not unreasonable.").
We have already touched on Christine's intent to get a good parking space and concluded *342 this was for the mutual benefit of both Christine and her employer. We have also touched on her action in picking up the videotape and concluded this was incidental to her main purpose in arriving early.
As one court put it,
The parking lot cases hold that an employee who has the use of the premises for parking must necessarily have a reasonable margin of time and space in going and coming between his work and his automobile. They do not state what he may do in this time and space. We think that he may do those normal things that men do during any other work-free period, and unless his action is so wholly unreasonable as to support an inference that he abandoned the employment, he remains within the course of employment.
North Am. Rockwell Corp., 9 Cal.App.3d at 159-60, 87 Cal.Rptr. 774 (affirming a workers' compensation award to an employee who sustained injury when he was struck by the automobile of a co-employee in a parking lot provided for the use of employees as they were assisting a third employee to start his stalled vehicle).
The time that Christine had before her shift began was equivalent to a work-free period. Retrieving the videotape and picking a parking spot close to the building are surely normal and reasonable and would not support an inference that she had abandoned her employment. Arriving early to secure a convenient parking spot is a matter of personal convenience and not unlike arriving early to read a newspaper or to have a cup of coffee in the break room. Rose, 668 A.2d at 789 (reading a newspaper); Carter, 833 S.W.2d at 493, 495 (going to break room to have coffee); cf. Frost, 299 N.W.2d at 649 (arriving early for a birthday breakfast). We must, as a matter of law, conclude Christine was within the course of her employment even though she used her free time to pick up the videotape and find a good parking spot.

VI. Disposition.

Because there existed no genuine issue of material fact as to whether Christine was injured in the course of her employment, the district court correctly ruled that workers' compensation covered her injuries. Workers' compensation is an exclusive remedy which, if applicable, deprives the district court of subject matter jurisdiction. Thus, the district court had no choice but to dismiss Christine's negligence action even though Batchelder had not raised exclusivity of the workers' compensation act as an affirmative defense.
Finding no error, we affirm.
AFFIRMED.
