Ë
    ¨Ü–i*  ã                   ó†   — d Z dgZddlmZmZ ddlmZmZ ddlm	Z
mZ ddlmZmZ erdd	lmZmZ dd
lmZmZ  G d„ d«      Zy)zLicense related factoriesÚLicenseFactoryé    )ÚTYPE_CHECKINGÚOptionalé   )ÚDisjunctiveLicenseÚLicenseExpression)Úfixup_idÚis_expressioné   )Ú!InvalidLicenseExpressionExceptionÚInvalidSpdxLicenseException)ÚAttachedTextÚXsUri)ÚLicenseÚLicenseAcknowledgementc                   óØ   — e Zd ZdZddddœdeded   ded   d	ed
   ddf
d„Zddœdeded
   defd„Zddddœdeded   ded   ded
   de	f
d„Z
ddddœdeded   ded   ded
   de	f
d„Zy)r   z5Factory for :class:`cyclonedx.model.license.License`.N)Úlicense_textÚlicense_urlÚlicense_acknowledgementÚvaluer   r   r   r   r   r   Úreturnr   c                ó¼   — 	 | j                  ||||¬«      S # t        $ r Y nw xY w	 | j                  ||¬«      S # t        $ r Y nw xY w| j	                  ||||¬«      S )z>Make a :class:`cyclonedx.model.license.License` from a string.©ÚtextÚurlÚacknowledgement©r   )Úmake_with_idr   Úmake_with_expressionr   Úmake_with_name)Úselfr   r   r   r   s        úg/var/www/html/content-pipeline/venv/lib/python3.12/site-packages/cyclonedx/contrib/license/factories.pyÚmake_from_stringzLicenseFactory.make_from_string$   s›   € ð	Ø×$Ñ$ UØ*6Ø)4Ø5Lð %ó Nð Nøô +ò 	Ùð	úð	Ø×,Ñ,¨UØ=Tð -ó Vð Vøä0ò 	Ùð	úà×"Ñ" 5Ø(4Ø'2Ø3Jð #ó Lð 	Ls   ‚ —	#¢#§: º	AÁAr   Ú
expressionr   c                óH   — t        |«      rt        ||¬«      S t        |«      ‚)a  Make a :class:`cyclonedx.model.license.LicenseExpression` with a compound expression.

        Utilizes :func:`cyclonedx.spdx.is_expression`.

        :raises InvalidLicenseExpressionException: if param `value` is not known/supported license expression
        r   )Úis_spdx_expressionr   r   )r!   r$   r   s      r"   r   z#LicenseFactory.make_with_expression;   s$   € ô ˜jÔ)Ü$ ZÀÔQÐQÜ/°
Ó;Ð;ó    r   Úspdx_idr   r   c                óP   — t        |«      }|€t        |«      ‚t        ||||¬«      S )zµMake a :class:`cyclonedx.model.license.DisjunctiveLicense` from an SPDX-ID.

        :raises InvalidSpdxLicenseException: if param `spdx_id` was not known/supported SPDX-ID
        )Úidr   r   r   )Ú
spdx_fixupr   r   )r!   r(   r   r   r   Úspdx_license_ids         r"   r   zLicenseFactory.make_with_idH   s1   € ô % WÓ-ˆØÐ"Ü-¨gÓ6Ð6Ü! _¸4ÀSÐZiÔjÐjr'   Únamec                ó    — t        ||||¬«      S )zGMake a :class:`cyclonedx.model.license.DisjunctiveLicense` with a name.)r-   r   r   r   )r   )r!   r-   r   r   r   s        r"   r    zLicenseFactory.make_with_nameV   s   € ô " t°$¸CÐQ`ÔaÐar'   )Ú__name__Ú
__module__Ú__qualname__Ú__doc__Ústrr   r#   r   r   r   r   r    © r'   r"   r   r   !   s#  „ Ù?ð CGØ:>ØW[òL cð LØ'/°Ñ'?ðLà&.¨wÑ&7ðLð 3;Ð;SÑ2TðLð (ó	Lð0 TXò<¨sð <Ø.6Ð7OÑ.Pð<à"3ó<ð 7;Ø.2ØKOòk Cð kØ# NÑ3ðkà" 7Ñ+ðkð '/Ð/GÑ&Hðkð -ó	kð 9=Ø04ØMQòb 3ð bØ% nÑ5ðbà$ WÑ-ðbð )1Ð1IÑ(Jðbð /ô	br'   N)r2   Ú__all__Útypingr   r   Úmodel.licenser   r   Úspdxr	   r+   r
   r&   Ú
exceptionsr   r   Úmodelr   r   r   r   r   r4   r'   r"   ú<module>r;      s3   ðñ$  àÐ
€ç *ç Bß Oß Váß,ß@÷;bò ;br'   