forked from I2P_Developers/i2p.i2p
Improved toString() and formatting.
This commit is contained in:
@ -476,25 +476,23 @@ public class CPUID {
|
|||||||
// Remove when implemented isCore7Compatible in BigInteger
|
// Remove when implemented isCore7Compatible in BigInteger
|
||||||
} else if (getCPUExtendedModel() == 0 && getCPUFamily() == 6 && getCPUModel() == 15){
|
} else if (getCPUExtendedModel() == 0 && getCPUFamily() == 6 && getCPUModel() == 15){
|
||||||
return true;
|
return true;
|
||||||
} else {
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
public boolean IsAtomCompatible()
|
public boolean IsAtomCompatible()
|
||||||
{
|
{
|
||||||
if (getCPUExtendedModel() == 0 && getCPUFamily() == 6 && getCPUModel() == 12){
|
if (getCPUExtendedModel() == 0 && getCPUFamily() == 6 && getCPUModel() == 12){
|
||||||
return true;
|
return true;
|
||||||
} else {
|
}
|
||||||
return false;
|
return false;
|
||||||
}
|
|
||||||
}
|
}
|
||||||
public boolean IsCore2Compatible()
|
public boolean IsCore2Compatible()
|
||||||
{
|
{
|
||||||
if (getCPUExtendedModel() == 0 && getCPUFamily() == 6 && getCPUModel() == 15){
|
if (getCPUExtendedModel() == 0 && getCPUFamily() == 6 && getCPUModel() == 15){
|
||||||
return true;
|
return true;
|
||||||
} else {
|
}
|
||||||
return false;
|
return false;
|
||||||
}
|
|
||||||
}
|
}
|
||||||
public boolean IsCoreiCompatible()
|
public boolean IsCoreiCompatible()
|
||||||
{
|
{
|
||||||
@ -503,9 +501,8 @@ public class CPUID {
|
|||||||
// Xeon MP (45nm) or Core i7
|
// Xeon MP (45nm) or Core i7
|
||||||
} else if (getCPUExtendedModel() == 1 && (getCPUFamily() == 6 && (getCPUModel() == 10 || getCPUModel() == 13 || getCPUModel() == 14))){
|
} else if (getCPUExtendedModel() == 1 && (getCPUFamily() == 6 && (getCPUModel() == 10 || getCPUModel() == 13 || getCPUModel() == 14))){
|
||||||
return true;
|
return true;
|
||||||
} else {
|
}
|
||||||
return false;
|
return false;
|
||||||
}
|
|
||||||
}
|
}
|
||||||
public String getCPUModelString() throws UnknownCPUException {
|
public String getCPUModelString() throws UnknownCPUException {
|
||||||
if (getCPUExtendedModel() == 0){
|
if (getCPUExtendedModel() == 0){
|
||||||
@ -668,6 +665,9 @@ public class CPUID {
|
|||||||
System.out.println(" Is pII-compatible: "+((IntelCPUInfo)c).IsPentium2Compatible());
|
System.out.println(" Is pII-compatible: "+((IntelCPUInfo)c).IsPentium2Compatible());
|
||||||
System.out.println(" Is pIII-compatible: "+((IntelCPUInfo)c).IsPentium3Compatible());
|
System.out.println(" Is pIII-compatible: "+((IntelCPUInfo)c).IsPentium3Compatible());
|
||||||
System.out.println(" Is pIV-compatible: "+((IntelCPUInfo)c).IsPentium4Compatible());
|
System.out.println(" Is pIV-compatible: "+((IntelCPUInfo)c).IsPentium4Compatible());
|
||||||
|
System.out.println(" Is atom-compatible: "+((IntelCPUInfo)c).IsAtomCompatible());
|
||||||
|
System.out.println(" Is core2-compatible: "+((IntelCPUInfo)c).IsCore2Compatible());
|
||||||
|
System.out.println(" Is corei-compatible: "+((IntelCPUInfo)c).IsCoreiCompatible());
|
||||||
}
|
}
|
||||||
if(c instanceof AMDCPUInfo){
|
if(c instanceof AMDCPUInfo){
|
||||||
System.out.println(" **AMD-info**");
|
System.out.println(" **AMD-info**");
|
||||||
|
@ -37,4 +37,16 @@ public interface IntelCPUInfo extends CPUInfo {
|
|||||||
* @return true iff the CPU implements at least a Pentium IV level instruction/feature set.
|
* @return true iff the CPU implements at least a Pentium IV level instruction/feature set.
|
||||||
*/
|
*/
|
||||||
public boolean IsPentium4Compatible();
|
public boolean IsPentium4Compatible();
|
||||||
|
/**
|
||||||
|
* @return true iff the CPU implements at least a Atom level instruction/feature set.
|
||||||
|
*/
|
||||||
|
public boolean IsAtomCompatible();
|
||||||
|
/**
|
||||||
|
* @return true iff the CPU implements at least a Core2 level instruction/feature set.
|
||||||
|
*/
|
||||||
|
public boolean IsCore2Compatible();
|
||||||
|
/**
|
||||||
|
* @return true iff the CPU implements at least a Corei level instruction/feature set.
|
||||||
|
*/
|
||||||
|
public boolean IsCoreiCompatible();
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user