Uploaded image for project: 'JBRULES'
  1. JBRULES
  2. JBRULES-615

Declared imports should override the default java.lang.* imports

This issue belongs to an archived project. You can view it, but you can't modify it. Learn more

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Minor
    • 3.0.6, 3.1-m1
    • 3.0.5
    • None
    • None

    Description

      The use of a java.lang.* Class in the LHS of a rule causes Exception in thread "XXX" java.lang.Error: Unable to find unambiguously defined class 'XXX' errors when rules are loaded for parsing. Workaround is to use fully qualified Class name in LHS. For example:-

      package some.rules

      import a.package.name.Process

      rule "A rule"
      when
      p:Process( )
      then
      System.out.println(p.toString());
      end

      JIRA raised at the request of Mark Proctor:-

      From: rules-users-bounces@lists.jboss.org
      rules-users-bounces@lists.jboss.org On Behalf Of Mark Proctor
      Sent: 20 January 2007 13:50
      To: Rules Users List
      Subject: Re: [rules-users] Exception in thread "main" java.lang.Error:
      Unableto find unambiguously defined class

      Actually this is also a bug, if you declare something as an import, it
      should override the default java.lang.* imports - can you open a JIRA
      for this bug.

      Thanks

      Mark

      Attachments

        Activity

          People

            etirelli@redhat.com Edson Tirelli
            manstis1 manstis1 (Inactive)
            Archiver:
            rhn-support-ceverson Clark Everson

            Dates

              Created:
              Updated:
              Resolved:
              Archived:

              PagerDuty