2013-02-11 Sebastian Huber <sebastian.huber@embedded-brains.de>
[official-gcc.git] / libgo / go / net / file_plan9.go
blobae3ac156b9878d02dc23ada735475e07f4a7d67c
1 // Copyright 2011 The Go Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style
3 // license that can be found in the LICENSE file.
5 package net
7 import (
8 "os"
9 "syscall"
12 // FileConn returns a copy of the network connection corresponding to
13 // the open file f. It is the caller's responsibility to close f when
14 // finished. Closing c does not affect f, and closing f does not
15 // affect c.
16 func FileConn(f *os.File) (c Conn, err error) {
17 return nil, syscall.EPLAN9
20 // FileListener returns a copy of the network listener corresponding
21 // to the open file f. It is the caller's responsibility to close l
22 // when finished. Closing l does not affect f, and closing f does not
23 // affect l.
24 func FileListener(f *os.File) (l Listener, err error) {
25 return nil, syscall.EPLAN9
28 // FilePacketConn returns a copy of the packet network connection
29 // corresponding to the open file f. It is the caller's
30 // responsibility to close f when finished. Closing c does not affect
31 // f, and closing f does not affect c.
32 func FilePacketConn(f *os.File) (c PacketConn, err error) {
33 return nil, syscall.EPLAN9