Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a2f78a36 authored by Chet Haase's avatar Chet Haase
Browse files

Change Property.set() to throw UnsupportedOperationException by default

Change-Id: I2326e066e0b7ce63cbafe83a3a37b90a3d148c43
parent be674b18
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -78,11 +78,11 @@ public abstract class Property<T, V> {

    /**
     * Sets the value on <code>object</code> which this property represents. If the method is unable
     * to set the value on the target object, it will throw a {@link NoSuchPropertyException}
     * to set the value on the target object it will throw an {@link UnsupportedOperationException}
     * exception.
     */
    public void set(T object, V value) {
        throw new NoSuchPropertyException("Property is read-only; set() is not implemented");
        throw new UnsupportedOperationException("Property " + getName() +" is read-only");
    }

    /**