func NewPolicyFromBytes(data []byte) (*Policy, error) {
	p := Policy{}
	if err := json.Unmarshal(data, &p); err != nil {
		return nil, InvalidPolicyFormatError(err.Error())
	}
	return &p, nil
}
func NewPolicyFromBytes(data []byte) (*Policy, error) {
	p := Policy{}
	if err := json.Unmarshal(data, &p); err != nil {
		return nil, InvalidPolicyFormatError(err.Error())
	}
	return &p, nil
}
func NewPolicyFromBytes ( data [ ] byte ) ( * Policy , error ) { p := Policy { } if err := json . Unmarshal ( data , & p ) ; err != nil { return nil , InvalidPolicyFormatError ( err . Error ( ) ) } return & p , nil }
// NewPolicyFromBytes returns a policy parsed from the specified blob.
// Use this function instead of calling json.Unmarshal directly.
NewPolicyFromBytes returns a policy parsed from the specified blob . Use this function instead of calling json . Unmarshal directly .