]> git.lizzy.rs Git - go-anidb.git/blobdiff - anidb.go
anidb: Simplify documentation
[go-anidb.git] / anidb.go
index 812f4c4704e6d68a5366154b857d0a4d79466f74..bfe81d1ce1aa37867d7dbfd4e9da6fb3853c8d96 100644 (file)
--- a/anidb.go
+++ b/anidb.go
@@ -5,6 +5,11 @@ import (
        "time"
 )
 
+// Main struct for the client, contains all non-shared state.
+//
+// All ObjectByKey methods (AnimeByID, GroupByName, etc) first try to read
+// from the cache. If the sought object isn't cached, or if the cache is
+// stale, then the appropriate API is queried.
 type AniDB struct {
        Timeout time.Duration // Timeout for the various calls (default: 45s)