// NewReference will create and initialize a new Reference value
346809
func NewReference(name string, section *Section) *Reference {
	return &Reference{
		section: section,
		name:    name,
	}
}
782537
func (s *BatchListObjectChildren) SetObjectReference(v *ObjectReference) *BatchListObjectChildren {
	s.ObjectReference = v
	return s
}
455747
func (l *fsLoader) JsonReference() (gojsonreference.JsonReference, error) { // nolint: golint
	return gojsonreference.NewJsonReference(l.JsonSource().(string))
}
957240
func (r *Registry) AddReference(obj mo.Reference, field *[]types.ManagedObjectReference, ref types.ManagedObjectReference) {
	r.WithLock(obj, func() {
		if FindReference(*field, ref) == nil {
			*field = append(*field, ref)
		}
	})
}
171161
func (vote *ProjectPostCommentVote) Reference() Reference {
	post, _ := NewProjectPostComment(vote.Hcid)
	return post
}
986937
func (s *GetObjectInformationInput) SetObjectReference(v *ObjectReference) *GetObjectInformationInput {
	s.ObjectReference = v
	return s
}
1110581
func NewReference(Variable node.Node) *Reference {
	return &Reference{
		FreeFloating: nil,
		Variable:     Variable,
	}
}
611622
func (r *ReferenceStorage) SetReference(ref *plumbing.Reference) error {
	delete(r.deleted, ref.Name())
	return r.temporal.SetReference(ref)
}
1350613
func (mb *referenceManifestBuilder) AppendReference(d distribution.Describable) error {
	r, ok := d.(Reference)
	if !ok {
		return fmt.Errorf("unable to add non-reference type to v1 builder")
	}

	// Entries need to be prepended
	mb.Manifest.FSLayers = append([]FSLayer{{BlobSum: r.Digest}}, mb.Manifest.FSLayers...)
	mb.Manifest.History = append([]History{r.History}, mb.Manifest.History...)
	return nil

}
1100683
func (bookmark *ProjectPostBookmark) Reference() Reference {
	post, _ := NewProjectPost(bookmark.Hpid)
	return post
}
1115039
func (s *LookupPolicyInput) SetObjectReference(v *ObjectReference) *LookupPolicyInput {
	s.ObjectReference = v
	return s
}
762332
func New(jsonReferenceString string) (Ref, error) {

	var r Ref
	err := r.parse(jsonReferenceString)
	return r, err

}
298899
func NewRemoteReferenceName(remote, name string) ReferenceName {
	return ReferenceName(refRemotePrefix + fmt.Sprintf("%s/%s", remote, name))
}
1126341
func (bookmark *UserPostBookmark) Reference() Reference {
	post, _ := NewUserPost(bookmark.Hpid)
	return post
}
359882
func (mb *builder) AppendReference(d distribution.Describable) error {
	mb.dependencies = append(mb.dependencies, d.Descriptor())
	return nil
}
865331
func (comment *ProjectPostComment) Reference() Reference {
	post, _ := NewProjectPost(comment.NumericReference())
	return post
}
425093
func (mb *configManifestBuilder) AppendReference(d distribution.Describable) error {
	descriptor := d.Descriptor()

	if err := descriptor.Digest.Validate(); err != nil {
		return err
	}

	mb.descriptors = append(mb.descriptors, descriptor)
	return nil
}