func slice(conn *client.Conn, args []string) { for i, item := range conn.Slice([]byte(args[1]), []byte(args[2]), []byte(args[3]), true, false) { fmt.Printf("%v: %v => %v\n", i, string(item.Key), decode(item.Value)) } }