The REV Robotics Magnetic Limit Switch (REV-31-1462) is a three-sided digital hall effect switch. The three internal hall effect elements (one on top, two on the sides) are connected in parallel so if any one of them is triggered the sensor will report as triggered.
Hall effect sensors detect the presence of a magnetic fields. The REV Magnetic Limit Switch is an omnipolar momentary switch; it will trigger when there is sufficient field strength of either magnetic pole detected.
Check out our documentation of the Magnetic Limit Switch.