Class MapMarker
- All Implemented Interfaces:
- IContentData<MapMarkerProp>
Markers can be placed on a map by means of either API directory against the map component or in the VirtualSpace by means of connections to the map.
A marker that is enabled and not read-only can be dragged on a map if the markers settings allows draggable markers.
- Author:
- Christopher Mindus
- Constructor SummaryConstructors
- Method SummaryModifier and TypeMethodDescription- void- addMappings- (VSMappings mappings, String uiRef, MapMarkerProp item) Adds the mappings of a VirtualSpace to the panel components.Returns the property that was used to update this data content.- char- getLabel()Gets the marker label character.Gets the marker label character text.- doubleGets the latitude of the marker.- doubleGets the longitude of the marker.Gets the map markers container.Gets the marker tooltip text.- getVSRow()Gets the associated VSRow for this item.- void- initialize- (MapMarkerProp item) Initializes the item property from the content data.- booleanGets the enabled state.- booleanGets the read-only state.- booleanGets the selection state of the item.- booleanGets the visibility state.- void- refreshFromVS- (int[] columns) Refreshes contents from VirtualSpace.- boolean- setEnabled- (boolean newState) Sets the enabled state.- boolean- setLabel- (char ch) Sets the marker label character.- boolean- setLabelChar- (PlainKString text) Sets the marker label character.- boolean- setLatitude- (double latitude) Sets the latitude of the marker.- boolean- setLongitude- (double longitude) Sets the longitude of the marker.- boolean- setReadOnly- (boolean newState) Sets the read-only state.- setSelection- (boolean on) Sets the selection state of an item.- setSelectionInternal- (boolean on) Internal method to sets the selection state of an item.- boolean- setTooltipText- (PlainKString text) Sets the marker tooltip text.- boolean- setVisible- (boolean newState) Sets the visibility state.- voidToggle the selected state of the map marker.- toString()Returns a String representation of the marker.
- Constructor Details- MapMarkerpublic MapMarker()Constructor for API.
- MapMarkerConstructor for VS-connected content provider.
 
- Method Details- refreshFromVSpublic void refreshFromVS- (int[] columns) Refreshes contents from VirtualSpace.- Specified by:
- refreshFromVSin interface- IContentData<MapMarkerProp>
- Parameters:
- columns- The connected table columns.
 
- getVSRowGets the associated VSRow for this item.- Specified by:
- getVSRowin interface- IContentData<MapMarkerProp>
- Returns:
- The row, or null if not associated with VirtualSpace.
 
- getItemPropReturns the property that was used to update this data content.- Specified by:
- getItemPropin interface- IContentData<MapMarkerProp>
- Returns:
- The property, or null if none is assigned.
 
- getMarkersGets the map markers container.- Returns:
- The container, or null if not yet associated.
 
- initializeInitializes the item property from the content data.- Specified by:
- initializein interface- IContentData<MapMarkerProp>
- Parameters:
- item- The item.
 
- toStringReturns a String representation of the marker.
- getTooltipTextGets the marker tooltip text.- Returns:
- The tooltip text as a plain KString, null if not set.
 
- setTooltipTextSets the marker tooltip text.- Parameters:
- text- The text, or null for none.
- Returns:
- true for changed, false for no change.
 
- getLabelpublic char getLabel()Gets the marker label character.- Returns:
- The label character, '\0' if not set.
 
- getLabelCharGets the marker label character text.- Returns:
- The label character, null if not set.
 
- setLabelpublic boolean setLabel- (char ch) Sets the marker label character.- Parameters:
- ch- The character, or '\0' for none.
- Returns:
- true for changed, false for no change.
 
- setLabelCharSets the marker label character.- Parameters:
- text- The text, or null for none. Only the first character is used.
- Returns:
- true for changed, false for no change.
 
- getLatitudepublic double getLatitude()Gets the latitude of the marker.- Returns:
- The latitude -90 to 90, initialized by default to zero.
 
- setLatitudepublic boolean setLatitude- (double latitude) Sets the latitude of the marker.- For reference, the Equator has a latitude of 0°, the North pole has a latitude of 90° north (written 90° N or +90°), and the South pole has a latitude of -90°. Prime Meridian has a longitude of 0° that goes through Greenwich, England. - Parameters:
- latitude- The latitude.
- Returns:
- true if changed, false for no change.
- Throws:
- IllegalArgumentException- If the latitude is not -90 to 90 degrees.
 
- getLongitudepublic double getLongitude()Gets the longitude of the marker.- Returns:
- The longitude -180 to 180, initialized by default to zero.
 
- setLongitudepublic boolean setLongitude- (double longitude) Sets the longitude of the marker.- Longitude is in the range -180 and +180 specifying the east-west position. For reference, the Equator has a latitude of 0°, the North pole has a latitude of 90° north (written 90° N or +90°), and the South pole has a latitude of -90°. Prime Meridian has a longitude of 0° that goes through Greenwich, England. - Parameters:
- longitude- The longitude.
- Returns:
- true if changed, false for no change.
- Throws:
- IllegalArgumentException- If the longitude is not -180 to 180 degrees.
 
- isVisiblepublic boolean isVisible()Gets the visibility state.- This is the items individual state and does not take parent states into account. - Returns:
- true for visible, false for hidden.
 
- isEnabledpublic boolean isEnabled()Gets the enabled state.- This is the items individual state and does not take parent states into account. - Returns:
- true for enabled, false for disabled.
 
- isReadOnlypublic boolean isReadOnly()Gets the read-only state.- This is the items individual state and does not take parent states into account. - Returns:
- true for read-only, false otherwise.
 
- isSelectedpublic boolean isSelected()Gets the selection state of the item.- Specified by:
- isSelectedin interface- IContentData<MapMarkerProp>
- Returns:
- The selected state.
 
- setVisiblepublic boolean setVisible- (boolean newState) Sets the visibility state.- This is the items individual state and does not take parent states into account. - Parameters:
- newState- the new state: true for visible, false for hidden.
- Returns:
- true for changed state, false for no change.
 
- setEnabledpublic boolean setEnabled- (boolean newState) Sets the enabled state.- This is the items individual state and does not take parent states into account. - Parameters:
- newState- The new state: true for enabled, false for disabled.
 
- setReadOnlypublic boolean setReadOnly- (boolean newState) Sets the read-only state.- This is the items individual state and does not take parent states into account. - Parameters:
- newState- The new state: true for read-only, false otherwise.
 
- setSelectionSets the selection state of an item.- Specified by:
- setSelectionin interface- IContentData<MapMarkerProp>
- Parameters:
- on- The new selection state.
- Returns:
- null for success.
 
- setSelectionInternalInternal method to sets the selection state of an item. This method is not intended to be called as it is used by the framework and will not cause a callback or event notification of selection changes.- Specified by:
- setSelectionInternalin interface- IContentData<MapMarkerProp>
- Parameters:
- on- The new selection state.
- Returns:
- null for success, empty string for no change.
 
- toggleSelectionpublic void toggleSelection()Toggle the selected state of the map marker.
- addMappingsAdds 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. - Specified by:
- addMappingsin interface- IContentData<MapMarkerProp>
- Parameters:
- mappings- The mappings instance to fill in.
- uiRef- The reference.
- item- The item property.