Another way that you can use (based on a recursive map[string]T - where
T is an interface type - can be seen here where I use it create a
filesystem of arbitrary behaviours).

https://github.com/ev3go/sisyphus

The general case though uses map[string]interface{}. Each time you want
to add a layer at "basepath", you navigate the tree and add a newly made
map[string]interface{} at that key. See
https://github.com/ev3go/sisyphus/blob/master/fs.go for code that does
this kind of thing.

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to