View Javadoc

1   package com.aragost.javahg.commands;
2   
3   import java.io.File;
4   
5   import com.aragost.javahg.Repository;
6   import com.aragost.javahg.commands.flags.RevertCommandFlags;
7   import com.aragost.javahg.internals.Utils;
8   
9   public class RevertCommand extends RevertCommandFlags {
10  
11      public RevertCommand(Repository repository) {
12          super(repository);
13      }
14  
15      /**
16       * Execute with no files. Should be used with {@link #all()}
17       */
18      public void execute() {
19          launchString(new String[0]);
20      }
21  
22      /**
23       * @param files the files to revert.
24       */
25      public void execute(String...files) {
26          launchString(files);
27      }
28  
29      /**
30       * @param files the files to revert.
31       */
32      public void execute(File... files) {
33          execute(Utils.fileArray2StringArray(files));
34      }
35  }