func (f *CachedFile) EnvFile(fs filestore.FileStore) (envexec.File, error) {
	_, fd := fs.Get(f.FileID)
	if fd == nil {
		return nil, fmt.Errorf("file not exists with id %v", f.FileID)
	}
	return fd, nil
}
EnvFile prepares file for envexec file
package worker
import (
	"bytes"
	"fmt"
	"github.com/criyle/go-judge/envexec"
	"github.com/criyle/go-judge/filestore"
)
type CmdFile interface {
	EnvFile(fs filestore.FileStore) (envexec.File, error)
	String() string
}
var (
	_ CmdFile = &LocalFile{}
	_ CmdFile = &MemoryFile{}
	_ CmdFile = &CachedFile{}
	_ CmdFile = &Collector{}
)
type LocalFile struct {
	Src string
}
func (f *LocalFile) EnvFile(fs filestore.FileStore) (envexec.File, error) {
	return envexec.NewFileInput(f.Src), nil
}
func (f *LocalFile) String() string {
	return fmt.Sprintf("local:%s", f.Src)
}
type MemoryFile struct {
	Content []byte
}
func (f *MemoryFile) EnvFile(fs filestore.FileStore) (envexec.File, error) {
	return envexec.NewFileReader(bytes.NewReader(f.Content), false), nil
}
func (f *MemoryFile) String() string {
	return fmt.Sprintf("memory:(len:%d)", len(f.Content))
}
type CachedFile struct {
	FileID string
}