Class EventFactHandle

    • Constructor Detail

      • EventFactHandle

        public EventFactHandle()
      • EventFactHandle

        public EventFactHandle​(long id,
                               java.lang.Object object,
                               long recency,
                               long timestamp,
                               long duration,
                               WorkingMemoryEntryPoint wmEntryPoint)
        Creates a new event fact handle.
        Parameters:
        id - this event fact handle ID
        object - the event object encapsulated in this event fact handle
        recency - the recency of this event fact handle
        timestamp - the timestamp of the occurrence of this event
        duration - the duration of this event. May be 0 (zero) in case this is a primitive event.
      • EventFactHandle

        protected EventFactHandle​(long id,
                                  int identityHashCode,
                                  java.lang.Object object,
                                  long recency,
                                  long timestamp,
                                  long duration,
                                  EntryPointId entryPointId)
    • Method Detail

      • isEvent

        public boolean isEvent()
        Always returns true, since the EventFactHandle is only used for Events, and not for regular Facts
        Specified by:
        isEvent in interface InternalFactHandle
        Overrides:
        isEvent in class DefaultFactHandle
        Returns:
      • getStartTimestamp

        public long getStartTimestamp()
        Returns the timestamp of the occurrence of this event.
        Returns:
      • getDuration

        public long getDuration()
        Returns the duration of this event. In case this is a primitive event, returns 0 (zero).
        Returns:
      • getEndTimestamp

        public long getEndTimestamp()
        Returns the end timestamp for this event. This is the same as: startTimestamp + duration
        Returns:
      • expirePartition

        public boolean expirePartition()
      • setExpired

        public void setExpired​(boolean expired)
      • setPendingRemoveFromStore

        public void setPendingRemoveFromStore​(boolean pendingRemove)
      • getActivationsCount

        public long getActivationsCount()
      • setActivationsCount

        public void setActivationsCount​(long activationsCount)
      • increaseActivationsCount

        public void increaseActivationsCount()
      • decreaseActivationsCount

        public void decreaseActivationsCount()
      • increaseOtnCount

        public void increaseOtnCount()
      • decreaseOtnCount

        public void decreaseOtnCount()
      • getOtnCount

        public int getOtnCount()
      • setOtnCount

        public void setOtnCount​(int otnCount)
      • addJob

        public void addJob​(JobHandle job)
      • removeJob

        public void removeJob​(JobHandle job)
      • unscheduleAllJobs

        public void unscheduleAllJobs​(ReteEvaluator reteEvaluator)