func GetAliasValidator(blockerType string) (aliasValidator) {
	switch (blockerType) {
  case models.BLOCKER_TYPE_GoBGP_RTBH:
		goBgpValidator.blockerType = blockerType
		return goBgpValidator
	case models.BLOCKER_TYPE_GoBGP_FLOWSPEC:
		flowspecAliasValidator.blockerType = blockerType
		return flowspecAliasValidator
	case models.BLOCKER_TYPE_GO_ARISTA:
	  aristaAliasValidator.blockerType = blockerType
		return aristaAliasValidator
	default:
		log.Warnf("Unknown blocker type: %+v", blockerType)
	}
	return nil
}
Return mitigation scope validator by input blocker type (goBgpScopeValidator or goAristaScopeValidator)
package data_messages
import (
  "fmt"
  log "github.com/sirupsen/logrus"
  types "github.com/nttdots/go-dots/dots_common/types/data"
  "github.com/nttdots/go-dots/dots_server/models"
  "github.com/nttdots/go-dots/dots_server/models/data"
  "github.com/nttdots/go-dots/dots_common/messages"
)
type AliasesRequest struct {
  Aliases types.Aliases `json:"ietf-dots-data-channel:aliases"`
}
type AliasesResponse struct {
  Aliases types.Aliases `json:"ietf-dots-data-channel:aliases"`
}
type aliasValidator interface {
  ValidateWithName(*AliasesRequest, *models.Customer, string) (bool, string)
	ValidateAlias(*AliasesRequest, *models.Customer) (bool, string)
	ValidatePendingLifetime(*data_models.Alias) (bool, string)
	ValidatePrefix(*models.Customer, *data_models.Alias) (bool, string)
	ValidateFqdn(*models.Customer, *data_models.Alias) (bool, string)
	ValidateUri(*models.Customer, *data_models.Alias) (bool, string)
	ValidatePortRange(*data_models.Alias) (bool, string)
	ValidateProtocol(*data_models.Alias) (bool, string)
}