18 lines
237 B
Go
18 lines
237 B
Go
|
|
package jsonextractor
|
||
|
|
|
||
|
|
import (
|
||
|
|
"context"
|
||
|
|
)
|
||
|
|
|
||
|
|
type Result struct {
|
||
|
|
value string
|
||
|
|
}
|
||
|
|
|
||
|
|
func NewResult(value string) *Result {
|
||
|
|
return &Result{value}
|
||
|
|
}
|
||
|
|
|
||
|
|
func (r *Result) GetValue(ctx context.Context) (string, error) {
|
||
|
|
return r.value, nil
|
||
|
|
}
|