Details

      Description

      I compile a .drl file and save it as object in .drl.compiled file.
      Loading that file does not work if I use insert() or retract() facts that are of a type declared in the .drl file.
      The way to circumvent this is to use the full class name in the insert, like this:

      insert(new vcm.planner.lock.standard.PossibleSlotLock($ship, $chamber,
      $side, $schedule, $eta, $schedule.getTick(), "existing"));

      And cast the variable to the full class name, like this:

      rule "clean up possible slot lock, when no longer to schedule"
      when
      $p : PossibleSlotLock( $ship; )
      not ToScheduleLock( mover == $ship )
      then
      retract( (vcm.planner.lock.standard.PossibleSlotLock)$p );
      end

      This did work in 5.4.0.Final.

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                mfusco Mario Fusco
                Reporter:
                wasperen Willem van Asperen
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: