Skip to content

Commit

Permalink
Add README docs
Browse files Browse the repository at this point in the history
  • Loading branch information
n1nj4t4nuk1 committed Sep 28, 2023
1 parent b4e1f0e commit 9eb5a71
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ A collection of Value Objects to save time by generalizing types and format vali
* [ISO Date](#iso-date)
* [Security value-objects](#security-value-objects)
* [CVE](#cve)
* [Nullable CVE](#nullable-cve)
* [CPE](#cpe)

# Value-objects
Expand Down Expand Up @@ -187,6 +188,20 @@ my_cve = Cve('CVE-2014-9418')
my_cve.value() # returns -> 'CVE-2014-9418'
```

### Nullable CVE

```python
from pyvalueobjects import NullableCve

# Creation
my_cve = NullableCve('CVE-2014-9418')
my_null_cve = NullableCve(None)

# Getting raw value
my_cve.value() # returns -> 'CVE-2014-9418'
my_null_cve.value() # returns -> None
```

### CPE

```python
Expand Down

0 comments on commit 9eb5a71

Please sign in to comment.