-
Notifications
You must be signed in to change notification settings - Fork 182
Expand file tree
/
Copy pathFFbinaryInterface.java
More file actions
72 lines (62 loc) · 2.06 KB
/
FFbinaryInterface.java
File metadata and controls
72 lines (62 loc) · 2.06 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
package nl.bravobit.ffmpeg;
import java.util.Map;
interface FFbinaryInterface {
/**
* Executes a command
*
* @param environmentVars Environment variables
* @param cmd command to execute
* @param ffcommandExecuteResponseHandler {@link FFcommandExecuteResponseHandler}
* @return the task
*/
FFtask execute(Map<String, String> environmentVars, String[] cmd, FFcommandExecuteResponseHandler ffcommandExecuteResponseHandler);
/**
* Executes a command
*
* @param cmd command to execute
* @param ffcommandExecuteResponseHandler {@link FFcommandExecuteResponseHandler}
* @return the task
*/
FFtask execute(String[] cmd, FFcommandExecuteResponseHandler ffcommandExecuteResponseHandler);
/**
* Executes a command synchronously
*
* @param environmentVars Environment variables
* @param cmd command to execute
* @return The output of the command
*/
String execute(Map<String, String> environmentVars, String[] cmd);
/**
* Executes a command synchronously
*
* @param cmd command to execute
* @return The output of the command
*/
String execute(String[] cmd);
/**
* Checks if FF binary is supported on this device
*
* @return true if FF binary is supported on this device
*/
boolean isSupported();
/**
* Checks if a command with given task is currently running
*
* @param task - the task that you want to check
* @return true if a command is running
*/
boolean isCommandRunning(FFtask task);
/**
* Kill given running process
*
* @param task - the task to kill
* @return true if process is killed successfully
*/
boolean killRunningProcesses(FFtask task);
/**
* Timeout for binary process, should be minimum of 10 seconds
*
* @param timeout in milliseconds
*/
void setTimeout(long timeout);
}