Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/Z-Bolt/OctoScreen.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'octoprintApis/StatusMapping.go')
-rwxr-xr-xoctoprintApis/StatusMapping.go23
1 files changed, 23 insertions, 0 deletions
diff --git a/octoprintApis/StatusMapping.go b/octoprintApis/StatusMapping.go
new file mode 100755
index 0000000..d49ed4b
--- /dev/null
+++ b/octoprintApis/StatusMapping.go
@@ -0,0 +1,23 @@
+package octoprintApis
+
+import (
+ // "errors"
+ "fmt"
+ // "io"
+ // "io/ioutil"
+ // "net/http"
+ // "net/url"
+ // "time"
+)
+
+
+type StatusMapping map[int]string
+
+func (this *StatusMapping) Error(code int) error {
+ err, ok := (*this)[code]
+ if ok {
+ return fmt.Errorf(err)
+ }
+
+ return nil
+}