Class AbstractBalloon

    • Field Detail

      • alwaysOnTop

        protected boolean alwaysOnTop
      • pickEnabled

        protected boolean pickEnabled
      • delegateOwner

        protected java.lang.Object delegateOwner
      • text

        protected java.lang.String text
      • visible

        protected boolean visible
      • highlighted

        protected boolean highlighted
      • minActiveAltitude

        protected double minActiveAltitude
      • maxActiveAltitude

        protected double maxActiveAltitude
      • defaultAttributes

        protected static final BalloonAttributes defaultAttributes
        The attributes used if attributes are not specified.
    • Constructor Detail

      • AbstractBalloon

        protected AbstractBalloon()
        Create a balloon.
      • AbstractBalloon

        protected AbstractBalloon​(java.lang.String text)
        Create a balloon with text.
        Parameters:
        text - The balloon text.
    • Method Detail

      • isAlwaysOnTop

        public boolean isAlwaysOnTop()
        Is the balloon always on top?
        Specified by:
        isAlwaysOnTop in interface Balloon
        Returns:
        True if the balloon will always render above other items.
      • setAlwaysOnTop

        public void setAlwaysOnTop​(boolean alwaysOnTop)
        Set the balloon to always on top or not.
        Specified by:
        setAlwaysOnTop in interface Balloon
        Parameters:
        alwaysOnTop - True if the balloon should always render above other objects.
      • isPickEnabled

        public boolean isPickEnabled()
        Is the balloon enabled for picking?
        Specified by:
        isPickEnabled in interface Balloon
        Returns:
        True if the balloon can be picked, false if not.
      • setPickEnabled

        public void setPickEnabled​(boolean enable)
        Set the balloon to be pick enabled or not.
        Specified by:
        setPickEnabled in interface Balloon
        Parameters:
        enable - True if the balloon can be picked, false if not.
      • setText

        public void setText​(java.lang.String text)
        Set the balloon text.
        Specified by:
        setText in interface Balloon
        Parameters:
        text - New balloon text.
      • getDelegateOwner

        public java.lang.Object getDelegateOwner()
        Returns the delegate owner of the balloon. If non-null, the returned object replaces the balloon as the pickable object returned during picking. If null, the balloon itself is the pickable object returned during picking.
        Specified by:
        getDelegateOwner in interface Balloon
        Returns:
        the object used as the pickable object returned during picking, or null to indicate the the balloon is returned during picking.
      • setDelegateOwner

        public void setDelegateOwner​(java.lang.Object delegateOwner)
        Specifies the delegate owner of the balloon. If non-null, the delegate owner replaces the balloon as the pickable object returned during picking. If null, the balloon itself is the pickable object returned during picking.
        Specified by:
        setDelegateOwner in interface Balloon
        Parameters:
        delegateOwner - the object to use as the pickable object returned during picking, or null to return the balloon.
      • setAttributes

        public void setAttributes​(BalloonAttributes attributes)
        Set the "normal" balloon attributes.
        Specified by:
        setAttributes in interface Balloon
        Parameters:
        attributes - New attributes
      • setHighlightAttributes

        public void setHighlightAttributes​(BalloonAttributes highlightAttributes)
        Set the highlight attributes.
        Specified by:
        setHighlightAttributes in interface Balloon
        Parameters:
        highlightAttributes - Attributes to use when the balloon is highlighted.
      • determineActiveAttributes

        protected void determineActiveAttributes()
        Determines which attributes -- normal, highlight or default -- to use each frame.
      • getActiveAttributes

        protected BalloonAttributes getActiveAttributes()
        Get the active attributes, based on the highlight state.
        Returns:
        Highlight attributes if the balloon is highlighted, or normal attributes otherwise.
      • getTextDecoder

        public TextDecoder getTextDecoder()
        Get the text decoder that will process the balloon text.
        Specified by:
        getTextDecoder in interface Balloon
        Returns:
        Active text decoder.
      • setTextDecoder

        public void setTextDecoder​(TextDecoder decoder)
        Set a text decoder to process the balloon text.
        Specified by:
        setTextDecoder in interface Balloon
        Parameters:
        decoder - New decoder.
      • isHighlighted

        public boolean isHighlighted()
        Indicates whether to highlight the shape.
        Specified by:
        isHighlighted in interface Highlightable
        Returns:
        true to highlight the shape, otherwise false.
      • setHighlighted

        public void setHighlighted​(boolean highlighted)
        Specifies whether to highlight the shape.
        Specified by:
        setHighlighted in interface Highlightable
        Parameters:
        highlighted - true to highlight the shape, otherwise false.
      • isVisible

        public boolean isVisible()
        Get whether the annotation is visible and should be rendered.
        Specified by:
        isVisible in interface Balloon
        Returns:
        true if the annotation is visible and should be rendered.
      • setVisible

        public void setVisible​(boolean visible)
        Set whether the balloon is visible and should be rendered.
        Specified by:
        setVisible in interface Balloon
        Parameters:
        visible - true if the balloon is visible and should be rendered.