Uploaded image for project: 'WINDUP - Red Hat Application Migration Toolkit'
  1. WINDUP - Red Hat Application Migration Toolkit
  2. WINDUP-484

Create a file-type discovery mapping rule: Map.fileExtension(".*.xml").as(XmlFile.class)

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 2.0.0.Final
    • 2.0.0.Beta8
    • MTA CLI
    • None

      Map.fileExtension(".*.xml").as(XmlFile.class)
      lincolnthree
      11:28 jsightler: we could actually add a rule that configures file discovery types
      jsightler
      11:28 Yeah, that's probably a good idea
      lincolnthree
      11:28 jsightler: oh i misread you
      11:28 jsightler: yeah, probably a lot
      jsightler
      11:29 I like the idea of being able to add other xml types via a rule. That seems like a good general solution.
      11:29 I am sure we will run into other xml files with odd extensions in the future.
      lincolnthree
      11:29 jsightler: i wonder how to get that rule to execute at the right time in the pipeline
      11:29 jsightler: we don't currently support targeting individual rules at phases
      jsightler
      11:30 yeah, you'd have to have it exist very early on (Initialization or something)
      11:30 Either that or just initializing the condition could do it
      11:30 (kind of like the way typeinterestfactory works)
      lincolnthree
      11:31 jsightler: right, that's kind of what i was thinking, but that makes it a little kludgy
      11:31 jsightler: though it could just be a rule rule
      11:31 jsightler: that might work
      jsightler
      11:31 a rule rule?
      lincolnthree
      11:31 .addRule(Map.fileExtension(".*.xml").as(XmlFile.class))
      jsightler
      11:32 Ah, yeah, that looks pretty good.
      lincolnthree
      11:32 jsightler: not a builder-rule
      11:32 jsightler: that could actually help to generalize some of our file discovery
      jsightler
      11:32 yeah
      lincolnthree
      11:34 jsightler: that rule can "fake" being a rule
      11:34 jsightler: aka, it would just be a static actor
      11:34 jsightler: but that would make it clearer that it's not going to work with parameters
      11:35 jsightler: or be possible to use as a condition or operation
      

            lincolnthree Lincoln Baxter III (Inactive)
            lincolnthree Lincoln Baxter III (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: