public class Version extends Object
Also upstream documentation at https://gstreamer.freedesktop.org/documentation/gstreamer/gst.html#gst_version
Modifier and Type | Field and Description |
---|---|
static Version |
BASELINE
The baseline version of GStreamer supported by these Java bindings.
|
Constructor and Description |
---|
Version(int major,
int minor)
Constructor for creating a Version with micro and nano set to zero.
|
Version(int major,
int minor,
int micro,
int nano)
Constructor for creating a Version reflecting all aspects of the native
GStreamer version.
|
Modifier and Type | Method and Description |
---|---|
boolean |
checkSatisfies(Version required)
Check whether this version is equal to or greater than the passed in
version.
|
int |
getMajor()
Gets the major version of GStreamer.
|
int |
getMicro()
Gets the micro version of GStreamer.
|
int |
getMinor()
Gets the minor version of GStreamer.
|
int |
getNano()
Gets the nano version of GStreamer.
|
static Version |
of(int major,
int minor)
Create a Version with specified major and minor version, and micro and
nano version set to zero.
|
String |
toString()
Gets a string representation of the version.
|
public static final Version BASELINE
public Version(int major, int minor)
Gst.init(org.freedesktop.gstreamer.Version)
prefer using of(int, int)
.
The library only supports major version 1
major
- Major version of GStreamerminor
- Minor version of GStreamerpublic Version(int major, int minor, int micro, int nano)
The library only supports major version 1
major
- Major version of GStreamerminor
- Minor version of GStreamermicro
- Micro (patch) version of GStreamernano
- Nano The nano version of GStreamer : Actual releases have 0,
GIT versions have 1, prerelease versions have 2public String toString()
public int getMajor()
public int getMinor()
public int getMicro()
public int getNano()
public boolean checkSatisfies(Version required)
required
- version to check againstpublic static Version of(int major, int minor)
Gst.init(org.freedesktop.gstreamer.Version)
.
The library only supports major version 1
Unlike the constructor this method will throw an exception if the version
is not greater or equal to BASELINE
, or the major version isn't
1.
major
- major version, currently must be 1minor
- minor version, greater or equal to 8IllegalArgumentException
- if the requested version is invalidCopyright © 2021 gstreamer-java. All rights reserved.