Package jmri.beans

Class ConstrainedBean

    • Method Detail

      • fireVetoableChange

        public void fireVetoableChange​(java.beans.PropertyChangeEvent event)
                                throws java.beans.PropertyVetoException
        Fire a vetoable property change on the current thread. Use VetoableChangeSupport.fireVetoableChange(java.beans.PropertyChangeEvent) directly to fire this notification on another thread. If a PropertyVetoException is thrown, ensure the property change does not complete.
        Parameters:
        event - PropertyChangeEvent to be fired
        Throws:
        java.beans.PropertyVetoException - if property update vetoed
      • fireVetoableChange

        public void fireVetoableChange​(java.lang.String propertyName,
                                       java.lang.Object oldValue,
                                       java.lang.Object newValue)
                                throws java.beans.PropertyVetoException
        Fire a vetoable property change on the current thread. Use VetoableChangeSupport.fireVetoableChange(java.lang.String, java.lang.Object, java.lang.Object) directly to fire this notification on another thread. If a PropertyVetoException is thrown, ensure the property change does not complete.
        Parameters:
        propertyName - property that is about to change
        oldValue - old value of the property
        newValue - new value of the property
        Throws:
        java.beans.PropertyVetoException - if property update vetoed
      • fireVetoableChange

        public void fireVetoableChange​(java.lang.String propertyName,
                                       int oldValue,
                                       int newValue)
                                throws java.beans.PropertyVetoException
        Fire a vetoable property change on the current thread. Use VetoableChangeSupport.fireVetoableChange(java.lang.String, int, int) directly to fire this notification on another thread. If a PropertyVetoException is thrown, ensure the property change does not complete.
        Parameters:
        propertyName - property that is about to change
        oldValue - old value of the property
        newValue - new value of the property
        Throws:
        java.beans.PropertyVetoException - if property update vetoed
      • fireVetoableChange

        public void fireVetoableChange​(java.lang.String propertyName,
                                       boolean oldValue,
                                       boolean newValue)
                                throws java.beans.PropertyVetoException
        Fire a vetoable property change on the current thread. Use VetoableChangeSupport.fireVetoableChange(java.lang.String, boolean, boolean) directly to fire this notification on another thread. If a PropertyVetoException is thrown, ensure the property change does not complete.
        Parameters:
        propertyName - property that is about to change
        oldValue - old value of the property
        newValue - new value of the property
        Throws:
        java.beans.PropertyVetoException - if property update vetoed
      • getIndexedPropertyOrNull

        protected java.lang.Object getIndexedPropertyOrNull​(java.lang.String key,
                                                            int index)
        Get the indexed property or return null if the index is invalid. Used to get the old value when setting an indexed property where the index may not previously have been set.
        Parameters:
        key - the property name
        index - the index
        Returns:
        the value at index or null