AsStaticFIFO returns the StatifFile as a StaticFIFO if the StaticFile represents a fifo. Otherwise, it returns the zero value of StaticFIFO and false.
()
| 334 | // StaticFile represents a fifo. Otherwise, it returns the zero value |
| 335 | // of StaticFIFO and false. |
| 336 | func (sf StaticFile) AsStaticFIFO() (fifo StaticFIFO, ok bool) { |
| 337 | if sf.b.ss.Type == TypeFIFO { |
| 338 | return StaticFIFO{sf}, true |
| 339 | } |
| 340 | |
| 341 | return |
| 342 | } |
| 343 | |
| 344 | // AsStaticSocket returns the StaticFile as a StaticSocket if the |
| 345 | // StaticFile represents a socket. Otherwise, it returns the zero |
no outgoing calls