func NewNode(parent *Node, fi os.FileInfo, maxFileSize int64) (node *Node, err error) {
	if fi == nil {
		return nil, nil
	}
	var (
		logp    = "NewNode"
		sysPath string
		relPath string
	)
	sysPath = filepath.Join(parent.SysPath, fi.Name())
	relPath = path.Join(parent.Path, fi.Name())
	node = &Node{
		SysPath: sysPath,
		Path:    relPath,
		name:    fi.Name(),
		modTime: fi.ModTime(),
		mode:    fi.Mode(),
		size:    fi.Size(),
		Parent:  parent,
	}
	node.generateFuncName(sysPath)
	if node.mode.IsDir() {
		node.size = 0
		return node, nil
	}
	if fi.Mode()&os.ModeSymlink != 0 {
		sysPath, err = filepath.EvalSymlinks(sysPath)
		if err != nil {
			return nil, fmt.Errorf("%s: %w", logp, err)
		}
		fi, err = os.Lstat(sysPath)
		if err != nil {
			return nil, fmt.Errorf("%s: %w", logp, err)
		}
		node.mode = fi.Mode()
		if node.mode.IsDir() {
			node.size = 0
			return node, nil
		}
		node.size = fi.Size()
	}
	err = node.updateContent(maxFileSize)
	if err != nil {
		return nil, fmt.Errorf("%s: %w", logp, err)
	}
	err = node.updateContentType()
	if err != nil {
		return nil, fmt.Errorf("%s: %w", logp, err)
	}
	return node, nil
}
NewNode create a new node based on file information "fi".

The parent parameter is required to allow valid system path generated for
new node.

If maxFileSize is greater than zero, the file content and its type will be
saved in node as Content and ContentType.
package memfs
import (
	"bytes"
	"compress/gzip"
	"encoding/base64"
	"errors"
	"fmt"
	"io"
	"io/ioutil"
	"mime"
	"net/http"
	"os"
	"path"
	"path/filepath"
	"time"
	"github.com/shuLhan/share/lib/ascii"
	libbytes "github.com/shuLhan/share/lib/bytes"
)
var (
	errOffset = errors.New("Seek: invalid offset")
	errWhence = errors.New("Seek: invalid whence")
)
type Node struct {
	os.FileInfo
	http.File
	SysPath         string   
	Path            string   
	Content         []byte   
	ContentType     string   
	ContentEncoding string   
	Parent          *Node    
	Childs          []*Node  
	GenFuncName     string   
	name    string       
	modTime time.Time    
	mode    os.FileMode  
	size    int64        
	plainv  []byte       
	lowerv  []byte       
	off     int64        
}