summaryrefslogtreecommitdiffhomepage
path: root/src/mintage/mintage.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/mintage/mintage.go')
-rw-r--r--src/mintage/mintage.go40
1 files changed, 40 insertions, 0 deletions
diff --git a/src/mintage/mintage.go b/src/mintage/mintage.go
new file mode 100644
index 0000000..cc94de7
--- /dev/null
+++ b/src/mintage/mintage.go
@@ -0,0 +1,40 @@
+package mintage
+
+type Data struct {
+ Standard []SRow
+ Commemorative []CRow
+}
+
+type SRow struct {
+ Year int
+ Mintmark string
+ Mintages [denoms]int
+}
+
+type CRow struct {
+ Year int
+ Name string
+ Mintmark string
+ Mintage int
+}
+
+const (
+ TypeCirc = iota
+ TypeNifc
+ TypeProof
+)
+
+const (
+ Unknown = -iota - 1
+ Invalid
+)
+
+const denoms = 8
+
+var cache map[string][3]Data = make(map[string][3]Data)
+
+func ClearCache(country string) {
+ if _, ok := cache[country]; ok {
+ delete(cache, country)
+ }
+}