port.go
func (p Port) ToString() (out string) {
	out += fmt.Sprintf("Port %d/%s is %s\n", p.ID, p.Protocol, p.State)
	for _, script := range p.Scripts {
		output := ""
		for _, line := range strings.Split(script.Output, "\n") {
			output += fmt.Sprintf("      %s\n", line)
		}
		out += fmt.Sprintf("  Script: %s\n%s\n", script.Name, output)
	}
	return
}
func (p Port) ToString() (out string) {
	out += fmt.Sprintf("Port %d/%s is %s\n", p.ID, p.Protocol, p.State)
	for _, script := range p.Scripts {
		output := ""
		for _, line := range strings.Split(script.Output, "\n") {
			output += fmt.Sprintf("      %s\n", line)
		}
		out += fmt.Sprintf("  Script: %s\n%s\n", script.Name, output)
	}
	return
}
func ( p Port ) ToString ( ) ( out string ) { out += fmt . Sprintf ( " \n " , p . ID , p . Protocol , p . State ) for _ , script := range p . Scripts { output := " " for _ , line := range strings . Split ( script . Output , " \n " ) { output += fmt . Sprintf ( " \n " , line ) } out += fmt . Sprintf ( " \n \n " , script . Name , output ) } return }
// ToString returns port information in a pretty-printed format
ToString returns port information in a pretty - printed format