static boolean doReplace(NLSSubstitution substitution, Map<String, NLSSubstitution> newKeyToSubstMap, Map<String, NLSSubstitution> oldKeyToSubstMap) { if (substitution.getState() != NLSSubstitution.EXTERNALIZED || substitution.hasStateChanged() || substitution.getInitialValue() == null) { return false; // was not in property file before } if (oldKeyToSubstMap.get(substitution.getInitialKey()) != substitution) { return false; // not the owner of this key } if (substitution.isKeyRename() || substitution.isValueRename()) { if (newKeyToSubstMap.get(substitution.getKey()) == substitution) { // only rename if we're not a duplicate. duplicates will be removed return true; } } return false; }
static boolean doReplace(NLSSubstitution substitution, Map newKeyToSubstMap, Map oldKeyToSubstMap) { if (substitution.getState() != NLSSubstitution.EXTERNALIZED || substitution.hasStateChanged() || substitution.getInitialValue() == null) { return false; // was not in property file before } if (oldKeyToSubstMap.get(substitution.getInitialKey()) != substitution) { return false; // not the owner of this key } if (substitution.isKeyRename() || substitution.isValueRename()) { if (newKeyToSubstMap.get(substitution.getKey()) == substitution) { // only rename if we're not a duplicate. duplicates will be removed return true; } } return false; }
static boolean doReplace(NLSSubstitution substitution, Map<String, NLSSubstitution> newKeyToSubstMap, Map<String, NLSSubstitution> oldKeyToSubstMap) { if (substitution.getState() != NLSSubstitution.EXTERNALIZED || substitution.hasStateChanged() || substitution.getInitialValue() == null) { return false; // was not in property file before } if (oldKeyToSubstMap.get(substitution.getInitialKey()) != substitution) { return false; // not the owner of this key } if (substitution.isKeyRename() || substitution.isValueRename()) { if (newKeyToSubstMap.get(substitution.getKey()) == substitution) { // only rename if we're not a duplicate. duplicates will be removed return true; } } return false; }
if (substitution.getInitialState() == NLSSubstitution.IGNORED) { sourceModification.deleteTag(substitution, change); if (substitution.isValueRename()) { sourceModification.replaceValue(substitution, change); if (substitution.getInitialState() == NLSSubstitution.INTERNALIZED) { sourceModification.addNLS(substitution, change, accessorClassName); if (substitution.isValueRename()) { sourceModification.replaceValue(substitution, change); if (substitution.isValueRename()) { sourceModification.replaceValue(substitution, change);
if (substitution.getInitialState() == NLSSubstitution.IGNORED) { sourceModification.deleteTag(substitution, change); if (substitution.isValueRename()) { sourceModification.replaceValue(substitution, change); if (substitution.getInitialState() == NLSSubstitution.INTERNALIZED) { sourceModification.addNLS(substitution, change, null); if (substitution.isValueRename()) { sourceModification.replaceValue(substitution, change); if (substitution.isValueRename()) { sourceModification.replaceValue(substitution, change);
if (substitution.getInitialState() == NLSSubstitution.IGNORED) { sourceModification.deleteTag(substitution, change); if (substitution.isValueRename()) { sourceModification.replaceValue(substitution, change); if (substitution.getInitialState() == NLSSubstitution.INTERNALIZED) { sourceModification.addNLS(substitution, change, null); if (substitution.isValueRename()) { sourceModification.replaceValue(substitution, change); if (substitution.isValueRename()) { sourceModification.replaceValue(substitution, change);