Parses <EventPort>

        @param node: Node containing the <EventPort> element
        @type node: xml.etree.Element

def parse_event_port(self, node):
        """
        Parses <EventPort>

        @param node: Node containing the <EventPort> element
        @type node: xml.etree.Element
        """

        if 'name' in node.lattrib:
            name = node.lattrib['name']
        else:
            self.raise_error(('<EventPort> must specify a name.'))

        if 'direction' in node.lattrib:
            direction = node.lattrib['direction']
        else:
            self.raise_error("Event port '{0}' must specify a direction.")

        direction = direction.lower()
        if direction != 'in' and direction != 'out':
            self.raise_error(('Event port direction must be \'in\' '
                              'or \'out\''))

        description = node.lattrib.get('description', '')
        
        self.current_component_type.add_event_port(EventPort(name, direction, description))