Package org.spdx.storage.listedlicense
Class ExceptionJson
java.lang.Object
org.spdx.storage.listedlicense.ExceptionJson
public class ExceptionJson extends Object
Simple POJO to hold the license exception data loaded from a JSON file
Licenses in the JSON format can be found at spdx.org/licenses/[exceptionid].json
- Author:
- Gary O'Neall
-
Constructor Summary
Constructors Constructor Description ExceptionJson()ExceptionJson(String id) -
Method Summary
Modifier and Type Method Description booleanaddPrimitiveValueToList(String propertyName, Object value)voidaddValueToList(String propertyName, String valueId, String type)voidclearPropertyValueList(String propertyName)voidcopyFrom(ListedLicenseException fromException)List<String>getPropertyValueNames()ObjectgetValue(String propertyName)List<?>getValueList(String propertyName)booleanisCollectionMembersAssignableTo(String propertyName, Class<?> clazz)booleanisCollectionProperty(String propertyName)booleanisPropertyValueAssignableTo(String propertyName, Class<?> clazz)booleanremovePrimitiveValueToList(String propertyName, Object value)voidremoveProperty(String propertyName)voidsetPrimativeValue(String propertyName, Object value)voidsetTypedProperty(String propertyName, String valueId, String type)
-
Constructor Details
-
ExceptionJson
-
ExceptionJson
public ExceptionJson()
-
-
Method Details
-
getPropertyValueNames
-
setTypedProperty
public void setTypedProperty(String propertyName, String valueId, String type) throws InvalidSpdxPropertyException- Throws:
InvalidSpdxPropertyException
-
setPrimativeValue
public void setPrimativeValue(String propertyName, Object value) throws InvalidSpdxPropertyException- Throws:
InvalidSpdxPropertyException
-
clearPropertyValueList
- Throws:
InvalidSpdxPropertyException
-
addValueToList
public void addValueToList(String propertyName, String valueId, String type) throws InvalidSpdxPropertyException- Throws:
InvalidSpdxPropertyException
-
addPrimitiveValueToList
public boolean addPrimitiveValueToList(String propertyName, Object value) throws InvalidSpdxPropertyException- Throws:
InvalidSpdxPropertyException
-
getValueList
- Throws:
InvalidSpdxPropertyException
-
getValue
- Throws:
InvalidSpdxPropertyException
-
removeProperty
- Throws:
InvalidSpdxPropertyException
-
copyFrom
- Throws:
InvalidSPDXAnalysisException
-
removePrimitiveValueToList
public boolean removePrimitiveValueToList(String propertyName, Object value) throws InvalidSpdxPropertyException- Throws:
InvalidSpdxPropertyException
-
isPropertyValueAssignableTo
public boolean isPropertyValueAssignableTo(String propertyName, Class<?> clazz) throws InvalidSpdxPropertyException- Throws:
InvalidSpdxPropertyException
-
isCollectionMembersAssignableTo
-
isCollectionProperty
-