]> Cypherpunks repositories - gostls13.git/commitdiff
net: update comments to remove redundant "net" prefix
authorMikio Hara <mikioh.mikioh@gmail.com>
Sun, 29 Jan 2012 10:11:05 +0000 (19:11 +0900)
committerMikio Hara <mikioh.mikioh@gmail.com>
Sun, 29 Jan 2012 10:11:05 +0000 (19:11 +0900)
R=rsc, r
CC=golang-dev
https://golang.org/cl/5569087

12 files changed:
src/pkg/net/dnsmsg.go
src/pkg/net/fd.go
src/pkg/net/fd_windows.go
src/pkg/net/iprawsock_plan9.go
src/pkg/net/ipsock_plan9.go
src/pkg/net/net.go
src/pkg/net/tcpsock_plan9.go
src/pkg/net/tcpsock_posix.go
src/pkg/net/udpsock_plan9.go
src/pkg/net/udpsock_posix.go
src/pkg/net/unixsock_plan9.go
src/pkg/net/unixsock_posix.go

index 7595aa2ab593b73378a38e20f8a54865c57122ae..97c5062103fe0f72920e9fe1589ff9265d9dd26c 100644 (file)
@@ -4,7 +4,7 @@
 
 // DNS packet assembly.  See RFC 1035.
 //
-// This is intended to support name resolution during net.Dial.
+// This is intended to support name resolution during Dial.
 // It doesn't have to be blazing fast.
 //
 // Rather than write the usual handful of routines to pack and
index 495ef007fe20ea4a2b71efb2bd58f131155fe7ba..c1bda7d67e5272cf82dc5098ba0e8d874085a1bd 100644 (file)
@@ -45,7 +45,7 @@ type netFD struct {
 
 type InvalidConnError struct{}
 
-func (e *InvalidConnError) Error() string   { return "invalid net.Conn" }
+func (e *InvalidConnError) Error() string   { return "invalid Conn" }
 func (e *InvalidConnError) Temporary() bool { return false }
 func (e *InvalidConnError) Timeout() bool   { return false }
 
index f00459f0bafe194f2c483429e2d789b6c34cabac..2ade0964fcb18f255d53b17832bc216d376d0a9d 100644 (file)
@@ -16,7 +16,7 @@ import (
 
 type InvalidConnError struct{}
 
-func (e *InvalidConnError) Error() string   { return "invalid net.Conn" }
+func (e *InvalidConnError) Error() string   { return "invalid Conn" }
 func (e *InvalidConnError) Temporary() bool { return false }
 func (e *InvalidConnError) Timeout() bool   { return false }
 
index 859153c2aad6449d6757bf3bf49434e251863db2..382a4402770c29ed561400885087114eb9e4429b 100644 (file)
@@ -15,17 +15,17 @@ import (
 // interfaces for IP network connections.
 type IPConn bool
 
-// SetDeadline implements the net.Conn SetDeadline method.
+// SetDeadline implements the Conn SetDeadline method.
 func (c *IPConn) SetDeadline(t time.Time) error {
        return os.EPLAN9
 }
 
-// SetReadDeadline implements the net.Conn SetReadDeadline method.
+// SetReadDeadline implements the Conn SetReadDeadline method.
 func (c *IPConn) SetReadDeadline(t time.Time) error {
        return os.EPLAN9
 }
 
-// SetWriteDeadline implements the net.Conn SetWriteDeadline method.
+// SetWriteDeadline implements the Conn SetWriteDeadline method.
 func (c *IPConn) SetWriteDeadline(t time.Time) error {
        return os.EPLAN9
 }
index 09d8d6b4e040de926bda0b45ac65e30b5972388f..29eeb75825bad13fd75df29bade6564ec9ee6da7 100644 (file)
@@ -91,7 +91,7 @@ func (c *plan9Conn) ok() bool { return c != nil && c.ctl != nil }
 
 // Implementation of the Conn interface - see Conn for documentation.
 
-// Read implements the net.Conn Read method.
+// Read implements the Conn Read method.
 func (c *plan9Conn) Read(b []byte) (n int, err error) {
        if !c.ok() {
                return 0, os.EINVAL
@@ -110,7 +110,7 @@ func (c *plan9Conn) Read(b []byte) (n int, err error) {
        return
 }
 
-// Write implements the net.Conn Write method.
+// Write implements the Conn Write method.
 func (c *plan9Conn) Write(b []byte) (n int, err error) {
        if !c.ok() {
                return 0, os.EINVAL
@@ -157,17 +157,17 @@ func (c *plan9Conn) RemoteAddr() Addr {
        return c.raddr
 }
 
-// SetDeadline implements the net.Conn SetDeadline method.
+// SetDeadline implements the Conn SetDeadline method.
 func (c *plan9Conn) SetDeadline(t time.Time) error {
        return os.EPLAN9
 }
 
-// SetReadDeadline implements the net.Conn SetReadDeadline method.
+// SetReadDeadline implements the Conn SetReadDeadline method.
 func (c *plan9Conn) SetReadDeadline(t time.Time) error {
        return os.EPLAN9
 }
 
-// SetWriteDeadline implements the net.Conn SetWriteDeadline method.
+// SetWriteDeadline implements the Conn SetWriteDeadline method.
 func (c *plan9Conn) SetWriteDeadline(t time.Time) error {
        return os.EPLAN9
 }
index 609fee242d0dbacdd77655b206888a2bbe707ef1..84cb4fcc73ae78c00eaf963b50c102e0e351b26d 100644 (file)
@@ -23,12 +23,12 @@ type Addr interface {
 // Conn is a generic stream-oriented network connection.
 type Conn interface {
        // Read reads data from the connection.
-       // Read can be made to time out and return a net.Error with Timeout() == true
+       // Read can be made to time out and return a Error with Timeout() == true
        // after a fixed time limit; see SetDeadline and SetReadDeadline.
        Read(b []byte) (n int, err error)
 
        // Write writes data to the connection.
-       // Write can be made to time out and return a net.Error with Timeout() == true
+       // Write can be made to time out and return a Error with Timeout() == true
        // after a fixed time limit; see SetDeadline and SetWriteDeadline.
        Write(b []byte) (n int, err error)
 
index f2444a4d96f9c331242ca1c0fc898d46f951e4c9..128766144ddc3ba42151f6af29696971e9928bf4 100644 (file)
@@ -17,17 +17,17 @@ type TCPConn struct {
        plan9Conn
 }
 
-// SetDeadline implements the net.Conn SetDeadline method.
+// SetDeadline implements the Conn SetDeadline method.
 func (c *TCPConn) SetDeadline(t time.Time) error {
        return os.EPLAN9
 }
 
-// SetReadDeadline implements the net.Conn SetReadDeadline method.
+// SetReadDeadline implements the Conn SetReadDeadline method.
 func (c *TCPConn) SetReadDeadline(t time.Time) error {
        return os.EPLAN9
 }
 
-// SetWriteDeadline implements the net.Conn SetWriteDeadline method.
+// SetWriteDeadline implements the Conn SetWriteDeadline method.
 func (c *TCPConn) SetWriteDeadline(t time.Time) error {
        return os.EPLAN9
 }
index 65ec493039cbd9a360f99b38cf3f3179b268faf6..e589f86b44315ca109fa2d0de362d1879e99b73b 100644 (file)
@@ -67,7 +67,7 @@ func (c *TCPConn) ok() bool { return c != nil && c.fd != nil }
 
 // Implementation of the Conn interface - see Conn for documentation.
 
-// Read implements the net.Conn Read method.
+// Read implements the Conn Read method.
 func (c *TCPConn) Read(b []byte) (n int, err error) {
        if !c.ok() {
                return 0, os.EINVAL
@@ -83,7 +83,7 @@ func (c *TCPConn) ReadFrom(r io.Reader) (int64, error) {
        return genericReadFrom(c, r)
 }
 
-// Write implements the net.Conn Write method.
+// Write implements the Conn Write method.
 func (c *TCPConn) Write(b []byte) (n int, err error) {
        if !c.ok() {
                return 0, os.EINVAL
@@ -135,7 +135,7 @@ func (c *TCPConn) RemoteAddr() Addr {
        return c.fd.raddr
 }
 
-// SetDeadline implements the net.Conn SetDeadline method.
+// SetDeadline implements the Conn SetDeadline method.
 func (c *TCPConn) SetDeadline(t time.Time) error {
        if !c.ok() {
                return os.EINVAL
@@ -143,7 +143,7 @@ func (c *TCPConn) SetDeadline(t time.Time) error {
        return setDeadline(c.fd, t)
 }
 
-// SetReadDeadline implements the net.Conn SetReadDeadline method.
+// SetReadDeadline implements the Conn SetReadDeadline method.
 func (c *TCPConn) SetReadDeadline(t time.Time) error {
        if !c.ok() {
                return os.EINVAL
@@ -151,7 +151,7 @@ func (c *TCPConn) SetReadDeadline(t time.Time) error {
        return setReadDeadline(c.fd, t)
 }
 
-// SetWriteDeadline implements the net.Conn SetWriteDeadline method.
+// SetWriteDeadline implements the Conn SetWriteDeadline method.
 func (c *TCPConn) SetWriteDeadline(t time.Time) error {
        if !c.ok() {
                return os.EINVAL
index 573438f85de3ca1c6f2c05d00749ce8f62df96d2..cf507536880da4b69ea53d9f424b286e60b1fdae 100644 (file)
@@ -18,17 +18,17 @@ type UDPConn struct {
        plan9Conn
 }
 
-// SetDeadline implements the net.Conn SetDeadline method.
+// SetDeadline implements the Conn SetDeadline method.
 func (c *UDPConn) SetDeadline(t time.Time) error {
        return os.EPLAN9
 }
 
-// SetReadDeadline implements the net.Conn SetReadDeadline method.
+// SetReadDeadline implements the Conn SetReadDeadline method.
 func (c *UDPConn) SetReadDeadline(t time.Time) error {
        return os.EPLAN9
 }
 
-// SetWriteDeadline implements the net.Conn SetWriteDeadline method.
+// SetWriteDeadline implements the Conn SetWriteDeadline method.
 func (c *UDPConn) SetWriteDeadline(t time.Time) error {
        return os.EPLAN9
 }
@@ -66,7 +66,7 @@ func (c *UDPConn) ReadFromUDP(b []byte) (n int, addr *UDPAddr, err error) {
        return n, &UDPAddr{h.raddr, int(h.rport)}, nil
 }
 
-// ReadFrom implements the net.PacketConn ReadFrom method.
+// ReadFrom implements the PacketConn ReadFrom method.
 func (c *UDPConn) ReadFrom(b []byte) (n int, addr Addr, err error) {
        if !c.ok() {
                return 0, nil, os.EINVAL
@@ -103,7 +103,7 @@ func (c *UDPConn) WriteToUDP(b []byte, addr *UDPAddr) (n int, err error) {
        return c.data.Write(buf)
 }
 
-// WriteTo implements the net.PacketConn WriteTo method.
+// WriteTo implements the PacketConn WriteTo method.
 func (c *UDPConn) WriteTo(b []byte, addr Addr) (n int, err error) {
        if !c.ok() {
                return 0, os.EINVAL
index fa3d29adfa8cf21826bf2f81288b25b14a6afafc..b8092e6b89eb903db8942f1687ec0c3b3b0bec7b 100644 (file)
@@ -60,7 +60,7 @@ func (c *UDPConn) ok() bool { return c != nil && c.fd != nil }
 
 // Implementation of the Conn interface - see Conn for documentation.
 
-// Read implements the net.Conn Read method.
+// Read implements the Conn Read method.
 func (c *UDPConn) Read(b []byte) (n int, err error) {
        if !c.ok() {
                return 0, os.EINVAL
@@ -68,7 +68,7 @@ func (c *UDPConn) Read(b []byte) (n int, err error) {
        return c.fd.Read(b)
 }
 
-// Write implements the net.Conn Write method.
+// Write implements the Conn Write method.
 func (c *UDPConn) Write(b []byte) (n int, err error) {
        if !c.ok() {
                return 0, os.EINVAL
@@ -102,7 +102,7 @@ func (c *UDPConn) RemoteAddr() Addr {
        return c.fd.raddr
 }
 
-// SetDeadline implements the net.Conn SetDeadline method.
+// SetDeadline implements the Conn SetDeadline method.
 func (c *UDPConn) SetDeadline(t time.Time) error {
        if !c.ok() {
                return os.EINVAL
@@ -110,7 +110,7 @@ func (c *UDPConn) SetDeadline(t time.Time) error {
        return setDeadline(c.fd, t)
 }
 
-// SetReadDeadline implements the net.Conn SetReadDeadline method.
+// SetReadDeadline implements the Conn SetReadDeadline method.
 func (c *UDPConn) SetReadDeadline(t time.Time) error {
        if !c.ok() {
                return os.EINVAL
@@ -118,7 +118,7 @@ func (c *UDPConn) SetReadDeadline(t time.Time) error {
        return setReadDeadline(c.fd, t)
 }
 
-// SetWriteDeadline implements the net.Conn SetWriteDeadline method.
+// SetWriteDeadline implements the Conn SetWriteDeadline method.
 func (c *UDPConn) SetWriteDeadline(t time.Time) error {
        if !c.ok() {
                return os.EINVAL
@@ -166,7 +166,7 @@ func (c *UDPConn) ReadFromUDP(b []byte) (n int, addr *UDPAddr, err error) {
        return
 }
 
-// ReadFrom implements the net.PacketConn ReadFrom method.
+// ReadFrom implements the PacketConn ReadFrom method.
 func (c *UDPConn) ReadFrom(b []byte) (n int, addr Addr, err error) {
        if !c.ok() {
                return 0, nil, os.EINVAL
@@ -195,7 +195,7 @@ func (c *UDPConn) WriteToUDP(b []byte, addr *UDPAddr) (int, error) {
        return c.fd.WriteTo(b, sa)
 }
 
-// WriteTo implements the net.PacketConn WriteTo method.
+// WriteTo implements the PacketConn WriteTo method.
 func (c *UDPConn) WriteTo(b []byte, addr Addr) (int, error) {
        if !c.ok() {
                return 0, os.EINVAL
index e8087d09a360943b05f79f983995f325e766f115..1d9d7578f4fff0ff3692dd5164831775258f4562 100644 (file)
@@ -17,12 +17,12 @@ type UnixConn bool
 
 // Implementation of the Conn interface - see Conn for documentation.
 
-// Read implements the net.Conn Read method.
+// Read implements the Conn Read method.
 func (c *UnixConn) Read(b []byte) (n int, err error) {
        return 0, os.EPLAN9
 }
 
-// Write implements the net.Conn Write method.
+// Write implements the Conn Write method.
 func (c *UnixConn) Write(b []byte) (n int, err error) {
        return 0, os.EPLAN9
 }
@@ -45,28 +45,28 @@ func (c *UnixConn) RemoteAddr() Addr {
        return nil
 }
 
-// SetDeadline implements the net.Conn SetDeadline method.
+// SetDeadline implements the Conn SetDeadline method.
 func (c *UnixConn) SetDeadline(t time.Time) error {
        return os.EPLAN9
 }
 
-// SetReadDeadline implements the net.Conn SetReadDeadline method.
+// SetReadDeadline implements the Conn SetReadDeadline method.
 func (c *UnixConn) SetReadDeadline(t time.Time) error {
        return os.EPLAN9
 }
 
-// SetWriteDeadline implements the net.Conn SetWriteDeadline method.
+// SetWriteDeadline implements the Conn SetWriteDeadline method.
 func (c *UnixConn) SetWriteDeadline(t time.Time) error {
        return os.EPLAN9
 }
 
-// ReadFrom implements the net.PacketConn ReadFrom method.
+// ReadFrom implements the PacketConn ReadFrom method.
 func (c *UnixConn) ReadFrom(b []byte) (n int, addr Addr, err error) {
        err = os.EPLAN9
        return
 }
 
-// WriteTo implements the net.PacketConn WriteTo method.
+// WriteTo implements the PacketConn WriteTo method.
 func (c *UnixConn) WriteTo(b []byte, addr Addr) (n int, err error) {
        err = os.EPLAN9
        return
index e500ddb4e0f30a80ff1280315c58f9bf0b90a155..beb2aa90f56c9820949cd48ebd35f360379d04f0 100644 (file)
@@ -120,7 +120,7 @@ func (c *UnixConn) ok() bool { return c != nil && c.fd != nil }
 
 // Implementation of the Conn interface - see Conn for documentation.
 
-// Read implements the net.Conn Read method.
+// Read implements the Conn Read method.
 func (c *UnixConn) Read(b []byte) (n int, err error) {
        if !c.ok() {
                return 0, os.EINVAL
@@ -128,7 +128,7 @@ func (c *UnixConn) Read(b []byte) (n int, err error) {
        return c.fd.Read(b)
 }
 
-// Write implements the net.Conn Write method.
+// Write implements the Conn Write method.
 func (c *UnixConn) Write(b []byte) (n int, err error) {
        if !c.ok() {
                return 0, os.EINVAL
@@ -165,7 +165,7 @@ func (c *UnixConn) RemoteAddr() Addr {
        return c.fd.raddr
 }
 
-// SetDeadline implements the net.Conn SetDeadline method.
+// SetDeadline implements the Conn SetDeadline method.
 func (c *UnixConn) SetDeadline(t time.Time) error {
        if !c.ok() {
                return os.EINVAL
@@ -173,7 +173,7 @@ func (c *UnixConn) SetDeadline(t time.Time) error {
        return setDeadline(c.fd, t)
 }
 
-// SetReadDeadline implements the net.Conn SetReadDeadline method.
+// SetReadDeadline implements the Conn SetReadDeadline method.
 func (c *UnixConn) SetReadDeadline(t time.Time) error {
        if !c.ok() {
                return os.EINVAL
@@ -181,7 +181,7 @@ func (c *UnixConn) SetReadDeadline(t time.Time) error {
        return setReadDeadline(c.fd, t)
 }
 
-// SetWriteDeadline implements the net.Conn SetWriteDeadline method.
+// SetWriteDeadline implements the Conn SetWriteDeadline method.
 func (c *UnixConn) SetWriteDeadline(t time.Time) error {
        if !c.ok() {
                return os.EINVAL
@@ -226,7 +226,7 @@ func (c *UnixConn) ReadFromUnix(b []byte) (n int, addr *UnixAddr, err error) {
        return
 }
 
-// ReadFrom implements the net.PacketConn ReadFrom method.
+// ReadFrom implements the PacketConn ReadFrom method.
 func (c *UnixConn) ReadFrom(b []byte) (n int, addr Addr, err error) {
        if !c.ok() {
                return 0, nil, os.EINVAL
@@ -252,7 +252,7 @@ func (c *UnixConn) WriteToUnix(b []byte, addr *UnixAddr) (n int, err error) {
        return c.fd.WriteTo(b, sa)
 }
 
-// WriteTo implements the net.PacketConn WriteTo method.
+// WriteTo implements the PacketConn WriteTo method.
 func (c *UnixConn) WriteTo(b []byte, addr Addr) (n int, err error) {
        if !c.ok() {
                return 0, os.EINVAL