CpuPerc() is not public in CpuPerc; cannot be accessed from outside package
...
import org.hyperic.sigar.*;
import org.hyperic.sigar.Cpu;
import org.hyperic.sigar.CpuPerc;
/**
*
* @author John
*/
public class GetCpu {
public void Start() {
Sigar sigar = new Sigar();
CpuPerc perc = new CpuPerc();
System.out.println(getCpuPerc()); // error appears here
}
}
What is this error and how can I fix it. I am using SIGAR API.