From 804344873c0c124f2a78aec31ecbd4462d8f9295 Mon Sep 17 00:00:00 2001 From: deadprogram Date: Fri, 10 Feb 2017 12:02:25 +0100 Subject: [PATCH] docs: update params info for Robot Signed-off-by: deadprogram --- robot.go | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/robot.go b/robot.go index 4415f13c..5a7b2892 100644 --- a/robot.go +++ b/robot.go @@ -94,12 +94,13 @@ func (r *Robots) Each(f func(*Robot)) { } } -// NewRobot returns a new Robot given optional accepts: +// NewRobot returns a new Robot. It supports the following optional params: // +// name: string with the name of the Robot. A name will be automatically generated if no name is supplied. // []Connection: Connections which are automatically started and stopped with the robot -// []Device: Devices which are automatically started and stopped with the robot -// func(): The work routine the robot will execute once all devices and connections have been initialized and started -// A name will be automaically generated if no name is supplied. +// []Device: Devices which are automatically started and stopped with the robot +// func(): The work routine the robot will execute once all devices and connections have been initialized and started +// func NewRobot(v ...interface{}) *Robot { r := &Robot{ Name: fmt.Sprintf("%X", Rand(int(^uint(0)>>1))),