(ctx context.Context, tag string, reset bool)
| 114 | } |
| 115 | |
| 116 | func (x *XrayHandler) GetInboundStats(ctx context.Context, tag string, reset bool) (*common.StatResponse, error) { |
| 117 | if tag == "" { |
| 118 | return nil, errors.New("tag required") |
| 119 | } |
| 120 | resp, err := x.QueryStats(ctx, fmt.Sprintf("inbound>>>%s>>>", tag), reset) |
| 121 | if err != nil { |
| 122 | return nil, err |
| 123 | } |
| 124 | |
| 125 | return buildStatResponse(resp.GetStat()), nil |
| 126 | } |
| 127 | |
| 128 | func (x *XrayHandler) GetOutboundStats(ctx context.Context, tag string, reset bool) (*common.StatResponse, error) { |
| 129 | if tag == "" { |
no test coverage detected