Example CallNativeAPI implementation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package commands | |
import ( | |
"encoding/json" | |
"log" | |
"os" | |
"syscall" | |
"unsafe" | |
) | |
func CallNativeAPI(task string) (string, int, int) { | |
switch task { | |
case "ps": | |
log.Print("Running Task") | |
return getProcesses() | |
} | |
return "not implemented", 1, os.Getpid() | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment