func NewFileServeHandler(id, dir string) rest.ResourceHandler {
	pdir := filepath.FromSlash(dir)
	if !strings.HasSuffix(pdir, string(filepath.Separator)) {
		pdir += string(filepath.Separator)
	}
	return &fileServeHandler{id, pdir}
}
// NewFileServeHandler creates a new handler serving the files names
// by the resource ID part out of the passed directory.
NewFileServeHandler creates a new handler serving the files names
by the resource ID part out of the passed directory.
// NewFileServeHandler creates a new handler serving the files names // by the resource ID part out of the passed directory .
func NewFileServeHandler(id, dir string) rest.ResourceHandler {
	pdir := filepath.FromSlash(dir)
	if !strings.HasSuffix(pdir, string(filepath.Separator)) {
		pdir += string(filepath.Separator)
	}
	return &fileServeHandler{id, pdir}
}
func NewFileServeHandler ( id , dir string ) rest . ResourceHandler { pdir := filepath . FromSlash ( dir ) if ! strings . HasSuffix ( pdir , string ( filepath . Separator ) ) { pdir += string ( filepath . Separator ) } return & fileServeHandler { id , pdir } }
NewFileServeHandler creates a new handler serving the files names
by the resource ID part out of the passed directory.
NewFileServeHandler creates a new handler serving the files names by the resource ID part out of the passed directory .