func CreateFingerPrint(releaseName, version, ns, chartName string) string {
	return fmt.Sprintf("%s_%s_%s_%s", releaseName, version, ns, chartName)
}
CreateFingerPrint creates a fingerprint from the specific strings.
package pkg
import (
	"bytes"
	"encoding/json"
	"fmt"
)
type tristate int
const (
	Unknown tristate = iota
	Present
	Absent
)
type Pkg struct {
	ReleaseName string  
	Version     string  
	Namespace   string  
	ChartName   string  
	DependsRel         []*PkgRel  
	DependsOptionalRel []*PkgRel  
	Repository         string     
	ParentChartPath    string     
	CurrentState       tristate   
	DesiredState       tristate   
	PinnedVer          tristate   
}
type PkgRel struct {
	ReleaseName string
	Namespace   string
	SemverRange string  
	ChartName   string
}
func NewPkg(relName, chartName, version, namespace string,
	currentState, desiredState, pinnedVer tristate,
	repo, parentChartPath string) *Pkg {
	p := &Pkg{
		ReleaseName:        relName,
		Version:            version,
		Namespace:          namespace,
		ChartName:          chartName,
		DependsRel:         []*PkgRel{},
		DependsOptionalRel: []*PkgRel{},
		Repository:         repo,
		ParentChartPath:    parentChartPath,
		CurrentState:       currentState,
		DesiredState:       desiredState,
		PinnedVer:          pinnedVer,
	}
	return p
}
func NewPkgMock(name, version, namespace string,
	depends, dependsOptional []*PkgRel,
	currentState, desiredState tristate) *Pkg {
	p := NewPkg(name, name, version, namespace,
		currentState, desiredState, Unknown, "ourrepo", "")
	p.DependsRel = depends
	p.DependsOptionalRel = dependsOptional
	return p
}
func (p *Pkg) JSON() ([]byte, error) {
	buffer := &bytes.Buffer{}
	encoder := json.NewEncoder(buffer)
	encoder.SetEscapeHTML(false)
	err := encoder.Encode(p)
	return buffer.Bytes(), err
}
func (p *Pkg) GetFingerPrint() string {
	return fmt.Sprintf("%s_%s_%s_%s", p.ReleaseName, p.Version, p.Namespace, p.ChartName)
}