diff --git a/httplib.go b/httplib/httplib.go similarity index 99% rename from httplib.go rename to httplib/httplib.go index 25d010e0..15a74fda 100644 --- a/httplib.go +++ b/httplib/httplib.go @@ -1,4 +1,4 @@ -package beego +package httplib import ( "bytes" diff --git a/httplib_test.go b/httplib/httplib_test.go similarity index 96% rename from httplib_test.go rename to httplib/httplib_test.go index ea4a7f9a..00392318 100644 --- a/httplib_test.go +++ b/httplib/httplib_test.go @@ -1,4 +1,4 @@ -package beego +package httplib import ( "io/ioutil" diff --git a/safemap.go b/safemap.go index 3ec441fb..73af9e8a 100644 --- a/safemap.go +++ b/safemap.go @@ -56,3 +56,9 @@ func (m *BeeMap) Delete(k interface{}) { defer m.lock.Unlock() delete(m.bm, k) } + +func (m *BeeMap) Items() map[interface{}]interface{} { + m.lock.RLock() + defer m.lock.RUnlock() + return m.bm +}