| "v.io/core/veyron2/context" |
| "v.io/core/veyron2/naming" |
| // GlobName calls __Glob on the given object with the given pattern and returns |
| // a sorted list of matching object names, or an error. |
| func GlobName(ctx *context.T, name, pattern string) ([]string, error) { |
| client := veyron2.GetClient(ctx) |
| call, err := client.StartCall(ctx, name, ipc.GlobMethod, []interface{}{pattern}) |
| var gr naming.VDLGlobReply |
| switch err := call.Recv(&gr); err { |
| case naming.VDLGlobReplyEntry: |
| results = append(results, v.Value.Name) |
| if err := call.Finish(); err != nil { |