nat/nat.go
func Parse(config *Config) (Interface, error) {
	switch config.Mechanism {
	case "any":
		return any(config), nil
	case "upnp":
		return uPnP(config), nil
	case "pmp":
		return pmp(), nil
	default:
		return nil, ErrBadMechanism
	}
}
func Parse(config *Config) (Interface, error) {
	switch config.Mechanism {
	case "any":
		return any(config), nil
	case "upnp":
		return uPnP(config), nil
	case "pmp":
		return pmp(), nil
	default:
		return nil, ErrBadMechanism
	}
}
func Parse ( config * Config ) ( Interface , error ) { switch config . Mechanism { case " " : return any ( config ) , nil case " " : return uPnP ( config ) , nil case " " : return pmp ( ) , nil default : return nil , ErrBadMechanism } }
// Parse parses a NAT interface description.
Parse parses a NAT interface description .