Skip to content

Commit

Permalink
Add readme badges
Browse files Browse the repository at this point in the history
  • Loading branch information
TheoBrigitte committed Nov 14, 2024
1 parent 8913fb4 commit 86834be
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,21 @@
# ExpiryMap
<p align="center">
<a href="https://pkg.go.dev/github.com/TheoBrigitte/expirymap"><img src="https://pkg.go.dev/badge/github.com/TheoBrigitte/expirymap.svg" alt="Go Reference"></a>
<a href="https://github.com/TheoBrigitte/expirymap/actions/workflows/test.yml"><img src="https://github.com/TheoBrigitte/expirymap/actions/workflows/test.yml/badge.svg" alt="Github action"></a>
<a href="github.com/TheoBrigitte/expirymap/releases"><img src="https://img.shields.io/github/release/TheoBrigitte/expirymap.svg" alt="Latest Release"></a>
</p>

## ExpiryMap

This Go package provides a map that automatically removes entries after a given expiry delay.

## Features
### Features

* The map key can be any comparable type
* The map value can be any type
* The map is safe for concurrent use
* The expiry delay is specified as a `time.Duration` value

## Methods
### Methods

* NewExpiryMap - creates a new ExpiryMap
* Get, Set, Delete - standard map operations
Expand All @@ -18,6 +24,6 @@ This Go package provides a map that automatically removes entries after a given
* Clear - removes all entries from the map
* Stop - stops the background goroutine that removes expired entries

## Example
### Example

See [example/simple/simple.go](./example/simple/simple.go)

0 comments on commit 86834be

Please sign in to comment.