func (c *ClientWriter) WriteTypeSectionHeader(w io.Writer) {
	fmt.Fprintf(w, "\n/****** Data Types ******/\n\n\n")
}
WriteTypeSectionHeader writes the separator between resources and data types.
package writers
import (
	"fmt"
	"io"
	"strings"
	"text/template"
	"github.com/rightscale/rsc/gen"
)
type ClientWriter struct {
	headerTmpl   *template.Template
	resourceTmpl *template.Template
}
func NewClientWriter() (*ClientWriter, error) {
	funcMap := template.FuncMap{
		"comment":           comment,
		"commandLine":       commandLine,
		"parameters":        parameters,
		"paramsInitializer": paramsInitializer,
		"blankCondition":    blankCondition,
		"stripStar":         stripStar,
	}
	headerT, err := template.New("header-client").Funcs(funcMap).Parse(headerTmpl)
	if err != nil {
		return nil, err
	}
	resourceT, err := template.New("resource-client").Funcs(funcMap).Parse(resourceTmpl)
	if err != nil {
		return nil, err
	}
	return &ClientWriter{
		headerTmpl:   headerT,
		resourceTmpl: resourceT,
	}, nil
}
func (c *ClientWriter) WriteHeader(pkg, version string, needTime, needJSON bool, w io.Writer) error {
	ctx := map[string]interface{}{
		"Pkg":        pkg,
		"APIVersion": version,
		"NeedTime":   needTime,
		"NeedJSON":   needJSON,
	}
	return c.headerTmpl.Execute(w, ctx)
}
func (c *ClientWriter) WriteResourceHeader(name string, w io.Writer) {
	fmt.Fprintf(w, "/****** %s ******/\n\n", name)
}