package main
import (
"regexp"
"fmt"
)
func main() {
var re = regexp.MustCompile(`([a-zA-Z0-9_-]+?)_[\d\w]{8}\-(?:[\d\w]{4}\-){3}[\d\w]{12}[_\d\w\s-]*$`)
var str = `/body/RenderingA_6c91dd08-c318-4aa1-9883-bd0ed8af711_UnqiueKeyA/RenderingB_1a9cbcf1-e80f-4448-a21e-12e66f38c015_UniqueKeyB/RenderingC_1a9cbcf1-e80f-4448-a21e-12e66f38c015_UniqueKeyC`
for i, match := range re.FindAllString(str, -1) {
fmt.Println(match, "found at index", i)
}
}
Please keep in mind that these code samples are automatically generated and are not guaranteed to work. If you find any syntax errors, feel free to submit a bug report. For a full regex reference for Golang, please visit: https://golang.org/pkg/regexp/