Uploaded image for project: 'UIMA'
  1. UIMA
  2. UIMA-4556

MARKTABLE does not support ignoring whitespaces in the entries of the dictionary

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.3.1ruta
    • Fix Version/s: 2.3.1ruta
    • Component/s: Ruta
    • Labels:
      None

      Description

      MARKFAST's last parameter allows to specify whether whitespaces in the entries of the dictionary should be ignored. see docs

      MARKTABLE does not support this. One way to add this feature is to support it down to the scripting language. However, it would break backwards compatibility, since it would change the syntax from

      MARKTABLE(TypeExpression, NumberExpression, TableExpression 
                (,BooleanExpression, NumberExpression, 
                StringExpression, NumberExpression)? 
                (,StringExpression = NumberExpression)+)
      

      to

      MARKTABLE(TypeExpression, NumberExpression, TableExpression 
                (,BooleanExpression, NumberExpression, 
                StringExpression, NumberExpression, BooleanExpression)? 
                (,StringExpression = NumberExpression)+)
      

        Activity

        Show
        renaudrichardet Renaud Richardet added a comment - Fixed with http://svn.apache.org/viewvc?view=revision&revision=1696102
        Hide
        pkluegl Peter Klügl added a comment -

        Hi,

        first of all: thanks

        a few small things:

        I plan to prepare a release candidate for 2.3.1 soon. In order to be included in the issue report, the issue needs to specify the fixVersion. You can also assign yourself to the issue.

        The getter for the boolean value misses the match context. This is hardly ever useful for this action, but I had already problems with some rules because I did not set it in other langauge elements. It is used to allow feature matches as agruments for the action, like MARKTABLE(..., SomeAnnotation.booleanFeature, ...)

        It would not break compatibility if we make the argument optional:

        MARKTABLE(TypeExpression, NumberExpression, TableExpression 
                  (,BooleanExpression, NumberExpression, 
                  StringExpression, NumberExpression, BooleanExpression?)? 
                  (,StringExpression = NumberExpression)+)
        

        What are the use cases if the user cannot configure it using the language?

        Show
        pkluegl Peter Klügl added a comment - Hi, first of all: thanks a few small things: I plan to prepare a release candidate for 2.3.1 soon. In order to be included in the issue report, the issue needs to specify the fixVersion. You can also assign yourself to the issue. The getter for the boolean value misses the match context. This is hardly ever useful for this action, but I had already problems with some rules because I did not set it in other langauge elements. It is used to allow feature matches as agruments for the action, like MARKTABLE(..., SomeAnnotation.booleanFeature, ...) It would not break compatibility if we make the argument optional: MARKTABLE(TypeExpression, NumberExpression, TableExpression (,BooleanExpression, NumberExpression, StringExpression, NumberExpression, BooleanExpression?)? (,StringExpression = NumberExpression)+) What are the use cases if the user cannot configure it using the language?
        Hide
        pkluegl Peter Klügl added a comment -

        I added the fixVersion and the match context in the action

        Show
        pkluegl Peter Klügl added a comment - I added the fixVersion and the match context in the action
        Hide
        renaudrichardet Renaud Richardet added a comment -

        Thanks for adding the fixVersion, will do next time. Also, thanks for adding the match context.

        I tried to make the argument optional but did not make it work for antlr3 :-/

        API use cases are for an extension to handle ontology files, see https://github.com/sherlok/ruta-ontologies

        Show
        renaudrichardet Renaud Richardet added a comment - Thanks for adding the fixVersion, will do next time. Also, thanks for adding the match context. I tried to make the argument optional but did not make it work for antlr3 :-/ API use cases are for an extension to handle ontology files, see https://github.com/sherlok/ruta-ontologies
        Hide
        pkluegl Peter Klügl added a comment -

        Nice!!! I need to take a closer look... :-D

        Show
        pkluegl Peter Klügl added a comment - Nice!!! I need to take a closer look... :-D

          People

          • Assignee:
            Unassigned
            Reporter:
            renaudrichardet Renaud Richardet
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development