
930 P.2d 740 (1997)
Ann ASHWOOD and Richard Ashwood, Appellants,
v.
CLARK COUNTY, a Political Subdivision, Nevada State Horseman's Association, a Nevada Corporation, Southern Nevada Hunter Jumper Association, a Nevada Corporation, and Dixie Bennett and John Doe Bennett, Husband and Wife, Respondents.
No. 26902.
Supreme Court of Nevada.
January 3, 1997.
*741 Davidson & Myers, Las Vegas, Snyder & Wenner, Phoenix, AZ, for Appellants.
Edwards & Hale and Sharon Gwin Immerman, Las Vegas, for Respondent Clark County.
Beckley, Singleton, Jemison & List and Daniel F. Polsenberg, Las Vegas, for Horseman's Association and Bennett.

OPINION
SPRINGER, Justice.
This is an appeal from a summary judgment in favor of the respondents in a negligence action. The claimed negligence arouse out of an incident in which the injured plaintiff, appellant Ann Ashwood, injured her knee as she attempted to come to the assistance of a fallen horseback rider at Horseman's Park in Las Vegas. Ashwood was in the barn area of the park at the time she learned of the accident. Ashwood at first tried to reach the fallen rider by leaving the barn area through a nearby gate, but found that the gate was locked. There was another gate nearby, less than 150 feet from the locked gate; nevertheless, Ashwood sued Clark County and others claiming that they had a duty to keep the locked gate open and that breach of that duty was the cause of her injuries.
Because we are asked to rule on the correctness of the trial court's ruling that no duty was owed by any of the respondents to keep the gate unlocked, it will be necessary for us to relate the facts relating to Ashwood's claims in some detail. Because this case is before this court upon appeal of an award of summary judgment, the facts are related in the light most favorable to appellant. See Butler v. Bogdanovich, 101 Nev. 449, 451, 705 P.2d 662, 663 (1985).
On September 1, 1990, Ashwood and her family attended a horseshow at Horseman's Park in Las Vegas. The park is owned by defendant/respondent Clark County. On the date in question, the park was leased to defendant/respondent Nevada State Horseman's Association (NSHA), the sponsor of the event.
The park includes a barn area surrounded by a chain-link fence. There are several gateways through the fence, although on the night in question only the main gateway to the south remained unlocked. Ashwood was assigned a stall in Barn "C" near the western fence line. While in the barn area, she heard the sounds of a runaway horse and cries for help. She observed a rider lying on the ground in an open area to the west of the barn area and on the other side of the fence.
Ashwood, who is trained in CPR, believed that the fallen rider needed immediate assistance and ran toward the nearest gate in the barn area fence to assist the injured rider. The nearest gate was the west gate, which was locked. Concerned that the fallen rider might be unconscious and not breathing, Ashwood attempted to climb over the chain-link fence, rather than run through the open main gate approximately 150 feet away. Unfortunately, Ashwood fell in the process and sustained a severe injury to her knee.
Ashwood brought suit against Clark County, the NSHA, and the manager of the barn area, Dixie Bennett (referred to collectively as "Respondents"). Ashwood claims that Respondents are liable in negligence for failing to keep the west gate unlocked. After substantial discovery, Respondents moved *742 for summary judgment. Ashwood filed a response to Respondents' motion and filed a cross-motion for partial summary judgment on the issue of duty.
In support of her motion for summary judgment, Ashwood presented the district court with the affidavit of Dan Cashdan (Cashdan), a registered civil engineer employed by the State of Nevada. Cashdan is thoroughly familiar with the Uniform Building Code ("U.B.C.") in effect in Clark County at the time of the incident, and his duties include reviewing building plans for compliance with the Building Code. Cashdan testified that the Building Code required the west gate be operable from inside the barn area. According to Cashdan, the padlocked west gate was a "clear violation" of the Building Code and a danger to public safety.
Ashwood also supported her motion with the affidavit of Drusilla E. Malavase (Malavase), an expert in equestrian training and safety for the past forty years and an organizer of horseshows. Malavase testified that Respondents' conduct was below the national standard of care, which "mandates that gates shall not be locked during the show and while the public is present." According to Malavase:
It is a known risk of and a common occurrence at horseshows for horses to behave erratically and endanger people in the area. This is especially true in a barn area where many horses congregate. It is highly foreseeable that an emergency will occur requiring people to exit the barn area quickly. In addition, to avoid the hazard of panic which can occur in these emergency situations, it is essential that exits in the barn area remain open and usable. By having the gate locked every person in the barn area was placed at risk and in danger. In so doing, the NSHA clearly fell below the standard of care of a reasonable person or group conducting a horseshow like the Labor Day Show.
Ashwood also presented the district court with the lease agreement between NSHA and Clark County, under which NSHA was obligated to comply with all laws and ordinances of the State of Nevada and Clark County. The lease agreement provided, among other things, that:
[N]o portion of the sidewalks, entries, passages, elevators, ramps, stairways, or access to public utilities of said buildings or grounds shall be obstructed or used for any purpose other than for ingress and egress to and from the premises.
Finally, Ashwood presented evidence that, at past horseshows, people had climbed over fences to rescue fallen riders.
On January 20, 1994, the district court granted Respondents' motion for summary judgment and denied Ashwood's cross-motion for partial summary judgment. On February 2, 1994, the district court entered judgment in favor of Respondents. Ashwood appealed.
Ashwood contends that the district court erred in granting summary judgment because there are material facts remaining to be tried and that, therefore, respondents were not entitled to judgment as a matter of law.
The first question raised by appellant Ashwood is whether, as a matter of law, the trial court erred in ruling that no duty was owed to her to keep the gate in question unlocked. In this regard Ashwood claims that respondents owed her a common law duty, that respondents were guilty of negligence per se, and that respondents owed her a contractual duty to keep the west gate unlocked. We consider each of these claims in turn.

Common Law Duty
It is the courts and not juries that have the ultimate responsibility of defining duty in relation to particular circumstances and to define the legal standard of reasonable conduct "in the light of the apparent risk." Merluzzi v. Larson, 96 Nev. 409, 412-13, 610 P.2d 739, 742 (1980) (quoting W. Prosser, Law of Torts, § 53 at 324 (4th ed.1971) (emphasis added)), overruled in part on other grounds, Smith v. Clough, 106 Nev. 568, 570 n. 2, 796 P.2d 592 (1990). By defining the scope of duty in negligence cases that come before them, the courts are making a vital "expression of the aggregate of those policy considerations which cause the law to *743 conclude that protection is owed." Merluzzi, 96 Nev. at 409, 610 P.2d at 742.
Ashwood presents two arguments on the duty question. First, she argues that there was a specific duty to keep the west gate unlocked because it was foreseeable that in an emergency she would need to use the padlocked gate to exit the barn area. Ashwood also argues that the respondents should have foreseen that during an emergency people would attempt to exit the barn area by climbing the fence if the gate were locked.
Foreseeability of harm is, of course, a predicate to establishing the element of duty. Id. at 414, 610 P.2d at 742; and respondents contend that a fallen rider in another part of the park is not the kind of foreseeable emergency that would give rise to a duty, enforceable by Ashwood, to keep the west gate unlocked. Respondents emphasize the unquestioned fact that there was an alternate safe means for Ashwood to carry out the intended rescue, namely, by going through the other, unlocked main gate that was less than 150 feet away. Respondents argue that there was no duty to provide the shortest or quickest route to any area of the horseshow grounds.
Ashwood has presented no evidence to suggest that the main gate, located 150 feet away from the locked gate, would have been inadequate to effect the intended rescue. Ashwood did not contend that she was physically incapable of traversing the additional distance nor that going to the open gate would have put her in personal danger or unacceptably delayed her attempted rescue. The exigent circumstances presented by the fallen rider did not constitute the kind of emergency alluded to by Ashwood's own expertssuch as a fire, panic, or stampede where an alternative means of egress may not have been reasonably available and where the immediacy of the danger combined with the inability to use the locked gate might have necessitated an attempt to scale the fence rather than to proceed to the unlocked gate. Under the circumstances, we agree with Respondents that this case really boils down to whether there existed a duty to provide Ashwood the shortest or quickest route from one area of the park to another. We conclude that there was no such duty. Accord Nicoletti v. Westcor, Inc., 131 Ariz. 140, 639 P.2d 330, 333 (1982) ("The landowner has a duty to provide a reasonably safe means of ingress and egress for those who enter onto the land.... The landowner, however, does not have to provide the shortest route to any destination."); Harris v. Union Stock Yard & Transit Co. of Chicago, 29 Ill.App.3d 1072, 331 N.E.2d 182, 188 (1975) (landowner owes invitee a duty to provide a reasonably safe means of ingress and egress, but not necessarily the shortest route to the invitee's destination).[1]
In light of the particular risk present in this case, Respondents' common law duty of reasonable care did not give rise to a specific duty to keep the west gate unlocked.

Negligence per se
Ashwood also contends that a duty to keep the west gate unlocked arose under the Clark County Building Code (the Code).[2] In response, Respondents first argue that the sections of the Code cited by Ashwood are not applicable either to the barn area or to the area surrounding the fence. Second, Respondents argue that, even if Respondents did violate the Code, the violations do not amount to negligence per se.
*744 A violation of statute establishes the duty and breach elements of negligence only if the injured party belongs to the class of persons that the statute was intended to protect, and the injury is of the type against which the statute was intended to protect. Sagebrush Ltd. v. Carson City, 99 Nev. 204, 208, 660 P.2d 1013, 1015 (1983).
Ashwood contends that the Code prohibits Respondents from padlocking the west gate while the public is present. Ashwood's contention depends upon the barn area being a "Group A Occupancy" under U.B.C. section 601 and the west gate being a required "exit." Exit doors in a Group A Occupancy are not to be latched or locked except with "panic hardware," a latching device that allows egress from the structure in an emergency. See U.B.C. § 3317(d). We are not convinced that the Horseman's Park barn area is a "Group A Occupancy," nor are we convinced that the west gate is a required exit; we need not decide this issue, however, because even if locking the west gate was a violation of section 3317(d), the violation would not be negligence per se in this case.
Ashwood argues that the Code is a "safety enactment." As discussed above, however, Ashwood herself was never in any danger; she was simply in a hurry to get from one part of horseman's park to another and chose, unwisely it turns out, to climb the fence rather than exiting through the open south gate. Clearly, the Code was not intended to ensure good samaritans the shortest route from one part of a public facility to another. Under the circumstances, we conclude as a matter of law that Ashwood is not a member of the class of persons the "panic hardware" provision of the building code was meant to protect. Accordingly, even if the Code was violated, the violation was not negligence per se and did not establish a duty owed to Ashwood to keep the west gate unlocked.[3]

Contractual duty
Ashwood also contends that Respondents owed her a duty to keep the gate unlocked under the lease agreement for Horseman's Park. According to Ashwood, a duty to keep the gate unlockedenforceable in tortmay be inferred from the contractual obligations between Respondents. The Horseman's Park lease between NSHA and Clark County contains several clauses that Ashwood describes as "safety precautions." For example, the lease provides:
Lessee agrees that no portion of the entries, passages, elevators, ramps, stairways,... shall be obstructed or used for any purpose other than for ingress or egress to and from the premises.
....
Lessee expressly agrees to observe all applicable safety procedures to insure that animals, as well as spectators, are not exposed to unsafe operational conditions.
According to Ashwood, these provisions of the contract create a specific duty in Respondents to keep the west gate unlocked.
Ashwood cites Granite Construction Co. v. Rhyne, 107 Nev. 651, 817 P.2d 711 (1991), and Baroco v. Araserv, Inc., 621 F.2d 189 (5th Cir.1980). In Granite Construction, we recognized that a contractor owed a duty to a driver injured in a collision with a bull arising out of a contract to furnish protective fencing that would prevent livestock from straying upon the highway. Similarly, in Baroco, the United States Court of Appeals *745 for the Fifth Circuit recognized that a contractor owed a duty to a drowned swimmer arising out of a contract to provide lifeguards and lifesaving equipment at a beach. Respondents argue that the above-cited cases are distinguishable. We agree.
In both Granite Construction and Baroco, the plaintiff was clearly among the class of persons the contract was intended to protect (drivers on the highway and swimmers at the beach, respectively) and the injury sustained by the plaintiff was precisely the kind of harm that the contract was intended to obviate (hitting livestock wandering onto the highway and drowning in the water). In the present case, on the other hand, the contractual "safety precautions" in the Horseman's Park lease were, like the building code provisions, clearly intended to protect visitors who might otherwise be unable to escape a dangerous situation within an area of the park or who might otherwise be injured trying to escape such a dangerous situation because an obstruction blocked the way. As previously stated, Ashwood herself was never in any danger, and a safe and adequate means of exiting the barn area was readily available to her. We therefore conclude that, for the same reason that the statutory safety enactments of the building code could not have given rise to a duty to keep the west gate unlocked in this case, the contractual "safety precautions" of the Horseman's Park lease cannot have given rise to a duty to keep the west gate unlocked.

CONCLUSION
Neither the common law, Clark County ordinances, nor the Horseman's Park lease agreement imposed upon Respondents a duty owing to Ashwood to keep the west gate unlocked; we conclude, therefore, that Respondents have negated an essential element of Ashwood's case. We hold, accordingly, that the district court did not err in entering summary judgment against Ashwood. See Perez v. Las Vegas Med. Ctr., 107 Nev. 1, 4, 805 P.2d 589, 591 (1991). The judgment of the district court is affirmed.
STEFFEN, C.J., and YOUNG, J., concur.
ROSE and SHEARING, JJ., dissent.
ROSE, Justice, with whom SHEARING, Justice, joins, dissenting:
I dissent from the majority's affirmance of the district court's judgment against the Ashwoods because questions of material fact remain, and therefore, the district court erred in awarding summary judgment against the Ashwoods in their negligence cause of action.
As to the question of what common law duty respondents owed to Ann Ashwood, in Moody v. Manny's Auto Repair, 110 Nev. 320, 333, 871 P.2d 935, 943 (1994), we held "that an owner or occupier of land should be held to the general duty of reasonable care when another is injured on that land," and that "determinations of liability should primarily depend upon whether the owner or occupier of land acted reasonably under the circumstances." The majority concluded that respondent's duty of reasonable care did not encompass "a specific duty to keep the west gate unlocked." This conclusion is erroneous because it is beyond the province of the district court or this court to make a determination as to whether the condition of respondents' gate falls within the landowner's duty to use reasonable care.
We have repeatedly noted that "`[c]ourts are reluctant to grant summary judgment in negligence cases because foreseeability, duty, proximate cause and reasonableness usually are questions of fact for the jury....'" Van Cleave v. Kietz-Mill Minit Mart, 97 Nev. 414, 417, 633 P.2d 1220, 1222 (1981) (emphasis added). Although in Merluzzi v. Larson, 96 Nev. 409, 412-413, 610 P.2d 739, 742 (1980), overruled on other grounds by Smith v. Clough, 106 Nev. 568, 570 n. 2, 796 P.2d 592, 594 (1990), we said that "`duty' is only an expression of the aggregate of those policy considerations which cause the law to conclude that protection is owed," we have also concluded that summary judgment is precluded where genuine issues of fact pertaining to a defendant's duty have been raised. See State ex rel. Dep't of Transp. v. Central Telephone, 107 Nev. 898, 901, 822 P.2d 1108, 1109 (1991) (holding summary judgment inappropriate where genuine issue of material fact remains as to whether respondent *746 had a duty to maintain a right of way in a safe condition).
In this case, the Ashwoods have presented sufficient evidence to survive summary judgment on the issue of respondents' duty of care. The majority recognizes that the district court may not pass on the credibility of affidavits and must accept the Ashwoods' statements as true. Sawyer v. Sugarless Shops, 106 Nev. 265, 267, 792 P.2d 14, 15 (1990). However, the opinion proceeds to reject the veracity of the Ashwoods' expert, Dan Cashdan, whose affidavit stated that the barn area where the accident occurred was a "Group A" classification. A "Group A" classification would have required the west gate to remain unlocked. Cashdan further concluded, based upon his experience with the U.B.C. as a State-employed civil engineer, that there was a duty to keep the west gate unlocked while Horseman's Park was being used by the public.
Nonetheless, the majority states that it is not convinced that the barn area is a "Group A Occupancy," nor is it convinced that the west gate is a "required exit." Under our jurisprudence, I do not believe that the Ashwoods bear the burden of convincing this court of these facts, since Cashdan's affidavit should have been deemed presumptively credible on summary judgment review by the district court. In past cases, this court has reversed a district court's order granting summary judgment where the record contains conflicting evidence concerning a defendant's duty of care. Harry v. Smith, 111 Nev. 528, 534, 893 P.2d 372, 375 (1995). I conclude that it was error for the district court to keep the resolution of such issues of fact from the jury, and the majority errs in affirming the lower court's erroneous decision.
In rejecting the Ashwoods' negligence per se and contractual duty arguments, the majority concludes that Ms. Ashwood was not a member of the class of persons meant to be protected by U.B.C. § 3317(d) or by the Horseman's Park lease contract between NSHA and Clark County. I conclude that whether or not the building code provision or the contractual "safety precautions" were meant to protect Ms. Ashwood were clearly questions of fact that should have been submitted to the jury.
For these reasons, I dissent from the majority's opinion affirming the district court's summary judgment against the Ashwoods on their claim of negligence.
NOTES
[1]  Finally, although we emphasize that this may be a case to which the maxim "danger invites rescue" is applicable, this is not a case where liability for a plaintiff's injuries may simply be imputed to defendants under the so-called "rescue doctrine." In order for that doctrine to apply, the defendants must first be liable for the injury to the victim being rescued. See Wagner v. International R.R. Co., 232 N.Y. 176, 133 N.E. 437, 438 (1921) (Cardozo, C.J.); Estate of Keck v. Blair, 71 Wash.App. 105, 856 P.2d 740 (1993). In this case, Ashwood has not alleged that Respondents were responsible for the fall of the rider for whom she was attempting rescue at the time of her own injury.
[2]  Clark County has, with certain express exceptions, adopted the U.B.C. by the International Conference of Building Officials (1994 edition) as the building code of Clark County. See Clark County Ordinance § 22.04.010. Accordingly, where applicable, citations are to the U.B.C.
[3]  We note in passing that there is some question as to whether the Clark County Building Code is an appropriate basis for application of the negligence per se doctrine. In Price v. Sinnott, we held that "proof of a deviation from an administrative regulation is only evidence of negligence; not negligence per se." 85 Nev. 600, 605, 460 P.2d 837, 840 (1969) (negligence per se not applicable to violation of safety rule promulgated by Nevada Liquified Petroleum Gas Board). We reasoned that, "This point of view best serves all interests since it accords appropriate dignity to administrative rules and concomitantly affords some leeway for those instances where the rule in issue may be arbitrary and its violation not necessarily unreasonable." Id. at 605, 460 P.2d at 840.

Although the Clark County Building Code is promulgated as a legislative ordinance, it appears, at least arguably, administrative in nature. Nevertheless, because this issue was neither raised before the district court, nor briefed on appeal, and because resolution of this issue would not affect the outcome of this case, we decline to consider this issue at the present time.
