func generateManifestSorter(output []ManifestEntry) func(i, j int) bool {
	return func(i, j int) bool {
		// Need both conditions so that it will proceed to the next check only
		// if there is a tie at this one
		if output[i].Zip < output[j].Zip {
			return true
		} else if output[i].Zip > output[j].Zip {
			return false
		}

		if output[i].Series < output[j].Series {
			return true
		} else if output[i].Series > output[j].Series {
			return false
		}

		if output[i].InstanceNumber < output[j].InstanceNumber {
			return true
		} else if output[i].InstanceNumber > output[j].InstanceNumber {
			return false
		}

		if output[i].Dicom < output[j].Dicom {
			return true
		} else if output[i].Dicom > output[j].Dicom {
			return false
		}

		return false
	}
}
// generateManifestSorter is a convenience function to help sort a list of
// manifest objects
generateManifestSorter is a convenience function to help sort a list of
manifest objects
// generateManifestSorter is a convenience function to help sort a list of // manifest objects
func generateManifestSorter(output []ManifestEntry) func(i, j int) bool {
	return func(i, j int) bool {
		if output[i].Zip < output[j].Zip {
			return true
		} else if output[i].Zip > output[j].Zip {
			return false
		}
		if output[i].Series < output[j].Series {
			return true
		} else if output[i].Series > output[j].Series {
			return false
		}
		if output[i].InstanceNumber < output[j].InstanceNumber {
			return true
		} else if output[i].InstanceNumber > output[j].InstanceNumber {
			return false
		}
		if output[i].Dicom < output[j].Dicom {
			return true
		} else if output[i].Dicom > output[j].Dicom {
			return false
		}
		return false
	}
}
func generateManifestSorter ( output [ ] ManifestEntry ) func ( i , j int ) bool { return func ( i , j int ) bool { if output [ i ] . Zip < output [ j ] . Zip { return true } else if output [ i ] . Zip > output [ j ] . Zip { return false } if output [ i ] . Series < output [ j ] . Series { return true } else if output [ i ] . Series > output [ j ] . Series { return false } if output [ i ] . InstanceNumber < output [ j ] . InstanceNumber { return true } else if output [ i ] . InstanceNumber > output [ j ] . InstanceNumber { return false } if output [ i ] . Dicom < output [ j ] . Dicom { return true } else if output [ i ] . Dicom > output [ j ] . Dicom { return false } return false } }
generateManifestSorter is a convenience function to help sort a list of
manifest objects
generateManifestSorter is a convenience function to help sort a list of manifest objects
// Need both conditions so that it will proceed to the next check only // if there is a tie at this one