Java Code Examples for javafx.collections.FXCollections#observableMap()
The following examples show how to use
javafx.collections.FXCollections#observableMap() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: Participant.java From pikatimer with GNU General Public License v3.0 | 6 votes |
public static ObservableMap<String,String> getAvailableAttributes() { ObservableMap<String,String> attribMap = FXCollections.observableMap(new LinkedHashMap() ); attribMap.put("bib", "Bib"); attribMap.put("first", "First Name"); attribMap.put("middle", "Middle Name"); attribMap.put("last", "Last Name"); attribMap.put("age", "Age"); attribMap.put("birth","Birthday"); attribMap.put("sex-gender", "Sex"); attribMap.put("city", "City"); attribMap.put("state", "State"); attribMap.put("zip","Zip Code"); attribMap.put("country", "Country"); attribMap.put("status","Status"); attribMap.put("note","Note"); attribMap.put("email", "EMail"); // TODO: routine to add custom attributes based on db lookup return attribMap; }
Example 2
Source File: MapPropertyExTests.java From gef with Eclipse Public License 2.0 | 6 votes |
@Test public void changeListenerRegistrationAndDeregistration() { MapProperty<Integer, String> property = propertyProvider.get(); // register listener ChangeExpector<Integer, String> changeListener = null; changeListener = new ChangeExpector<>(property); property.addListener(changeListener); // add second listener (and remove again) ChangeExpector<Integer, String> changeListener2 = null; changeListener2 = new ChangeExpector<>(property); property.addListener(changeListener2); property.removeListener(changeListener2); ObservableMap<Integer, String> newValue = FXCollections .observableMap(new HashMap<Integer, String>()); changeListener.addExpectation(property.get(), newValue); newValue.put(1, "1"); property.set(newValue); changeListener.check(); }
Example 3
Source File: BaseIndicatorBox.java From TAcharting with GNU Lesser General Public License v2.1 | 5 votes |
/** * Constructor <p/> * @param series a {@link TaBarSeries time series} * @param parameterManager a {@link IndicatorParameterManager parameter manager} for indicator parameters */ public BaseIndicatorBox(TaBarSeries series, IndicatorParameterManager parameterManager){ Objects.requireNonNull(series); this.indicartors = FXCollections.observableMap(new HashMap<>()); this.strategies = FXCollections.observableMap(new HashMap<>()); this.tempIndicators = FXCollections.observableMap(new HashMap<>()); this.series = new SimpleObjectProperty<>(series); this.closePriceIndicator = new SimpleObjectProperty<>(new ClosePriceIndicator(this.series.get())); this.parameter = parameterManager; }
Example 4
Source File: Message.java From Animu-Downloaderu with MIT License | 4 votes |
public Message() { Map<String, String> map = new HashMap<>(); this.messages = FXCollections.observableMap(map); }