pkg.re/essentialkaos/ek.10@v12.41.0+incompatible/system/process/processes_darwin.go (about)

     1  package process
     2  
     3  // ////////////////////////////////////////////////////////////////////////////////// //
     4  //                                                                                    //
     5  //                         Copyright (c) 2022 ESSENTIAL KAOS                          //
     6  //      Apache License, Version 2.0 <https://www.apache.org/licenses/LICENSE-2.0>     //
     7  //                                                                                    //
     8  // ////////////////////////////////////////////////////////////////////////////////// //
     9  
    10  // ❗ ProcessInfo contains basic info about process
    11  type ProcessInfo struct {
    12  	Command  string         // ❗ Full command
    13  	User     string         // ❗ Username
    14  	PID      int            // ❗ PID
    15  	IsThread bool           // ❗ True if process is thread
    16  	Parent   int            // ❗ Parent process PID
    17  	Childs   []*ProcessInfo // ❗ Slice with child processes
    18  }
    19  
    20  // ////////////////////////////////////////////////////////////////////////////////// //
    21  
    22  // ❗ GetTree returns root process with all subprocesses on the system
    23  func GetTree(pid ...int) (*ProcessInfo, error) {
    24  	panic("UNSUPPORTED")
    25  	return nil, nil
    26  }
    27  
    28  // ❗ GetList returns slice with all active processes on the system
    29  func GetList() ([]*ProcessInfo, error) {
    30  	panic("UNSUPPORTED")
    31  	return nil, nil
    32  }