Package cpufeatures.x86
Record Class X86Info
java.lang.Object
java.lang.Record
cpufeatures.x86.X86Info
- Record Components:
features- Which features this processor supports.family- Family.model- Model.stepping- Stepping.vendor- Manufacturer.brandString- Brand name.uarch- Microarchitecture.
public record X86Info(X86Features features, int family, int model, int stepping, String vendor, String brandString, X86Uarch uarch)
extends Record
Info on a processor running the X86 architecture.
-
Constructor Summary
ConstructorsConstructorDescriptionX86Info(X86Features features, int family, int model, int stepping, String vendor, String brandString, X86Uarch uarch) Creates an instance of aX86Inforecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thebrandStringrecord component.final booleanIndicates whether some other object is "equal to" this one.intfamily()Returns the value of thefamilyrecord component.features()Returns the value of thefeaturesrecord component.Gets a set of all features that this info holds.static X86Infoget()Gets info on the X86 processor running on this JVM.final inthashCode()Returns a hash code value for this object.intmodel()Returns the value of themodelrecord component.intstepping()Returns the value of thesteppingrecord component.final StringtoString()Returns a string representation of this record class.uarch()Returns the value of theuarchrecord component.vendor()Returns the value of thevendorrecord component.
-
Constructor Details
-
X86Info
public X86Info(X86Features features, int family, int model, int stepping, String vendor, String brandString, X86Uarch uarch) Creates an instance of aX86Inforecord class.- Parameters:
features- the value for thefeaturesrecord componentfamily- the value for thefamilyrecord componentmodel- the value for themodelrecord componentstepping- the value for thesteppingrecord componentvendor- the value for thevendorrecord componentbrandString- the value for thebrandStringrecord componentuarch- the value for theuarchrecord component
-
-
Method Details
-
get
Gets info on the X86 processor running on this JVM.If the host is not on an X86 processor, this operation will fail.
- Returns:
- Processor info.
-
featureSet
Gets a set of all features that this info holds. If you are testing for a specific feature, prefer usingfeatures()instead.- Returns:
- Set of features.
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
features
Returns the value of thefeaturesrecord component.- Returns:
- the value of the
featuresrecord component
-
family
public int family()Returns the value of thefamilyrecord component.- Returns:
- the value of the
familyrecord component
-
model
public int model()Returns the value of themodelrecord component.- Returns:
- the value of the
modelrecord component
-
stepping
public int stepping()Returns the value of thesteppingrecord component.- Returns:
- the value of the
steppingrecord component
-
vendor
Returns the value of thevendorrecord component.- Returns:
- the value of the
vendorrecord component
-
brandString
Returns the value of thebrandStringrecord component.- Returns:
- the value of the
brandStringrecord component
-
uarch
Returns the value of theuarchrecord component.- Returns:
- the value of the
uarchrecord component
-