@@ -0,0 +1,799 @@
+/*%0A * To change this license header, choose License Headers in Project Properties.%0A * To change this template file, choose Tools %7C Templates%0A * and open the template in the editor.%0A */%0Apackage doublex.lib.locks;%0A%0A/**%0A *%0A * @author kenneth.lau%0A * @param %3CK%3E%0A */%0Apublic final class MutableLock%3CK%3E extends AbstractLock%3CK%3E implements %0A        IMutableLockable%3CK%3E %7B%0A%0A    private K mKey;%0A%0A    public MutableLock(final K key) %7B%0A        changeKey(key);%0A    %7D%0A%0A    @Override%0A    public final void tryChangeKey(final K oldKey, final K newKey) %7B%0A        if (isLocked()) return;%0A        if (isCorrectKey(oldKey)) changeKey(newKey);%0A    %7D%0A%0A    @Override%0A    final boolean isCorrectKey(final K key) %7B%0A        return mKey.equals(key);%0A    %7D%0A%0A    private void changeKey(final K key) %7B%0A        mKey = key;%0A    %7D%0A%0A%7D;%0A

Create MutableLock.java