Klasse License
java.lang.Object
org.apache.tools.ant.ProjectComponent
org.apache.tools.ant.types.DataType
org.apache.ant.cyclonedx.License
- Alle implementierten Schnittstellen:
Cloneable
public class License
extends org.apache.tools.ant.types.DataType
A license element to be attached to a component.
Licenses are required to have an id or a name attribute. Due to
Ant's own usage of the id attribute the SBOM id of the
license is called licenseId here.
The CycloneDX specification supports more information for a license than this type currently exposes.
This class is a type exposed by this Ant Library. When using the
inherited refid attribute it can reference an instance
defined previously - in which case no child elements or other
attributes are allowed.
-
Feldübersicht
Von Klasse geerbte Felder org.apache.tools.ant.types.DataType
checked, refVon Klasse geerbte Felder org.apache.tools.ant.ProjectComponent
description, location, project -
Konstruktorübersicht
Konstruktoren -
Methodenübersicht
Modifikator und TypMethodeBeschreibungvoidaddConfiguredUrl(org.apache.tools.ant.types.resources.URLResource url) Sets the url of the license.protected LicensegetRef()Perform the check for circular references and return the referenced License.voidsetLicenseId(String id) Sets theidof the license.voidSets the name of the license.org.cyclonedx.model.LicenseMaps the license to its CycloneDX counterpart.Von Klasse geerbte Methoden org.apache.tools.ant.types.DataType
checkAttributesAllowed, checkChildrenAllowed, circularReference, clone, dieOnCircularReference, dieOnCircularReference, dieOnCircularReference, getCheckedRef, getCheckedRef, getCheckedRef, getCheckedRef, getCheckedRef, getDataTypeName, getRefid, invokeCircularReferenceCheck, isChecked, isReference, noChildrenAllowed, pushAndInvokeCircularReferenceCheck, setChecked, setRefid, tooManyAttributes, toStringVon Klasse geerbte Methoden org.apache.tools.ant.ProjectComponent
getDescription, getLocation, getProject, log, log, setDescription, setLocation, setProject
-
Konstruktordetails
-
License
public License()
-
-
Methodendetails
-
setLicenseId
-
setName
-
addConfiguredUrl
public void addConfiguredUrl(org.apache.tools.ant.types.resources.URLResource url) Sets the url of the license.Even though this is a nested element of the license element, at most one child is allowed.
- Parameter:
url- url of license
-
toCycloneDxLicense
public org.cyclonedx.model.License toCycloneDxLicense()Maps the license to its CycloneDX counterpart.- Gibt zurück:
- CycloneDX version of this instance
-
getRef
Perform the check for circular references and return the referenced License.- Gibt zurück:
License.
-