def parse(cls, element):
        """
        Create a new AltRecordID by parsing root.

        :param element: Element to be parsed into an AltRecordID.
        :raises exceptions.ParseError: If element is not a valid altRecordID.
        """
        if element.tag != cls.ALT_RECORD_ID_TAG:
            raise exceptions.ParseError(
                u"AltRecordID got unexpected tag {}; expected {}".format(
                    element.tag, cls.ALT_RECORD_ID_TAG
                )
            )

        return cls(element.text, id=element.get(u"ID"), type=element.get(u"TYPE"))