FileDescriptorsInfo retrieves information about all file descriptors of the process.
()
| 310 | // FileDescriptorsInfo retrieves information about all file descriptors of |
| 311 | // the process. |
| 312 | func (p Proc) FileDescriptorsInfo() (ProcFDInfos, error) { |
| 313 | names, err := p.fileDescriptors() |
| 314 | if err != nil { |
| 315 | return nil, err |
| 316 | } |
| 317 | |
| 318 | var fdinfos ProcFDInfos |
| 319 | |
| 320 | for _, n := range names { |
| 321 | fdinfo, err := p.FDInfo(n) |
| 322 | if err != nil { |
| 323 | continue |
| 324 | } |
| 325 | fdinfos = append(fdinfos, *fdinfo) |
| 326 | } |
| 327 | |
| 328 | return fdinfos, nil |
| 329 | } |
| 330 | |
| 331 | // Schedstat returns task scheduling information for the process. |
| 332 | func (p Proc) Schedstat() (ProcSchedstat, error) { |