Package com.nomagic.license.utils.exec
Interface Commandline
- All Known Implementing Classes:
CommandlineImpl
@OpenApiAll
public interface Commandline
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final longDefault process timeout = 1 minute -
Method Summary
Modifier and TypeMethodDescriptionExecute command lineExecute command lineExecute command lineExecute command lineExecute command lineExecute command lineExecute command lineExecute command linelongbooleanvoidPrint some log information.voidsetTimeout(long timeout)
-
Field Details
-
DEFAULT_TIMEOUT
static final long DEFAULT_TIMEOUTDefault process timeout = 1 minute- See Also:
-
-
Method Details
-
execute
ProcessOutput execute(String cmd, String[] environment, File dir) throws IOException, InterruptedException Execute command line- Parameters:
dir- file working directorycmd- command line- Returns:
- output of command
- Throws:
IOExceptionInterruptedException
-
execute
Execute command line- Parameters:
cmd- command line- Returns:
- output of command
- Throws:
IOExceptionInterruptedException
-
execute
Execute command line- Parameters:
dir- file working directorycmd- command line- Returns:
- output of command
- Throws:
IOExceptionInterruptedException
-
execute
Execute command line- Parameters:
cmd- command line- Returns:
- output of command
- Throws:
IOExceptionInterruptedException
-
execute
ProcessOutput execute(String[] cmd, String[] environment, File dir) throws IOException, InterruptedException Execute command line- Parameters:
dir- file working directorycmd- command line- Returns:
- output of command
- Throws:
IOExceptionInterruptedException
-
execute
Execute command line- Parameters:
cmd- command line- Returns:
- output of command
- Throws:
IOExceptionInterruptedException
-
execute
Execute command line- Parameters:
dir- file working directorycmd- command line- Returns:
- output of command
- Throws:
IOExceptionInterruptedException
-
execute
Execute command line- Parameters:
cmd- command line- Returns:
- output of command
- Throws:
IOExceptionInterruptedException
-
getTimeout
long getTimeout()- Returns:
-
setTimeout
void setTimeout(long timeout) -
isLogEnabled
boolean isLogEnabled()- Returns:
-
log
Print some log information.- Parameters:
text-
-