Package org.spdx.rdfparser.model
Class SpdxPackage
java.lang.Object
org.spdx.rdfparser.model.RdfModelObject
org.spdx.rdfparser.model.SpdxElement
org.spdx.rdfparser.model.SpdxItem
org.spdx.rdfparser.model.SpdxPackage
- All Implemented Interfaces:
Cloneable,Comparable<SpdxPackage>,IRdfModel,SpdxRdfConstants
public class SpdxPackage extends SpdxItem implements SpdxRdfConstants, Comparable<SpdxPackage>
A Package represents a collection of software files that are
delivered as a single functional component.
- Author:
- Gary O'Neall
-
Field Summary
Fields inherited from class org.spdx.rdfparser.model.SpdxElement
annotations, comment, name, relationshipsFields inherited from class org.spdx.rdfparser.model.RdfModelObject
model, modelContainer, node, refreshOnGet, resourceFields inherited from interface org.spdx.rdfparser.SpdxRdfConstants
ALGORITHM_SHA1, CLASS_ANNOTATION, CLASS_DOAP_PROJECT, CLASS_EXTERNAL_DOC_REF, CLASS_OR_LATER_OPERATOR, CLASS_POINTER_BYTE_OFFSET_POINTER, CLASS_POINTER_LINE_CHAR_POINTER, CLASS_POINTER_START_END_POINTER, CLASS_RELATIONSHIP, CLASS_SPDX_ANY_LICENSE_INFO, CLASS_SPDX_CHECKSUM, CLASS_SPDX_CONJUNCTIVE_LICENSE_SET, CLASS_SPDX_CREATION_INFO, CLASS_SPDX_DISJUNCTIVE_LICENSE_SET, CLASS_SPDX_DOCUMENT, CLASS_SPDX_ELEMENT, CLASS_SPDX_EXTERNAL_REFERENCE, CLASS_SPDX_EXTRACTED_LICENSING_INFO, CLASS_SPDX_FILE, CLASS_SPDX_ITEM, CLASS_SPDX_LICENSE, CLASS_SPDX_LICENSE_EXCEPTION, CLASS_SPDX_NOASSERTION_ELEMENT, CLASS_SPDX_NONE_ELEMENT, CLASS_SPDX_PACKAGE, CLASS_SPDX_REFERENCE_TYPE, CLASS_SPDX_REVIEW, CLASS_SPDX_SIMPLE_LICENSE_INFO, CLASS_SPDX_SNIPPET, CLASS_SPDX_VERIFICATIONCODE, CLASS_WITH_EXCEPTION_OPERATOR, CREATOR_PREFIX_ORGANIZATION, CREATOR_PREFIX_PERSON, CREATOR_PREFIX_TOOL, DOAP_NAMESPACE, EXTERNAL_DOC_REF_PATTERN, EXTERNAL_DOC_REF_PRENUM, EXTERNAL_ELEMENT_REF_PATTERN, FILE_TYPE_ARCHIVE, FILE_TYPE_BINARY, FILE_TYPE_OTHER, FILE_TYPE_SOURCE, LICENSE_ID_PATTERN, LICENSE_ID_PATTERN_NUMERIC, LICENSEXML_ATTRIBUTE_ALT_MATCH, LICENSEXML_ATTRIBUTE_ALT_NAME, LICENSEXML_ATTRIBUTE_DEPRECATED, LICENSEXML_ATTRIBUTE_DEPRECATED_VERSION, LICENSEXML_ATTRIBUTE_FSF_LIBRE, LICENSEXML_ATTRIBUTE_ID, LICENSEXML_ATTRIBUTE_LIST_VERSION_ADDED, LICENSEXML_ATTRIBUTE_NAME, LICENSEXML_ATTRIBUTE_OSI_APPROVED, LICENSEXML_ELEMENT_ALT, LICENSEXML_ELEMENT_BREAK, LICENSEXML_ELEMENT_BULLET, LICENSEXML_ELEMENT_COPYRIGHT_TEXT, LICENSEXML_ELEMENT_CROSS_REF, LICENSEXML_ELEMENT_CROSS_REFS, LICENSEXML_ELEMENT_EXCEPTION, LICENSEXML_ELEMENT_ITEM, LICENSEXML_ELEMENT_LICENSE, LICENSEXML_ELEMENT_LICENSE_COLLECTION, LICENSEXML_ELEMENT_LIST, LICENSEXML_ELEMENT_NOTES, LICENSEXML_ELEMENT_OPTIONAL, LICENSEXML_ELEMENT_PARAGRAPH, LICENSEXML_ELEMENT_STANDARD_LICENSE_HEADER, LICENSEXML_ELEMENT_TEXT, LICENSEXML_ELEMENT_TITLE_TEXT, LICENSEXML_URI, NOASSERTION_VALUE, NON_STD_LICENSE_ID_PRENUM, NONE_VALUE, OWL_NAMESPACE, PROP_ANNOTATION, PROP_ANNOTATION_DATE, PROP_ANNOTATION_TYPE, PROP_ANNOTATOR, PROP_ATTRIBUTION_TEXT, PROP_CHECKSUM_ALGORITHM, PROP_CHECKSUM_ALGORITHM_SHA1, PROP_CHECKSUM_VALUE, PROP_COPYRIGHT_TEXT, PROP_CREATION_CREATED, PROP_CREATION_CREATOR, PROP_CROSS_REF_IS_LIVE, PROP_CROSS_REF_IS_VALID, PROP_CROSS_REF_MATCH, PROP_CROSS_REF_TIMESTAMP, PROP_CROSS_REF_URL, PROP_CROSS_REF_WAYBACK_LINK, PROP_EXAMPLE, PROP_EXCEPTION_TEMPLATE, PROP_EXCEPTION_TEXT, PROP_EXTERNAL_DOC_CHECKSUM, PROP_EXTERNAL_DOC_ID, PROP_EXTERNAL_REF, PROP_EXTERNAL_SPDX_DOCUMENT, PROP_EXTRACTED_TEXT, PROP_FILE_ARTIFACTOF, PROP_FILE_CHECKSUM, PROP_FILE_CONTRIBUTOR, PROP_FILE_COPYRIGHT, PROP_FILE_FILE_DEPENDENCY, PROP_FILE_LIC_COMMENTS, PROP_FILE_LICENSE, PROP_FILE_NAME, PROP_FILE_NOTICE, PROP_FILE_SEEN_LICENSE, PROP_FILE_TYPE, PROP_FILE_TYPE_ARCHIVE, PROP_FILE_TYPE_BINARY, PROP_FILE_TYPE_OTHER, PROP_FILE_TYPE_SOURCE, PROP_LIC_COMMENTS, PROP_LIC_ID_DEPRECATED, PROP_LICENSE_CONCLUDED, PROP_LICENSE_DECLARED, PROP_LICENSE_EXCEPTION, PROP_LICENSE_EXCEPTION_ID, PROP_LICENSE_ID, PROP_LICENSE_INFO_FROM_SNIPPETS, PROP_LICENSE_LIST_VERSION, PROP_LICENSE_NAME, PROP_LICENSE_SET_MEMEBER, PROP_LICENSE_TEXT, PROP_NAME, PROP_OWL_SAME_AS, PROP_PACKAGE_CHECKSUM, PROP_PACKAGE_CONCLUDED_LICENSE, PROP_PACKAGE_DECLARED_COPYRIGHT, PROP_PACKAGE_DECLARED_LICENSE, PROP_PACKAGE_DECLARED_NAME, PROP_PACKAGE_DESCRIPTION, PROP_PACKAGE_DOWNLOAD_URL, PROP_PACKAGE_FILE, PROP_PACKAGE_FILE_NAME, PROP_PACKAGE_FILES_ANALYZED, PROP_PACKAGE_LICENSE_COMMENT, PROP_PACKAGE_LICENSE_INFO_FROM_FILES, PROP_PACKAGE_ORIGINATOR, PROP_PACKAGE_SHORT_DESC, PROP_PACKAGE_SOURCE_INFO, PROP_PACKAGE_SUPPLIER, PROP_PACKAGE_VERIFICATION_CODE, PROP_PACKAGE_VERSION_INFO, PROP_POINTER_END_POINTER, PROP_POINTER_LINE_NUMBER, PROP_POINTER_OFFSET, PROP_POINTER_REFERENCE, PROP_POINTER_START_POINTER, PROP_PROJECT_HOMEPAGE, PROP_PROJECT_NAME, PROP_REFERENCE_CATEGORY, PROP_REFERENCE_LOCATOR, PROP_REFERENCE_TYPE, PROP_RELATED_SPDX_ELEMENT, PROP_RELATIONSHIP, PROP_RELATIONSHIP_TYPE, PROP_REVIEW_DATE, PROP_REVIEW_REVIEWER, PROP_SNIPPET_FROM_FILE, PROP_SNIPPET_RANGE, PROP_SPDX_CREATION_INFO, PROP_SPDX_DATA_LICENSE, PROP_SPDX_EXTERNAL_DOC_REF, PROP_SPDX_EXTRACTED_LICENSES, PROP_SPDX_FILE_REFERENCE, PROP_SPDX_PACKAGE, PROP_SPDX_REVIEWED_BY, PROP_SPDX_VERSION, PROP_STD_LICENSE_FSF_LIBRE, PROP_STD_LICENSE_HEADER_TEMPLATE, PROP_STD_LICENSE_HEADER_VERSION_1, PROP_STD_LICENSE_NAME, PROP_STD_LICENSE_NAME_VERSION_1, PROP_STD_LICENSE_NOTES_VERSION_1, PROP_STD_LICENSE_NOTICE, PROP_STD_LICENSE_OSI_APPROVED, PROP_STD_LICENSE_OSI_APPROVED_VERSION_1, PROP_STD_LICENSE_TEMPLATE, PROP_STD_LICENSE_TEMPLATE_VERSION_1, PROP_STD_LICENSE_URL_VERSION_1, PROP_VALUE_NOASSERTION, PROP_VALUE_NONE, PROP_VERIFICATIONCODE_IGNORED_FILES, PROP_VERIFICATIONCODE_VALUE, RDF_NAMESPACE, RDF_POINTER_NAMESPACE, RDF_PROP_RESOURCE, RDF_PROP_TYPE, RDFS_NAMESPACE, RDFS_PROP_COMMENT, RDFS_PROP_LABEL, RDFS_PROP_SEE_ALSO, SPDX_DATA_LICENSE_ID, SPDX_DATA_LICENSE_ID_VERSION_1_0, SPDX_DATE_FORMAT, SPDX_DOCUMENT_ID, SPDX_ELEMENT_REF_PATTERN, SPDX_ELEMENT_REF_PRENUM, SPDX_LISTED_REFERENCE_TYPES_PREFIX, SPDX_NAMESPACE, SPDX_VERSION_PATTERN, STANDARD_LICENSE_URL, TERM_ELEMENT_NOASSERTION, TERM_ELEMENT_NONE, TERM_LICENSE_NOASSERTION, TERM_LICENSE_NONE, URI_VALUE_NOASSERTION, URI_VALUE_NONE -
Constructor Summary
Constructors Constructor Description SpdxPackage(String name, String comment, Annotation[] annotations, Relationship[] relationships, AnyLicenseInfo licenseConcluded, AnyLicenseInfo[] licenseInfosFromFiles, String copyrightText, String licenseComment, AnyLicenseInfo licenseDeclared, Checksum[] checksums, String description, String downloadLocation, SpdxFile[] files, String homepage, String originator, String packageFileName, SpdxPackageVerificationCode packageVerificationCode, String sourceInfo, String summary, String supplier, String versionInfo)SpdxPackage(String name, String comment, Annotation[] annotations, Relationship[] relationships, AnyLicenseInfo licenseConcluded, AnyLicenseInfo[] licenseInfosFromFiles, String copyrightText, String licenseComment, AnyLicenseInfo licenseDeclared, Checksum[] checksums, String description, String downloadLocation, SpdxFile[] files, String homepage, String originator, String packageFileName, SpdxPackageVerificationCode packageVerificationCode, String sourceInfo, String summary, String supplier, String versionInfo, boolean filesAnalyzed, ExternalRef[] externalRefs)SpdxPackage(String name, String comment, Annotation[] annotations, Relationship[] relationships, AnyLicenseInfo licenseConcluded, AnyLicenseInfo[] licenseInfosFromFiles, String copyrightText, String licenseComment, AnyLicenseInfo licenseDeclared, Checksum[] checksums, String description, String downloadLocation, SpdxFile[] files, String homepage, String originator, String packageFileName, SpdxPackageVerificationCode packageVerificationCode, String sourceInfo, String summary, String supplier, String versionInfo, boolean filesAnalyzed, ExternalRef[] externalRefs, String[] attributionText)SpdxPackage(String name, AnyLicenseInfo licenseConcluded, AnyLicenseInfo[] licenseInfosFromFiles, String copyrightText, AnyLicenseInfo licenseDeclared, String downloadLocation, SpdxFile[] files, SpdxPackageVerificationCode packageVerificationCode)SpdxPackage(IModelContainer modelContainer, org.apache.jena.graph.Node node) -
Method Summary
Modifier and Type Method Description voidaddChecksum(Checksum checksum)Add a checksum to the list of checksums for this packagevoidaddExternalRef(ExternalRef externalRef)voidaddFile(SpdxFile file)Add a file to the list of files attached to this packageSpdxPackageclone()SpdxPackageclone(Map<String,SpdxElement> clonedElementIds)Clones this element, but prevents infinite recursion by keeping track of all elements which have been clonedintcompareTo(SpdxPackage pkg)booleanequivalent(IRdfModel o)Returns true if the compare object contains properties which would be equal if they were contained in the same RDF Modelbooleanequivalent(IRdfModel o, boolean testRelationships)Test for equivalentorg.apache.jena.rdf.model.ResourcefindDuplicateResource(IModelContainer modelContainer, String uri)Search the model to see if there is a duplicate resource either based on the URI or based on other information.Checksum[]getChecksums()AnyLicenseInfogetConcludedLicenses()Deprecated.StringgetDeclaredCopyright()Deprecated.AnyLicenseInfogetDeclaredLicense()Deprecated.StringgetDeclaredName()Deprecated.StringgetDescription()StringgetDownloadLocation()StringgetDownloadUrl()Deprecated.ExternalRef[]getExternalRefs()StringgetFileName()Deprecated.SpdxFile[]getFiles()SpdxFile[]getFiles(boolean checkRelationships)StringgetHomepage()AnyLicenseInfogetLicenseDeclared()protected StringgetNamePropertyName()StringgetOriginator()StringgetPackageFileName()SpdxPackageVerificationCodegetPackageVerificationCode()voidgetPropertiesFromModel()Fetch all of the properties from the model and populate the local Java propertiesStringgetSha1()StringgetShortDescription()Deprecated.StringgetSourceInfo()StringgetSummary()StringgetSupplier()org.apache.jena.rdf.model.ResourcegetType(org.apache.jena.rdf.model.Model model)SpdxPackageVerificationCodegetVerificationCode()Deprecated.StringgetVersionInfo()booleanisFilesAnalyzed()voidpopulateModel()Populate the RDF model from the Java propertiesvoidsetChecksums(Checksum[] checksums)voidsetDescription(String description)voidsetDownloadLocation(String downloadLocation)voidsetExternalRefs(ExternalRef[] externalRefs)voidsetFiles(SpdxFile[] files)voidsetFilesAnalyzed(boolean filesAnalyzed)Set files Analyzed for the packagevoidsetHomepage(String homepage)voidsetLicenseDeclared(AnyLicenseInfo licenseDeclared)voidsetOriginator(String originator)voidsetPackageFileName(String packageFileName)voidsetPackageVerificationCode(SpdxPackageVerificationCode packageVerificationCode)voidsetSourceInfo(String sourceInfo)voidsetSummary(String summary)voidsetSupplier(String supplier)voidsetVersionInfo(String versionInfo)List<String>verify()Methods inherited from class org.spdx.rdfparser.model.SpdxItem
cloneLicenseConcluded, cloneLicenseInfosFromFiles, getAttributionText, getCopyrightText, getLicenseComment, getLicenseComments, getLicenseConcluded, getLicenseInfoFromFiles, getLicenseInfoFromFilesPropertyName, setAttributionText, setCopyrightText, setLicenseComment, setLicenseComments, setLicenseConcluded, setLicenseInfosFromFilesMethods inherited from class org.spdx.rdfparser.model.SpdxElement
addAnnotation, addNameToWarnings, addRelationship, arraysEquivalent, arraysEquivalent, cloneAnnotations, cloneRelationships, equivalentConsideringNull, equivalentConsideringNull, getAnnotations, getComment, getId, getName, getRelationships, getUri, setAnnotations, setComment, setId, setName, setRelationships, toStringMethods inherited from class org.spdx.rdfparser.model.RdfModelObject
addPropertyUriValue, addPropertyValue, addPropertyValue, addPropertyValue, addPropertyValue, addPropertyValue, addPropertyValue, addPropertyValue, createResource, createResource, equals, findAnnotationPropertyValues, findAnyLicenseInfoPropertyValue, findAnyLicenseInfoPropertyValues, findChecksumPropertyValue, findCreationInfoPropertyValue, findElementPropertyValue, findExternalDocRefPropertyValues, findExternalDocRefPropertyValues, findExternalRefPropertyValues, findIntPropertyValue, findMultipleChecksumPropertyValues, findMultipleDoapPropertyValues, findMultipleElementPropertyValues, findMultiplePropertyValues, findReferenceTypePropertyValue, findRelationshipPropertyValues, findReviewPropertyValues, findSinglePointerPropertyValue, findSinglePropertyValue, findStartEndPointerPropertyValues, findUriPropertyValue, findUriPropertyValues, findVerificationCodePropertyValue, getNode, hashCode, isRefreshOnGet, removePropertyValue, resourcesEqual, setMultipleObjectsForSameNode, setPropertyUriValue, setPropertyUriValues, setPropertyValue, setPropertyValue, setPropertyValue, setPropertyValue, setPropertyValue, setPropertyValue, setPropertyValue, setPropertyValue, setPropertyValue, setPropertyValue, setPropertyValue, setPropertyValue, setPropertyValue, setPropertyValue, setPropertyValue, setPropertyValue, setPropertyValue, setPropertyValues, setPropertyValues, setPropertyValues, setPropertyValues, setPropertyValues, setPropertyValues, setSingleObjectForSameNode
-
Constructor Details
-
SpdxPackage
public SpdxPackage(String name, String comment, Annotation[] annotations, Relationship[] relationships, AnyLicenseInfo licenseConcluded, AnyLicenseInfo[] licenseInfosFromFiles, String copyrightText, String licenseComment, AnyLicenseInfo licenseDeclared, Checksum[] checksums, String description, String downloadLocation, SpdxFile[] files, String homepage, String originator, String packageFileName, SpdxPackageVerificationCode packageVerificationCode, String sourceInfo, String summary, String supplier, String versionInfo, boolean filesAnalyzed, ExternalRef[] externalRefs)- Parameters:
name-comment-annotations-relationships-licenseConcluded-licenseInfosFromFiles-copyrightText-licenseComment-licenseDeclared-checksums-description-downloadLocation-files-homepage-originator-packageFileName-packageVerificationCode-sourceInfo-summary-supplier-versionInfo-filesAnalyzed-externalRefs-
-
SpdxPackage
public SpdxPackage(String name, String comment, Annotation[] annotations, Relationship[] relationships, AnyLicenseInfo licenseConcluded, AnyLicenseInfo[] licenseInfosFromFiles, String copyrightText, String licenseComment, AnyLicenseInfo licenseDeclared, Checksum[] checksums, String description, String downloadLocation, SpdxFile[] files, String homepage, String originator, String packageFileName, SpdxPackageVerificationCode packageVerificationCode, String sourceInfo, String summary, String supplier, String versionInfo) -
SpdxPackage
public SpdxPackage(String name, AnyLicenseInfo licenseConcluded, AnyLicenseInfo[] licenseInfosFromFiles, String copyrightText, AnyLicenseInfo licenseDeclared, String downloadLocation, SpdxFile[] files, SpdxPackageVerificationCode packageVerificationCode) -
SpdxPackage
public SpdxPackage(IModelContainer modelContainer, org.apache.jena.graph.Node node) throws InvalidSPDXAnalysisException- Parameters:
modelContainer-node-- Throws:
InvalidSPDXAnalysisException
-
SpdxPackage
public SpdxPackage(String name, String comment, Annotation[] annotations, Relationship[] relationships, AnyLicenseInfo licenseConcluded, AnyLicenseInfo[] licenseInfosFromFiles, String copyrightText, String licenseComment, AnyLicenseInfo licenseDeclared, Checksum[] checksums, String description, String downloadLocation, SpdxFile[] files, String homepage, String originator, String packageFileName, SpdxPackageVerificationCode packageVerificationCode, String sourceInfo, String summary, String supplier, String versionInfo, boolean filesAnalyzed, ExternalRef[] externalRefs, String[] attributionText)- Parameters:
name-comment-annotations-relationships-licenseConcluded-licenseInfosFromFiles-copyrightText-licenseComment-licenseDeclared-checksums-description-downloadLocation-files-homepage-originator-packageFileName-packageVerificationCode-sourceInfo-summary-supplier-versionInfo-filesAnalyzed-externalRefs-attributionText-
-
-
Method Details
-
getPropertiesFromModel
Description copied from class:RdfModelObjectFetch all of the properties from the model and populate the local Java properties- Overrides:
getPropertiesFromModelin classSpdxItem- Throws:
InvalidSPDXAnalysisException
-
findDuplicateResource
public org.apache.jena.rdf.model.Resource findDuplicateResource(IModelContainer modelContainer, String uri) throws InvalidSPDXAnalysisExceptionDescription copied from class:RdfModelObjectSearch the model to see if there is a duplicate resource either based on the URI or based on other information. Subclasses may choose to override this method to prevent duplicate resource from being created with the same properties.- Overrides:
findDuplicateResourcein classRdfModelObject- Returns:
- Any duplicate resource found. Null if no duplicate resource was found.
- Throws:
InvalidSPDXAnalysisException
-
populateModel
Description copied from class:RdfModelObjectPopulate the RDF model from the Java properties- Overrides:
populateModelin classSpdxItem- Throws:
InvalidSPDXAnalysisException
-
getNamePropertyName
- Overrides:
getNamePropertyNamein classSpdxElement- Returns:
- the property name used for the Name property. Override this function if using a subproperty of SPDX Name
-
getType
public org.apache.jena.rdf.model.Resource getType(org.apache.jena.rdf.model.Model model) -
isFilesAnalyzed
- Returns:
- true if filesAnalyzed flag is set
- Throws:
InvalidSPDXAnalysisException
-
setFilesAnalyzed
public void setFilesAnalyzed(boolean filesAnalyzed)Set files Analyzed for the package- Parameters:
filesAnalyzed-
-
getLicenseDeclared
- Returns:
- the licenseDeclared
- Throws:
InvalidSPDXAnalysisException
-
setLicenseDeclared
- Parameters:
licenseDeclared- the licenseDeclared to set- Throws:
InvalidSPDXAnalysisException
-
getChecksums
- Returns:
- the checksums
- Throws:
InvalidSPDXAnalysisException
-
setChecksums
- Parameters:
checksums- the checksums to set- Throws:
InvalidSPDXAnalysisException
-
addChecksum
Add a checksum to the list of checksums for this package- Parameters:
checksum-- Throws:
InvalidSPDXAnalysisException
-
getDescription
- Returns:
- the description
-
setDescription
- Parameters:
description- the description to set
-
getDownloadLocation
- Returns:
- the downloadLocation
-
setDownloadLocation
- Parameters:
downloadLocation- the downloadLocation to set
-
getHomepage
- Returns:
- the homepage
-
setHomepage
- Parameters:
homepage- the homepage to set
-
getOriginator
- Returns:
- the originator
-
setOriginator
- Parameters:
originator- the originator to set
-
getPackageFileName
- Returns:
- the packageFileName
-
setPackageFileName
- Parameters:
packageFileName- the packageFileName to set
-
getPackageVerificationCode
- Returns:
- the packageVerificationCode
- Throws:
InvalidSPDXAnalysisException
-
setPackageVerificationCode
public void setPackageVerificationCode(SpdxPackageVerificationCode packageVerificationCode) throws InvalidSPDXAnalysisException- Parameters:
packageVerificationCode- the packageVerificationCode to set- Throws:
InvalidSPDXAnalysisException
-
getSourceInfo
- Returns:
- the sourceInfo
-
setSourceInfo
- Parameters:
sourceInfo- the sourceInfo to set
-
getSummary
- Returns:
- the summary
-
setSummary
- Parameters:
summary- the summary to set
-
getSupplier
- Returns:
- the supplier
-
setSupplier
- Parameters:
supplier- the supplier to set
-
getVersionInfo
- Returns:
- the versionInfo
-
setVersionInfo
- Parameters:
versionInfo- the versionInfo to set
-
getExternalRefs
- Returns:
- the externalRefs
- Throws:
InvalidSPDXAnalysisException
-
setExternalRefs
- Parameters:
externalRefs- the externalRefs to set- Throws:
InvalidSPDXAnalysisException
-
getFiles
- Returns:
- the files
- Throws:
InvalidSPDXAnalysisException
-
getFiles
- Parameters:
checkRelationships- - if true, compare relationships when determining if the files need to be loaded- Returns:
- the files
- Throws:
InvalidSPDXAnalysisException
-
setFiles
- Parameters:
files- the files to set- Throws:
InvalidSPDXAnalysisException
-
addFile
Add a file to the list of files attached to this package- Parameters:
file-- Throws:
InvalidSPDXAnalysisException
-
equivalent
Description copied from interface:IRdfModelReturns true if the compare object contains properties which would be equal if they were contained in the same RDF Model- Specified by:
equivalentin interfaceIRdfModel- Overrides:
equivalentin classSpdxItem- Returns:
-
equivalent
Description copied from class:SpdxElementTest for equivalent- Overrides:
equivalentin classSpdxItemtestRelationships- If true, test relationships- Returns:
-
clone
Description copied from class:SpdxElementClones this element, but prevents infinite recursion by keeping track of all elements which have been cloned -
clone
-
verify
-
getDeclaredName
Deprecated.This method has been replaced by getName() to be consistent with the spec property name- Returns:
-
getDownloadUrl
Deprecated.This method has been replaced by getDownloadLocation() to be consistent with the spec property name- Returns:
-
getShortDescription
Deprecated.This method has been replaced by getSummary() to be consistent with the spec property name- Returns:
-
getFileName
Deprecated.This method has been replaced by getPackageFileName() to be consistent with the spec property name- Returns:
-
getVerificationCode
@Deprecated public SpdxPackageVerificationCode getVerificationCode() throws InvalidSPDXAnalysisExceptionDeprecated.This method has been replaced by getPackageVerificationCode() to be consistent with the spec property name- Returns:
- Throws:
InvalidSPDXAnalysisException
-
getDeclaredCopyright
Deprecated.This method has been replaced by getDeclaredCopyright() to be consistent with the spec property name- Returns:
-
getDeclaredLicense
Deprecated.This method has been replaced by getLicenseDeclared() to be consistent with the spec property name- Returns:
- Throws:
InvalidSPDXAnalysisException
-
getConcludedLicenses
Deprecated.This method has been replaced by getLicenseConcluded() to be consistent with the spec property name- Returns:
-
compareTo
- Specified by:
compareToin interfaceComparable<SpdxPackage>
-
getSha1
- Returns:
- the Sha1 checksum value for this package, or a blank string if no sha1 checksum has been set
-
addExternalRef
- Parameters:
externalRef-- Throws:
InvalidSPDXAnalysisException
-