A door is a hinged or otherwise movable barrier that allows ingress and egress into an "enclosure". The opening in the wall can be referred to as a "portal". A door's essential and primary purpose is to provide security by controlling access to the portal (doorway).