Package org.spdx.spreadsheetstore
Class DocumentInfoSheetV2d0
java.lang.Object
org.spdx.spreadsheetstore.AbstractSheet
org.spdx.spreadsheetstore.DocumentInfoSheet
org.spdx.spreadsheetstore.DocumentInfoSheetV2d0
DocumentInfoSheet for version 2.0+ of the SPDX Spec
- Author:
- Gary O'Neall
-
Field Summary
Fields inherited from class org.spdx.spreadsheetstore.DocumentInfoSheet
version
Fields inherited from class org.spdx.spreadsheetstore.AbstractSheet
checkboxStyle, CHECKSUM_PATTERN, copyManager, dateStyle, documentUri, firstCellNum, firstRowNum, FONT_SIZE, greenWrapped, lastRowNum, modelStore, redWrapped, sheet, workbook, yellowWrapped
-
Constructor Summary
ConstructorsConstructorDescriptionDocumentInfoSheetV2d0
(org.apache.poi.ss.usermodel.Workbook workbook, String sheetName, String version, org.spdx.storage.IModelStore modelStore, org.spdx.library.ModelCopyManager copyManager) -
Method Summary
Modifier and TypeMethodDescriptionvoid
addDocument
(org.spdx.library.model.v2.SpdxDocument doc) Add all origin information from the documentstatic void
Retrieve the author comments for the SPDX documentRetrieve the creation date of the SPDX documentRetrieve the list of creators of the SPDX documentRetrieve the license for the SPDX documentRetrieve the document comment for the SPDX documentSet SPDX identifier for the documentRetrieve the document nameCollection
<org.spdx.library.model.v2.ExternalDocumentRef> Retrieve the external document refsRetrieve the license list version for the SPDX documentRetrieve the namespace for the SPDX documentRetrieve the SPDX identifier for the SPDX documentRetrieve the SPDX specification version of the SPDX documentvoid
setAuthorComments
(String comments) Set the author comments for the SPDX documentvoid
setCreated
(Date created) Set the created date for the SPDX documentvoid
setCreatedBy
(String createdBy) void
setCreatedBy
(Collection<String> createdByCollection) Set the list of creators of the SPDX documentvoid
setDataLicense
(String dataLicense) Set the license for the SPDX documentvoid
setDocumentComment
(String docComment) Set the document comment for the SPDX documentvoid
setDocumentDescribes
(Collection<String> contentsCollection) Set the SPDX ID's for content described by this SPDX documentvoid
setDocumentName
(String documentName) Set the document namevoid
setExternalDocumentRefs
(Collection<org.spdx.library.model.v2.ExternalDocumentRef> externalDocumentRefColleciton) Set the external document refsvoid
setLicenseListVersion
(String licenseVersion) Set the license list version for the SPDX documentvoid
Set the SPDX identifier for the documentvoid
setSPDXVersion
(String version) Set the SPDX specification version for the SPDX documentvoid
setSpreadsheetVersion
(String version) verify()
Verifies the integrity of the sheet's dataMethods inherited from class org.spdx.spreadsheetstore.DocumentInfoSheet
getDataCellDateValue, getDataCellStringValue, getDataRow, getDataRow, getOrCreateDataCell, openVersion, setDataCellDateValue, setDataCellStringValue
Methods inherited from class org.spdx.spreadsheetstore.AbstractSheet
addRow, checksumsToString, checksumToString, clear, createCenterStyle, createHeaderStyle, createLeftWrapStyle, csvToStrings, getFirstDataRow, getNumDataRows, getSheet, licensesToString, parseChecksum, resizeRows, stringsToCsv, strToChecksums
-
Constructor Details
-
DocumentInfoSheetV2d0
public DocumentInfoSheetV2d0(org.apache.poi.ss.usermodel.Workbook workbook, String sheetName, String version, org.spdx.storage.IModelStore modelStore, org.spdx.library.ModelCopyManager copyManager) throws SpreadsheetException - Throws:
SpreadsheetException
-
-
Method Details
-
verify
Description copied from class:AbstractSheet
Verifies the integrity of the sheet's data- Specified by:
verify
in classAbstractSheet
- Returns:
- A string describing any issues, or an empty string if valid.
-
create
-
setAuthorComments
Description copied from class:DocumentInfoSheet
Set the author comments for the SPDX document- Specified by:
setAuthorComments
in classDocumentInfoSheet
- Parameters:
comments
- Author comments
-
setCreatedBy
-
setDataLicense
Description copied from class:DocumentInfoSheet
Set the license for the SPDX document- Specified by:
setDataLicense
in classDocumentInfoSheet
- Parameters:
dataLicense
- License ID
-
setSPDXVersion
Description copied from class:DocumentInfoSheet
Set the SPDX specification version for the SPDX document- Specified by:
setSPDXVersion
in classDocumentInfoSheet
- Parameters:
version
- SPDX specification version
-
setSpreadsheetVersion
-
getAuthorComments
Description copied from class:DocumentInfoSheet
Retrieve the author comments for the SPDX document- Specified by:
getAuthorComments
in classDocumentInfoSheet
- Returns:
- Author comments
-
getCreated
Description copied from class:DocumentInfoSheet
Retrieve the creation date of the SPDX document- Specified by:
getCreated
in classDocumentInfoSheet
- Returns:
- Date the SPDX document was created
-
getDataLicense
Description copied from class:DocumentInfoSheet
Retrieve the license for the SPDX document- Specified by:
getDataLicense
in classDocumentInfoSheet
- Returns:
- License ID
-
getSPDXVersion
Description copied from class:DocumentInfoSheet
Retrieve the SPDX specification version of the SPDX document- Specified by:
getSPDXVersion
in classDocumentInfoSheet
- Returns:
- SPDX specification version
-
getSpreadsheetVersion
-
setCreatedBy
Description copied from class:DocumentInfoSheet
Set the list of creators of the SPDX document- Specified by:
setCreatedBy
in classDocumentInfoSheet
- Parameters:
createdByCollection
- List of creators
-
getCreatedBy
Description copied from class:DocumentInfoSheet
Retrieve the list of creators of the SPDX document- Specified by:
getCreatedBy
in classDocumentInfoSheet
- Returns:
- List of creators
-
setCreated
Description copied from class:DocumentInfoSheet
Set the created date for the SPDX document- Specified by:
setCreated
in classDocumentInfoSheet
- Parameters:
created
- Created date
-
getDocumentComment
Description copied from class:DocumentInfoSheet
Retrieve the document comment for the SPDX document- Specified by:
getDocumentComment
in classDocumentInfoSheet
- Returns:
- Document comment
-
setDocumentComment
Description copied from class:DocumentInfoSheet
Set the document comment for the SPDX document- Specified by:
setDocumentComment
in classDocumentInfoSheet
- Parameters:
docComment
- Document comment
-
getLicenseListVersion
Description copied from class:DocumentInfoSheet
Retrieve the license list version for the SPDX document- Specified by:
getLicenseListVersion
in classDocumentInfoSheet
- Returns:
- License list version
-
setLicenseListVersion
Description copied from class:DocumentInfoSheet
Set the license list version for the SPDX document- Specified by:
setLicenseListVersion
in classDocumentInfoSheet
- Parameters:
licenseVersion
- License list version
-
getNamespace
Description copied from class:DocumentInfoSheet
Retrieve the namespace for the SPDX document- Specified by:
getNamespace
in classDocumentInfoSheet
- Returns:
- Namespace
-
addDocument
Description copied from class:DocumentInfoSheet
Add all origin information from the document- Specified by:
addDocument
in classDocumentInfoSheet
- Parameters:
doc
- SPDX document to add- Throws:
SpreadsheetException
-
getSpdxId
Description copied from class:DocumentInfoSheet
Retrieve the SPDX identifier for the SPDX document- Specified by:
getSpdxId
in classDocumentInfoSheet
- Returns:
- SPDX identifier for the document
-
setSpdxId
Description copied from class:DocumentInfoSheet
Set the SPDX identifier for the document- Specified by:
setSpdxId
in classDocumentInfoSheet
- Parameters:
id
- SPDX identifier
-
getDocumentName
Description copied from class:DocumentInfoSheet
Retrieve the document name- Specified by:
getDocumentName
in classDocumentInfoSheet
- Returns:
- Document name
-
setDocumentName
Description copied from class:DocumentInfoSheet
Set the document name- Specified by:
setDocumentName
in classDocumentInfoSheet
- Parameters:
documentName
- Document name
-
getDocumentContents
Description copied from class:DocumentInfoSheet
Set SPDX identifier for the document- Specified by:
getDocumentContents
in classDocumentInfoSheet
- Returns:
- SPDX ID's for content described by this SPDX document
-
setDocumentDescribes
Description copied from class:DocumentInfoSheet
Set the SPDX ID's for content described by this SPDX document- Specified by:
setDocumentDescribes
in classDocumentInfoSheet
- Parameters:
contentsCollection
- SPDX ID's for content described by this SPDX document
-
getExternalDocumentRefs
public Collection<org.spdx.library.model.v2.ExternalDocumentRef> getExternalDocumentRefs() throws SpreadsheetExceptionDescription copied from class:DocumentInfoSheet
Retrieve the external document refs- Specified by:
getExternalDocumentRefs
in classDocumentInfoSheet
- Returns:
- External document refs
- Throws:
SpreadsheetException
-
setExternalDocumentRefs
public void setExternalDocumentRefs(Collection<org.spdx.library.model.v2.ExternalDocumentRef> externalDocumentRefColleciton) throws SpreadsheetException Description copied from class:DocumentInfoSheet
Set the external document refs- Specified by:
setExternalDocumentRefs
in classDocumentInfoSheet
- Parameters:
externalDocumentRefColleciton
-- Throws:
SpreadsheetException
-