What role does an Ethernet layer 2 switch play in virtual local-area networks (VLAN)?