Class XpathFileGeneratorAstFilter

    • Field Detail

      • MESSAGE_QUERY_MAP

        private static final java.util.Map<Violation,​java.lang.String> MESSAGE_QUERY_MAP
        Map from Violation objects to xpath queries.
      • tabWidth

        private int tabWidth
        The distance between tab stop position.
    • Method Detail

      • setTabWidth

        public void setTabWidth​(int tabWidth)
        Sets tab width.
        Parameters:
        tabWidth - the distance between tab stops
      • findCorrespondingXpathQuery

        public static java.lang.String findCorrespondingXpathQuery​(AuditEvent event)
        Returns xpath query corresponding to violation of the TreeWalkerAuditEvent object which points to the same AST element as specified AuditEvent object.
        Parameters:
        event - the AuditEvent object.
        Returns:
        returns corresponding xpath query
      • accept

        public boolean accept​(TreeWalkerAuditEvent event)
        Description copied from interface: TreeWalkerFilter
        Determines whether or not a filtered TreeWalkerAuditEvent is accepted.
        Specified by:
        accept in interface TreeWalkerFilter
        Parameters:
        event - the TreeWalkerAuditEvent to filter.
        Returns:
        true if the event is accepted.