Class GHVulnerability
java.lang.Object
io.github.coho04.githubapi.bases.GHBase
io.github.coho04.githubapi.entities.GHVulnerability
- All Implemented Interfaces:
HttpRequestInterface
,JSONHelper
This class represents a GitHub Vulnerability.
It provides methods for fetching data about the vulnerability such as its package, first patched version, vulnerable version range, and vulnerable functions.
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.github.coho04.githubapi.interfaces.JSONHelper
JSONHelper.JSONToObject<T>
-
Constructor Summary
ConstructorsConstructorDescriptionGHVulnerability
(Github github, org.json.JSONObject jsonObject) Constructs a new GHVulnerability instance with the provided JSON object. -
Method Summary
Modifier and TypeMethodDescriptionReturns the first patched version of the vulnerability.Returns the package of the vulnerability.Returns the vulnerable functions of the vulnerability.Returns the vulnerable version range of the vulnerability.Methods inherited from class io.github.coho04.githubapi.bases.GHBase
fetchArrayData, fetchArrayData, fetchPaginatedData, fetchPaginatedData, fetchPaginatedData, getBaseUrl, toJSONObject
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.github.coho04.githubapi.interfaces.HttpRequestInterface
extractNextPageUrl, sendDeleteRequest, sendDeleteRequestWithResponseCode, sendGetRequest, sendGetRequestWithLinkHeader, sendGetRequestWithResponseCode, sendPatchRequest, sendPostRequest, sendPutRequest
Methods inherited from interface io.github.coho04.githubapi.interfaces.JSONHelper
getArrayOrNull, getBooleanOrNull, getIntOrNull, getJSONArrayToStringList, getJSONObjectOrNull, getLocalDateOrNull, getLongOrNull, getStringOrNull
-
Constructor Details
-
GHVulnerability
Constructs a new GHVulnerability instance with the provided JSON object.- Parameters:
jsonObject
- the JSON object containing the vulnerability data
-
-
Method Details
-
getGhPackage
Returns the package of the vulnerability.- Returns:
- the package of the vulnerability
-
getFirstPatchedVersion
Returns the first patched version of the vulnerability.- Returns:
- the first patched version of the vulnerability
-
getVulnerableVersionRange
Returns the vulnerable version range of the vulnerability.- Returns:
- the vulnerable version range of the vulnerability
-
getVulnerableFunctions
Returns the vulnerable functions of the vulnerability.- Returns:
- the vulnerable functions of the vulnerability
-