Class MapMarkerProp

    • Field Detail


        public static final java.lang.String PN_LABEL_CHAR
        Property name: label character "ch".
        See Also:
        Constant Field Values

        public static final java.lang.String PN_LATITUDE
        Property name: latitude "lat".
        See Also:
        Constant Field Values

        public static final java.lang.String PN_LONGITUDE
        Property name: longitude "lng".
        See Also:
        Constant Field Values
    • Constructor Detail

      • MapMarkerProp

        public MapMarkerProp()
        Constructor of the marker property without name.
      • MapMarkerProp

        public MapMarkerProp​(Atom atom)
        Constructor of the marker property.
        atom - The name of this property.
    • Method Detail

      • setContentItem

        public void setContentItem​(IContentData<?> itemData)
        Returns the content item that has initialized this property container.
        Specified by:
        setContentItem in interface IContentItem
        itemData - Sets the content item that has updated this property container.
      • getItemsContainer

        public MapMarkers getItemsContainer()
        Returns the container for the items.
        Specified by:
        getItemsContainer in interface IContentItem
        The container, or null if not found.
      • getContentItem

        public MapMarker getContentItem​(boolean createIfNotPresent)
        Returns the content item that has initialized this property container. If it has not been initialized, it will be initialized with this call if the flag createIfNotPresent is true.
        Specified by:
        getContentItem in interface IContentItem
        createIfNotPresent - Creates the content data if it doesn't exist if true.
        The content item, null if not previously initialized if createIfNotPresent is false.
      • getDeviceType

        public final int getDeviceType()
        Gets the device type: -1=mobile, 0=both, 1=desktop.
        Specified by:
        getDeviceType in interface IUIComp
      • getApproximateSize

        public Size getApproximateSize()
        Returns the size of the component in pixels. The size is a calculation and does not exactly reflect the real size that may be different due to additional styles not taken into account by this method. The size is calculated from the font of the component and default or defined values (such as character length or number of lines for text area).
        Specified by:
        getApproximateSize in class UIComp
        The size of the component.
        java.lang.IllegalStateException - If called outside of the Designer, e.g. from the Server.
      • getMarkers

        public MapMarkers getMarkers()
        Gets the map markers container.
        The map markers container, or null if marker is orphaned.
      • getMap

        public UIMap getMap()
        Gets the map associated with the marker.
        The map, or null if marker or markers container is orphaned.
      • onRemoteEvent

        public void onRemoteEvent​(RemoteEvent event)
        Called when a remote property event should be processed by this property.
        Specified by:
        onRemoteEvent in interface IGProp<GProp<?>[]>
        onRemoteEvent in class UIComp
        event - The remote event.
      • addMappings

        protected void addMappings​(VSMappings mappings,
                                   VSComponent vsStateFocus)
        Gets the mappings of a VirtualSpace to the panel components.

        The default is to find the relative references to VS and add those references. Override to provide other functionality.

        addMappings in class UIComp
        mappings - The mappings instance to fill in.
        vsStateFocus - Do not go past this component when going up in the parent tree, null for none.
      • triggerRemoteSelectionEvent

        protected void triggerRemoteSelectionEvent​(boolean isSelected)
        Sends the selection property to the connected clients.
        isSelected -
      • isUnselected

        public boolean isUnselected()
        Returns if the selection is not set.
        Specified by:
        isUnselected in interface IUIBooleanSelectionComp
        true if unselected, false if selected.
      • isON

        public boolean isON()
        Returns if the selection is "on".
        Specified by:
        isON in interface IUIBooleanSelectionComp
        true if on, false if off.
      • isOFF

        public boolean isOFF()
        Returns if the selection is "off".
        Specified by:
        isOFF in interface IUIBooleanSelectionComp
        true if off, false if on.
      • setSelection

        public boolean setSelection​(boolean isSelected)
        Sets the selection.
        Specified by:
        setSelection in interface IUIBooleanSelectionComp
        isSelected - The selected state.
        true if state is changed, false for no change.
      • getSelectionPropAtom

        public Atom getSelectionPropAtom()
        Returns the selection property atom for verification of selection changes.

        This method is used by the framework in UIComp to fire selection events when the property value changes.

        Specified by:
        getSelectionPropAtom in interface IUISelectionComp
      • getSelectionListenerHandler

        public GenericListener<IUISelectionListener> getSelectionListenerHandler​(boolean doCreate)
        Returns the generic selection listener.
        Specified by:
        getSelectionListenerHandler in interface IUISelectionComp
        doCreate - Create the listener handler if it doesn't exist, false not to.
        The selection listener handler, or null if not created.
      • getSelectionType

        public int getSelectionType()
        Gets the selection type of the component.

        This method forwards the selection type to the map markers.

        Specified by:
        getSelectionType in interface IUISelectionComp
        A value indicating the selection capability as the SELECTION_TYPE_* values.
      • isSelectionTriStateBased

        public boolean isSelectionTriStateBased()
        Returns if the selection component supports index-based selection.
        Specified by:
        isSelectionTriStateBased in interface IUISelectionComp
      • isSelectionIndexBased

        public boolean isSelectionIndexBased()
        Returns if the selection component supports index-based selection.
        Specified by:
        isSelectionIndexBased in interface IUISelectionComp
      • isSelectionCellBased

        public boolean isSelectionCellBased()
        Returns if the selection component supports is cell based.
        Specified by:
        isSelectionCellBased in interface IUISelectionComp
      • getSelection

        public IUISelection getSelection()
        Gets the current selection of the component.
        Specified by:
        getSelection in interface IUISelectionComp
        The current selection of the component.
      • getOnUISelectionMethod

        public java.lang.reflect.Method getOnUISelectionMethod()
        Returns the method to use for onUISelection notifications that is attached to this selection component. The method name is not important, but must have the annotation and signature:

        @OnUISelection(name = "some/property")
        public void onUISelection(UISelectionEvent event)

        Specified by:
        getOnUISelectionMethod in interface IUISelectionComp
        The method, or null if none is registered.
      • onSelectionChanged

        protected void onSelectionChanged​(GEvent event)
        Method called when the selection of the component changed due to a property change (value changed, property added or removed).
        onSelectionChanged in class UIComp
        event - The event that causes the selection change.
      • onNotifySelectionChanged

        protected void onNotifySelectionChanged​(GEvent event)
        Method called when the selection of the component has changed and has been verified to be different from a previous selection. Subclasses can override this method to inform potential listeners.
        onNotifySelectionChanged in class UIComp
        event - The event that causes the selection change, COULD BE NULL!
      • onPrepare

        protected void onPrepare​(IAppOwner appOwner,
                                 IModuleOwner moduleOwner,
                                 boolean isPostCall,
                                 java.util.List<java.lang.Throwable> errors)
                          throws PropException
        Called when the application is being prepared. The order of onPrepare calls is always parent first, the children. The method is called twice, first time with isPostCall set to false, then a second time with true.
        onPrepare in class UIComp
        appOwner - The application owner.
        moduleOwner - The Module owner.
        isPostCall - Flag indicating this is a post-call.
        errors - A list of errors that occurred but did not cause an abort.
        PropException - For property errors during the application preparation to need to abort.