Java 类javafx.beans.property.IntegerProperty 实例源码

项目:gen7-iv-calculator    文件:CalculatorPresenter.java   
private void undo() {
    History.HistoryAction action = history.undo();
    if (action == null) {
        return;
    }
    if (action instanceof History.Stat) {
        History.Stat statAction = (History.Stat) action;
        pokemon.setStatRange(statAction);
    } else if (action instanceof History.Evolution) {
        pokemon.unevolve();
    } else if (action instanceof History.EvAdded) {
        History.EvAdded evAction = (History.EvAdded) action;
        String stat = evAction.getStat();
        IntegerProperty statProperty = pokemon.getEffortValues().get(stat);
        statProperty.set(statProperty.get() - 1);
    }
}
项目:charts    文件:LocationBuilder.java   
public final Location build() {
    Location location = new Location();
    properties.forEach((key, property) -> {
        if ("name".equals(key)) {
            location.setName(((StringProperty) properties.get(key)).get());
        } else if ("timestamp".equals(key)) {
            location.setTimestamp(((ObjectProperty<Instant>) properties.get(key)).get());
        } else if ("latitude".equals(key)) {
            location.setLatitude(((DoubleProperty) properties.get(key)).get());
        } else if ("longitude".equals(key)) {
            location.setLongitude(((DoubleProperty) properties.get(key)).get());
        } else if ("altitude".equals(key)) {
            location.setAltitude(((DoubleProperty) properties.get(key)).get());
        } else if ("info".equals(key)) {
            location.setInfo(((StringProperty) properties.get(key)).get());
        } else if ("color".equals(key)) {
            location.setColor(((ObjectProperty<Color>) properties.get(key)).get());
        } else if ("zoomLevel".equals(key)) {
            location.setZoomLevel(((IntegerProperty) properties.get(key)).get());
        }

    });
    return location;
}
项目:hygene    文件:SequenceControllerTest.java   
@Test
void testDecrementLargeAmount() {
    final IntegerProperty onscreenBase = new SimpleIntegerProperty(10);
    when(sequenceVisualizer.getOnScreenBasesCountProperty()).thenReturn(onscreenBase);
    interact(() -> sequenceController.decrementLargeAction(mock(ActionEvent.class)));

    verify(sequenceVisualizer).decrementOffset(onscreenBase.get());
}
项目:can4eve    文件:JFXCanValuePlot.java   
public void updateOn(IntegerProperty updateCountProperty) {
  updateCountProperty.addListener(new ChangeListener<Number>() {

    @Override
    public void changed(ObservableValue<? extends Number> observable,
        Number oldValue, Number newValue) {
      if (debug)
        LOGGER.log(Level.INFO, "Plot "+JFXCanValuePlot.this.title+" "+newValue+" updates");
      if (newValue.doubleValue()>3)
        update();
    }

   });
}
项目:OneClient    文件:PageService.java   
public PageService(Supplier<List<Map.Entry<String, CurseProject>>> entries,
                   ObservableList<T> tiles,
                   StringProperty placeholder, IntegerProperty count) {
    this.entries = entries;
    this.tiles = tiles;
    this.placeholder = placeholder;
    this.count = count;
    this.setExecutor(Executors.newSingleThreadExecutor());
}
项目:shuffleboard    文件:PreferencesUtilsTest.java   
@Test
public void testSaveInt() {
  // given
  String name = "int";
  int value = Integer.MAX_VALUE;
  IntegerProperty property = new SimpleIntegerProperty(null, name, value);

  // when
  PreferencesUtils.save(property, preferences);

  // then
  int saved = preferences.getInt(name, -1);
  assertEquals(value, saved);
}
项目:shuffleboard    文件:PreferencesUtilsTest.java   
@Test
public void testReadWhenSavedValueIsWrongType() {
  // given
  int initialValue = 10;
  IntegerProperty property = new SimpleIntegerProperty(null, "value", initialValue);
  preferences.putBoolean("value", false);

  // when
  PreferencesUtils.read(property, preferences);

  // then
  assertEquals(initialValue, property.getValue().intValue());
}
项目:WebPLP    文件:PLPRegFile.java   
/***
 * PLPRegFile constructor. It creates all the registers and initializes to default value
 */
public PLPRegFile()
{
    this.registers = new IntegerProperty[NUMBER_OF_REGISTERS];
    this.regInstructions = new BooleanProperty[NUMBER_OF_REGISTERS];

    for(int i = 0; i < NUMBER_OF_REGISTERS; i++)
        this.registers[i] = new SimpleIntegerProperty(DEFAULT_REGISTER_VALUE);

    for(int i = 0; i < NUMBER_OF_REGISTERS; i++)
        this.regInstructions[i] = new SimpleBooleanProperty(false);


    this.namedRegisters = buildNamedRegistersMap();
}
项目:WebPLP    文件:PLPRegFile.java   
/**
 * This gets the value of the given register. It actually gives the property so we can bind to any other object
 * @param registerName Register whose value property needs to be fetched
 * @return returns the registers value propery.
 */
public IntegerProperty getRegisterValueProperty(String registerName)
{
    int index = convertNameToIndex(registerName);
    if (registerIndexIsValid(index))
        return registers[index];
    else
        return null;
}
项目:WebPLP    文件:CpuWindow.java   
public RegisterRow(String register, IntegerProperty content,
        TextField editContent)
{
    this.registerName = new SimpleStringProperty(register);
    this.content = content;
    this.editContent = new TextField();
}
项目:WebPLP    文件:CpuWindow.java   
public MemoryMapRow(int index, String moduleName, IntegerProperty startAddress,
        IntegerProperty endAddress, CheckBox enable)
{
    this.index = index;
    this.moduleName = moduleName;
    this.startAddress = startAddress;
    this.endAddress = endAddress;
    this.enable = new CheckBox();
}
项目:charts    文件:AreaHeatMapBuilder.java   
public final AreaHeatMap build() {
    final AreaHeatMap CONTROL = new AreaHeatMap();
    for (String key : properties.keySet()) {
        if ("prefSize".equals(key)) {
            Dimension2D dim = ((ObjectProperty<Dimension2D>) properties.get(key)).get();
            CONTROL.setPrefSize(dim.getWidth(), dim.getHeight());
        } else if ("colorMapping".equals(key)) {
            CONTROL.setColorMapping(((ObjectProperty<ColorMapping>) properties.get(key)).get());
        } else if("useColorMapping".equals(key)) {
            CONTROL.setUseColorMapping(((BooleanProperty) properties.get(key)).get());
        } else if ("quality".equals(key)) {
            CONTROL.setQuality(((IntegerProperty) properties.get(key)).get());
        } else if ("heatMapOpacity".equals(key)) {
            CONTROL.setHeatMapOpacity(((DoubleProperty) properties.get(key)).get());
        } else if ("dataPointsVisible".equals(key)) {
            CONTROL.setDataPointsVisible(((BooleanProperty) properties.get(key)).get());
        } else if ("smoothedHull".equals(key)) {
            CONTROL.setSmoothedHull(((BooleanProperty) properties.get(key)).get());
        } else if ("discreteColors".equals(key)) {
            CONTROL.setDiscreteColors(((BooleanProperty) properties.get(key)).get());
        } else if ("noOfCloserInfluentPoints".equals(key)) {
            CONTROL.setNoOfCloserInfluentPoints(((IntegerProperty) properties.get(key)).get());
        }
    }
    if (properties.keySet().contains("dataPointsArray")) {
        CONTROL.setDataPoints(((ObjectProperty<DataPoint[]>) properties.get("dataPointsArray")).get());
    }
    if(properties.keySet().contains("dataPointsList")) {
        CONTROL.setDataPoints(((ObjectProperty<List<DataPoint>>) properties.get("dataPointsList")).get());
    }
    return CONTROL;
}
项目:fritz-home-skill    文件:Powermeter.java   
default IntegerProperty powerPorperty() {
  return power;
}
项目:drd    文件:MeleWeaponEntry.java   
public IntegerProperty rampancyProperty() {
    return rampancy;
}
项目:stvs    文件:GlobalConfig.java   
public IntegerProperty simulationTimeoutProperty() {
  return simulationTimeout;
}
项目:eadlsync    文件:ConflictManagerViewModel.java   
public IntegerProperty currentIndexProperty() {
    return currentIndex;
}
项目:fx-animation-editor    文件:ClampedIntegerStringConverter.java   
public IntegerProperty minProperty() {
    return min;
}
项目:stvs    文件:GlobalConfig.java   
public IntegerProperty windowWidthProperty() {
  return windowWidth;
}
项目:fxutils    文件:EditableLabel.java   
public IntegerProperty editableClicksProperty() { 
    return editableClicks; 
}
项目:fritz-home-skill    文件:Powermeter.java   
default IntegerProperty energyPorperty() {
  return energy;
}
项目:CSS-Editor-FX    文件:IntegerOption.java   
public IntegerProperty intProperty() {
  return property;
}
项目:gen7-iv-calculator    文件:ConfigurationPresenter.java   
private void updateEffortValues() {
    Map<String, IntegerProperty> effortValues = pokemon.getEffortValues();
    Map<String, Integer> newEffortValues = EffortValueProvider.getEffortValues(gameService.getGame(), pokemon.getLevel());
    effortValues.forEach((stat, effortValue) -> effortValue.set(newEffortValues.get(stat)));
}
项目:3DSFE-Randomizer    文件:AGui.java   
public IntegerProperty baseStatPassesProperty() {
    return baseStatPasses;
}
项目:3DSFE-Randomizer    文件:AGui.java   
public IntegerProperty baseStatMinProperty() {
    return baseStatMin;
}
项目:3DSFE-Randomizer    文件:AGui.java   
public IntegerProperty baseStatMaxProperty() {
    return baseStatMax;
}
项目:3DSFE-Randomizer    文件:AGui.java   
public IntegerProperty growthPassesProperty() {
    return growthPasses;
}
项目:stvs    文件:GlobalConfig.java   
public IntegerProperty windowHeightProperty() {
  return windowHeight;
}
项目:3DSFE-Randomizer    文件:AGui.java   
public IntegerProperty growthMaxProperty() {
    return growthMax;
}
项目:3DSFE-Randomizer    文件:AGui.java   
public IntegerProperty modMinProperty() {
    return modMin;
}
项目:drd    文件:RangedWeapon.java   
public IntegerProperty rangeLongProperty() {
    return rangeLong;
}
项目:3DSFE-Randomizer    文件:FatesGui.java   
public IntegerProperty baseStatPassesProperty() {
    return baseStatPasses;
}
项目:drd    文件:Armor.java   
public IntegerProperty defenceNumberProperty() {
    return defenceNumber;
}
项目:ServerBrowser    文件:SampServer.java   
public IntegerProperty maxPlayersProperty() {
    return maxPlayersProperty;
}
项目:3DSFE-Randomizer    文件:FatesGui.java   
public IntegerProperty growthPassesProperty() {
    return growthPasses;
}
项目:3DSFE-Randomizer    文件:FatesGui.java   
public IntegerProperty growthMinProperty() {
    return growthMin;
}
项目:3DSFE-Randomizer    文件:FatesGui.java   
public IntegerProperty growthMaxProperty() {
    return growthMax;
}
项目:3DSFE-Randomizer    文件:FatesGui.java   
public IntegerProperty modPassesProperty() {
    return modPasses;
}
项目:fritz-home-skill    文件:FDevice.java   
public default IntegerProperty idPorperty() {
  return id;
}
项目:3DSFE-Randomizer    文件:FatesGui.java   
public IntegerProperty modMaxProperty() {
    return modMax;
}
项目:qgu    文件:ObservableGanttTask.java   
public IntegerProperty levelProperty() {
    return this.level;
}