示例#1
0
文件: action.go 项目: kapilt/juju
// actionIdFromTag converts an ActionTag to an actionId
func actionIdFromTag(tag names.ActionTag) string {
	ptag := tag.PrefixTag()
	if ptag == nil {
		return ""
	}
	return fmt.Sprintf("%s%d", ensureActionMarker(ptag.Id()), tag.Sequence())
}
示例#2
0
// actionIdFromTag converts an ActionTag to an actionId
func actionIdFromTag(tag names.ActionTag) string {
	prefix := actionPrefixFromUnitId(tag.UnitTag().Id())
	return actionId(prefix, tag.Sequence())
}