Package net.bramp.ffmpeg
Class Preconditions
java.lang.Object
net.bramp.ffmpeg.Preconditions
-
Method Summary
Modifier and TypeMethodDescriptionstatic String
checkNotEmpty
(String arg, Object errorMessage) Ensures the argument is not null, empty string, or just whitespace.static URI
checkValidStream
(URI uri) Checks if the URI is valid for streaming to.
-
Method Details
-
checkNotEmpty
Ensures the argument is not null, empty string, or just whitespace.- Parameters:
arg
- The argumenterrorMessage
- The exception message to use if the check fails- Returns:
- The passed in argument if it is not blank
-
checkValidStream
Checks if the URI is valid for streaming to.- Parameters:
uri
- The URI to check- Returns:
- The passed in URI if it is valid
- Throws:
IllegalArgumentException
- if the URI is not valid.
-