code: func (yd *YAMLDecoder) Encode(data []*FileDataEntry) ([]byte, error) {
  	// Convert to json-specific structure
  	var yamlFileEntries []yamlFileEntry
  	for _, dataEntry := range data {
  		yamlFileEntries = append(yamlFileEntries, yamlFileEntry{
  			Key:   dataEntry.Key,
  			Value: dataEntry.Value,
  		})
  	}
  	// Encode to type specific structure
  	yamlFile := &yamlFile{Data: yamlFileEntries}
  	return yaml.Marshal(yamlFile)
  }
docs: // Encode provided file entries into json byte set