Interface ILicenseFormatWriter
- All Known Implementing Classes:
LicenseHtmlFormatWriter,LicenseJsonFormatWriter,LicenseMarkdownFormatWriter,LicenseRdfaFormatWriter,LicenseRdfFormatWriter,LicenseTemplateFormatWriter,LicenseTextFormatWriter,SpdxWebsiteFormatWriter
public interface ILicenseFormatWriter
Writes licenses in a specific format
- Author:
- Gary O'Neall
-
Method Summary
Modifier and Type Method Description voidwriteException(org.spdx.library.model.license.ListedLicenseException exception)voidwriteLicense(org.spdx.library.model.license.SpdxListedLicense license, boolean deprecated, String deprecatedVersion)Formats and writes a specific licensevoidwriteToC()Write the Table of Contents file for the format if applicable
-
Method Details
-
writeLicense
void writeLicense(org.spdx.library.model.license.SpdxListedLicense license, boolean deprecated, String deprecatedVersion) throws IOException, LicenseGeneratorException, org.spdx.library.InvalidSPDXAnalysisException, org.spdx.licenseTemplate.InvalidLicenseTemplateExceptionFormats and writes a specific license- Parameters:
license- License to be addeddeprecated- True if deprecateddeprecatedVersion- License list version when the license was deprecated, null otherwise- Throws:
IOExceptionLicenseGeneratorExceptionorg.spdx.library.InvalidSPDXAnalysisExceptionorg.spdx.licenseTemplate.InvalidLicenseTemplateException
-
writeToC
Write the Table of Contents file for the format if applicable- Throws:
IOExceptionLicenseGeneratorException
-
writeException
void writeException(org.spdx.library.model.license.ListedLicenseException exception) throws IOException, LicenseGeneratorException, org.spdx.licenseTemplate.InvalidLicenseTemplateException, org.spdx.library.InvalidSPDXAnalysisException- Parameters:
exception- Exception to be formatted and written- Throws:
IOExceptionLicenseGeneratorExceptionorg.spdx.licenseTemplate.InvalidLicenseTemplateExceptionorg.spdx.library.InvalidSPDXAnalysisException
-