Package org.spdx.html
Class LicenseTOCJSONFile
java.lang.Object
org.spdx.html.AbstractJsonFile
org.spdx.html.LicenseTOCJSONFile
public class LicenseTOCJSONFile extends AbstractJsonFile
This class holds a JSON file for a license table of contents
- Author:
- Kyle E. Mitchell
-
Field Summary
Fields Modifier and Type Field Description static StringJSON_REFERENCE_FIELD -
Constructor Summary
Constructors Constructor Description LicenseTOCJSONFile(String version, String releaseDate) -
Method Summary
Modifier and Type Method Description voidaddLicense(SpdxListedLicense license, String licHTMLReference, String licJSONReference, boolean deprecated)Add a license to the JSON table of contents fileprotected org.json.simple.JSONObjectgetJsonObject()
-
Field Details
-
JSON_REFERENCE_FIELD
- See Also:
- Constant Field Values
-
-
Constructor Details
-
Method Details
-
addLicense
public void addLicense(SpdxListedLicense license, String licHTMLReference, String licJSONReference, boolean deprecated)Add a license to the JSON table of contents file- Parameters:
license- License to be addedlicHTMLReference- file path to the license file HTMLlicHTMLReference- file path to the license file JSON detaildeprecated- true if the license ID is deprecated
-
getJsonObject
protected org.json.simple.JSONObject getJsonObject()- Specified by:
getJsonObjectin classAbstractJsonFile- Returns:
- the JsonObject to be written
-