/** * Fires a property change of a boolean property with the given name. If the * old value and the new value are not null and equal the event will not be * fired. * * @param propertyName * the property name * @param index * the index of the changed property * @param oldValue * the old value * @param newValue * the new value */ public void fireIndexedPropertyChange(String propertyName, int index, boolean oldValue, boolean newValue) { if (oldValue != newValue) { fireIndexedPropertyChange(propertyName, index, Boolean.valueOf(oldValue), Boolean.valueOf(newValue)); } }
/** * Fires a property change of an integer property with the given name. If * the old value and the new value are not null and equal the event will not * be fired. * * @param propertyName * the property name * @param index * the index of the changed property * @param oldValue * the old value * @param newValue * the new value */ public void fireIndexedPropertyChange(String propertyName, int index, int oldValue, int newValue) { if (oldValue != newValue) { fireIndexedPropertyChange(propertyName, index, Integer.valueOf(oldValue), Integer.valueOf(newValue)); } }
protected void fireIndexedPropertyChange ( final String propertyName, final int index, final boolean oldValue, final boolean newValue ) { this.listeners.fireIndexedPropertyChange ( propertyName, index, oldValue, newValue ); }
/** * {@inheritDoc} */ @Override public void setLabel( final String aLabel ) { String oldLabel = this.label; this.label = aLabel; this.propertyChangeSupport.fireIndexedPropertyChange( "channelLabel", this.index, oldLabel, aLabel ); }
/** * {@inheritDoc} */ @Override public void setLabel( final String aLabel ) { String oldLabel = this.label; this.label = aLabel; this.propertyChangeSupport.fireIndexedPropertyChange( "cursorLabel", this.index, oldLabel, this.label ); }
/** * {@inheritDoc} */ @Override public void setEnabled( final boolean aEnabled ) { boolean oldEnabled = this.enabled; this.enabled = aEnabled; this.propertyChangeSupport.fireIndexedPropertyChange( "channelEnabled", this.index, oldEnabled, aEnabled ); }
/** * Fire a property change event for a property with an index. * @param propertyName name of the property being changed * @param index property index * @param oldValue old property value * @param newValue new property value */ protected void fireIndexedPropertyChange(String propertyName, int index, int oldValue, int newValue) { myPropertyChangeSupport.fireIndexedPropertyChange(propertyName, index, oldValue, newValue); }
/** * Fire a property change event for a property with an index. * @param propertyName name of the property being changed * @param index property index * @param oldValue old property value * @param newValue new property value */ protected void fireIndexedPropertyChange(String propertyName, int index, boolean oldValue, boolean newValue){ myPropertyChangeSupport.fireIndexedPropertyChange(propertyName, index, oldValue, newValue); }
protected void fireIndexedPropertyChange(String propertyName, int index, Object oldValue, Object newValue) { pcs.fireIndexedPropertyChange(propertyName, index, oldValue, newValue); } }
/** * Fire a property change event for a property with an index. * @param propertyName name of the property being changed * @param index property index * @param oldValue old property value * @param newValue new property value */ protected void fireIndexedPropertyChange(String propertyName, int index, boolean oldValue, boolean newValue){ myPropertyChangeSupport.fireIndexedPropertyChange(propertyName, index, oldValue, newValue); }
/** * Fire a property change event for a property with an index. * @param propertyName name of the property being changed * @param index property index * @param oldValue old property value * @param newValue new property value */ protected void fireIndexedPropertyChange(String propertyName, int index, Object oldValue, Object newValue) { myPropertyChangeSupport.fireIndexedPropertyChange(propertyName, index, oldValue, newValue); }
/** * {@inheritDoc} */ @Override public void setTimestamp( final long aTimestamp ) { Long oldValue = this.timestamp; this.timestamp = Long.valueOf( aTimestamp ); this.propertyChangeSupport.fireIndexedPropertyChange( "cursorTimestamp", this.index, oldValue, this.timestamp ); }
public void fireIndexedPropertyChange(String propertyName, int index, boolean oldValue, boolean newValue) { if (oldValue != newValue) { fireIndexedPropertyChange(propertyName, index, Boolean.valueOf(oldValue), Boolean.valueOf(newValue)); } }
/** * Removes a belief base from the ordered list of belief bases. * @param beliefBase Reference to the belief base which shall be removed. */ public void removeBeliefbase(Collection<?> beliefBase) { int index = beliefBases.indexOf(beliefBase); if(index != -1) { beliefBases.remove(index); change.fireIndexedPropertyChange("beliefBases", index, beliefBase, null); } }
/** * Adds a belief base to the end of the ordered list of belief bases. * @param beliefBase Reference to the new belief base */ public void addBeliefbase(Collection<? extends Formula> beliefBase) { beliefBases.add(beliefBase); change.fireIndexedPropertyChange("beliefBases", beliefBases.size()-1, null, beliefBase); }
@Override public boolean removeAction(Action action) { action.putValue(RemoveActionControls.DELETED_PROPERTY, true); int index = actions.indexOf(action); if(actions.remove(action)) { propertyChangeSupport.fireIndexedPropertyChange(PROP_ACTIONS,index,action,null); return true; } else { return false; } } @Override
public void setPoint(int i, Point2D pt) { if (primitive[i] != pt) { Point2D old = primitive[i]; primitive[i] = pt; fireGraphicChanged(); pcs.fireIndexedPropertyChange(POINT_PROP, i, old, primitive[i]); } }
@Override public void addAction(Action action) { if (!actions.contains(action)) { actions.add(action); applyActionsOnAllControls(new Action[]{action}); propertyChangeSupport.fireIndexedPropertyChange(PROP_ACTIONS,actions.size()-1,null,action); } }
@Override public boolean removeAction(Action action) { action.putValue(RemoveActionControls.DELETED_PROPERTY, true); int index = actions.indexOf(action); if(actions.remove(action)) { propertyChangeSupport.fireIndexedPropertyChange(PROP_ACTIONS,index,action,null); return true; } else { return false; } } @Override
@Override public void addStyle(int i, Style s){ if (styleList == null){ styleList = new ArrayList<Style>(); } addStyleListener(s); styleList.add(i, s); propertyChangeSupport.fireIndexedPropertyChange(PROP_STYLES, i, null, s); this.fireStyleChanged(); }