diff --git a/internal/data/data.go b/internal/data/data.go new file mode 100644 index 0000000..b7989aa --- /dev/null +++ b/internal/data/data.go @@ -0,0 +1,34 @@ +// Copyright 2024 Matthew Rich . All rights reserved. + +package data + +import ( + "context" +) + +type Validator interface { + Validate() error +} + +type Creator interface { + Create(context.Context) error +} + +type Reader interface { + Read(context.Context) ([]byte, error) +} + +type Updater interface { + Update(context.Context) error +} + +type Deleter interface { + Delete(context.Context) error +} + +type Crudder struct { + Creator + Reader + Updater + Deleter +}