1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
|
// +build codegen
package api
type examplesBuilder interface {
BuildShape(*ShapeRef, map[string]interface{}, bool) string
BuildList(string, string, *ShapeRef, []interface{}) string
BuildComplex(string, string, *ShapeRef, map[string]interface{}) string
GoType(*ShapeRef, bool) string
Imports(*API) string
}
type defaultExamplesBuilder struct {
ShapeValueBuilder
}
func (builder defaultExamplesBuilder) Imports(a *API) string {
return `"fmt"
"strings"
"time"
"` + SDKImportRoot + `/aws"
"` + SDKImportRoot + `/aws/awserr"
"` + SDKImportRoot + `/aws/session"
"` + SDKImportRoot + `/service/` + a.PackageName() + `"
`
}
|