If the user name ends with " Exc", this string is removed. BLD200407281800
authormentlicher@netbeans.org
Wed, 28 Jul 2004 14:48:36 +0000
changeset 4977963fc75d5bcf
parent 4976 5c01e4688e53
child 4978 6e2a81d67f79
If the user name ends with " Exc", this string is removed.
This is a fix of issue #36615.
vcs.profiles.vss/src/org/netbeans/modules/vcs/profiles/vss/list/VssListCommand.java
vcs.profiles.vss/src/org/netbeans/modules/vcs/profiles/vss/list/VssListFileCommand.java
vcs.profiles.vss/src/org/netbeans/modules/vcs/profiles/vss/list/VssListRecursive.java
     1.1 --- a/vcs.profiles.vss/src/org/netbeans/modules/vcs/profiles/vss/list/VssListCommand.java	Wed Jul 28 13:26:06 2004 +0000
     1.2 +++ b/vcs.profiles.vss/src/org/netbeans/modules/vcs/profiles/vss/list/VssListCommand.java	Wed Jul 28 14:48:36 2004 +0000
     1.3 @@ -299,7 +299,8 @@
     1.4                                  } else {
     1.5                                      statuses[1] = STATUS_LOCALLY_MODIFIED;
     1.6                                  }
     1.7 -                                statuses[2] = addLocker(statuses[2], elements[0].substring(index, index2).trim());
     1.8 +                                String lockerName = elements[0].substring(index, index2).trim();
     1.9 +                                statuses[2] = addLocker(statuses[2], parseLocker(lockerName));
    1.10                                  filesByName.put(statuses[0], statuses);
    1.11                                  stdoutListener.outputData(statuses);
    1.12                                  processedFiles.add(file);
    1.13 @@ -346,6 +347,13 @@
    1.14          }
    1.15      }
    1.16      
    1.17 +    static final String parseLocker(String lockerName) {
    1.18 +        if (lockerName.endsWith(" Exc")) {
    1.19 +            lockerName = lockerName.substring(0, lockerName.length() - " Exc".length());
    1.20 +        }
    1.21 +        return lockerName;
    1.22 +    }
    1.23 +    
    1.24      private void fillFilesByName(Set files, String status) throws InterruptedException {
    1.25          if (files == null) return ;
    1.26          for (Iterator fileIt = files.iterator(); fileIt.hasNext(); ) {
    1.27 @@ -435,7 +443,7 @@
    1.28          int index2 = elements[0].indexOf("  ", index);
    1.29          if (index2 < 0) index2 = elements[0].length();
    1.30          if (index < index2) {
    1.31 -            statuses[2] = addLocker(statuses[2], elements[0].substring(index, index2).trim());
    1.32 +            statuses[2] = addLocker(statuses[2], parseLocker(elements[0].substring(index, index2).trim()));
    1.33          } else {
    1.34              if (statuses[2] == null) statuses[2] = "";
    1.35          }
     2.1 --- a/vcs.profiles.vss/src/org/netbeans/modules/vcs/profiles/vss/list/VssListFileCommand.java	Wed Jul 28 13:26:06 2004 +0000
     2.2 +++ b/vcs.profiles.vss/src/org/netbeans/modules/vcs/profiles/vss/list/VssListFileCommand.java	Wed Jul 28 14:48:36 2004 +0000
     2.3 @@ -310,7 +310,7 @@
     2.4          int index2 = elements[0].indexOf("  ", index);
     2.5          if (index2 < 0) index2 = elements[0].length();
     2.6          if (index < index2) {
     2.7 -            statuses[2] = VssListCommand.addLocker(statuses[2], elements[0].substring(index, index2).trim());
     2.8 +            statuses[2] = VssListCommand.addLocker(statuses[2], VssListCommand.parseLocker(elements[0].substring(index, index2).trim()));
     2.9          } else {
    2.10              if (statuses[2] == null) statuses[2] = "";
    2.11          }
     3.1 --- a/vcs.profiles.vss/src/org/netbeans/modules/vcs/profiles/vss/list/VssListRecursive.java	Wed Jul 28 13:26:06 2004 +0000
     3.2 +++ b/vcs.profiles.vss/src/org/netbeans/modules/vcs/profiles/vss/list/VssListRecursive.java	Wed Jul 28 14:48:36 2004 +0000
     3.3 @@ -521,7 +521,7 @@
     3.4                  file = getDistinguishable(pattern, filesByName);
     3.5                  if (file != null) {
     3.6                      String[] statuses = (String[]) filesByName.get(file);
     3.7 -                    statuses[2] = VssListCommand.addLocker(statuses[2], elements[0].substring(index, index2).trim());
     3.8 +                    statuses[2] = VssListCommand.addLocker(statuses[2], VssListCommand.parseLocker(elements[0].substring(index, index2).trim()));
     3.9                  } else {
    3.10                      undistiguishable.add(lastFilesCont.getPath()+"/"+pattern);
    3.11                  }