Class AbstractPerceptionCategory<G extends Gtu,​P extends Perception<G>>

    • Constructor Detail

      • AbstractPerceptionCategory

        public AbstractPerceptionCategory​(P perception)
        Construct a new AbstractPerceptionCategory.
        Parameters:
        perception - P; perception to which the new AbstractPerceptionCategory belongs
    • Method Detail

      • getPerception

        public P getPerception()
        Returns the connected perception.
        Returns:
        P; the connected perception
      • getGtu

        public G getGtu()
                 throws GtuException
        Returns the connected GTU.
        Returns:
        G; connected GTU
        Throws:
        GtuException - if the GTU has not been initialized
      • getCurrentTime

        public final Time getCurrentTime()
                                  throws GtuException
        Returns the current time.
        Returns:
        current time
        Throws:
        GtuException - if the GTU has not been initialized
      • getObjectOrNull

        protected final <T> T getObjectOrNull​(TimeStampedObject<T> object)
        Returns the object inside a time stamped object, or null if it's null.
        Type Parameters:
        T - type of time stamped object
        Parameters:
        object - TimeStampedObject<T>; time stamped object
        Returns:
        T; the object inside a time stamped object, or null if it's null