org.apache.commons.lang.StringUtils



Project JetBrains/intellij-community in file ...c.org.zmlx.hg4idea.command.HgTagBranchCommand.java (2012-08-10)
@@ -15,7 +15,6 @@ package org.zmlx.hg4idea.command;
 import com.intellij.openapi.project.Project;
 import com.intellij.openapi.vfs.VirtualFile;
 import com.intellij.util.Consumer;
-import org.apache.commons.lang.StringUtils;
 import org.jetbrains.annotations.NotNull;
 import org.jetbrains.annotations.Nullable;
 import org.zmlx.hg4idea.HgRevisionNumber;
@@ -55,7 +54,7 @@ public class HgTagBranchCommand {
     if (output == null || output.isEmpty()) {
       return null;
     }
-    return StringUtils.trim(output.get(0));
+    return output.get(0).trim();
   }
 
   public void listBranches(final Consumer<List<HgTagBranch>> branchListConsumer) {
Project JetBrains/intellij-community in file ...src.org.zmlx.hg4idea.command.HgVersionCommand.java (2012-08-10)
@@ -12,7 +12,6 @@
 // limitations under the License.
 package org.zmlx.hg4idea.command;
 
-import org.apache.commons.lang.StringUtils;
 import org.zmlx.hg4idea.execution.ShellCommand;
 import org.zmlx.hg4idea.execution.ShellCommandException;
 
@@ -22,7 +21,7 @@ import java.util.Arrays;
 public class HgVersionCommand {
 
   public boolean isValid(String executable, boolean isRunViaBash) {
-    String hgExecutable = StringUtils.trim(executable);
+    String hgExecutable = executable == null ? null : executable.trim();
     ShellCommand shellCommand = new ShellCommand(isRunViaBash);
     try {
       return !shellCommand
Project JetBrains/intellij-community in file ...g.zmlx.hg4idea.ui.HgConfigurationProjectPanel.java (2012-08-10)
@@ -15,7 +15,6 @@ package org.zmlx.hg4idea.ui;
 import com.intellij.openapi.options.ConfigurationException;
 import com.intellij.openapi.ui.TextFieldWithBrowseButton;
 import com.intellij.openapi.util.SystemInfo;
-import org.apache.commons.lang.StringUtils;
 import org.zmlx.hg4idea.HgGlobalSettings;
 import org.zmlx.hg4idea.HgProjectSettings;
 import org.zmlx.hg4idea.HgVcsMessages;
@@ -85,7 +84,7 @@ public class HgConfigurationProjectPanel {
     mySelectRadioButton.setSelected(!isAutodetectHg);
     myPathSelector.setEnabled(!isAutodetectHg);
     if (isAutodetectHg) {
-      myPathSelector.setText(StringUtils.EMPTY);
+      myPathSelector.setText("");
     } else {
       myPathSelector.setText(myProjectSettings.getHgExecutable());
     }
Project JetBrains/intellij-community in file ....hg4idea.src.org.zmlx.hg4idea.ui.HgPushDialog.java (2012-08-10)
@@ -18,7 +18,6 @@ import com.intellij.openapi.project.Project;
 import com.intellij.openapi.ui.DialogWrapper;
 import com.intellij.openapi.util.text.StringUtil;
 import com.intellij.openapi.vfs.VirtualFile;
-import org.apache.commons.lang.StringUtils;
 import org.jetbrains.annotations.NotNull;
 import org.jetbrains.annotations.Nullable;
 import org.zmlx.hg4idea.HgPusher;
@@ -139,7 +138,7 @@ public class HgPushDialog extends DialogWrapper {
   }
 
   private boolean validateOptions() {
-    return StringUtils.isNotBlank(repositoryTxt.getText())
+    return !StringUtil.isEmptyOrSpaces(repositoryTxt.getText())
       && !(revisionCbx.isSelected() && StringUtil.isEmptyOrSpaces(revisionTxt.getText()))
       && !(branchCheckBox.isSelected() && (branchComboBox.getSelectedItem() == null));
   }
Project apache/cassandra in file ...va.org.apache.cassandra.streaming.PendingFile.java (2011-05-04)
@@ -27,8 +27,6 @@ import java.io.IOException;
 import java.util.ArrayList;
 import java.util.List;
 
-import org.apache.commons.lang.StringUtils;
-
 import org.apache.cassandra.io.ICompactSerializer;
 import org.apache.cassandra.io.sstable.Descriptor;
 import org.apache.cassandra.io.sstable.SSTable;
@@ -95,7 +93,7 @@ public class PendingFile
 
     public String toString()
     {
-        return getFilename() + "/" + StringUtils.join(sections, ",") + "\n\t progress=" + progress + "/" + size + " - " + progress*100/size + "%";
+        return getFilename() + " sections=" + sections.size() + " progress=" + progress + "/" + size + " - " + progress*100/size + "%";
     }
 
     public static class PendingFileSerializer implements ICompactSerializer<PendingFile>