Record Class CmdInfo
java.lang.Object
java.lang.Record
com.iohao.net.framework.core.CmdInfo
CmdInfo
- Author:
- 渔民小镇
- date:
- 2021-12-20
-
Constructor Summary
ConstructorsConstructorDescriptionCmdInfo(int cmd, int subCmd, int cmdMerge) Creates an instance of aCmdInforecord class. -
Method Summary
Modifier and TypeMethodDescriptionintcmd()Returns the value of thecmdrecord component.intcmdMerge()Returns the value of thecmdMergerecord component.booleanIndicates whether some other object is "equal to" this one.inthashCode()Returns a hash code value for this object.static CmdInfoof(int cmdMerge) static CmdInfoof(int cmd, int subCmd) intsubCmd()Returns the value of thesubCmdrecord component.@NonNull StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
CmdInfo
public CmdInfo(int cmd, int subCmd, int cmdMerge) Creates an instance of aCmdInforecord class.- Parameters:
cmd- the value for thecmdrecord componentsubCmd- the value for thesubCmdrecord componentcmdMerge- the value for thecmdMergerecord component
-
-
Method Details
-
of
-
of
-
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. All components in this record class are compared with thecomparemethod from their corresponding wrapper classes. -
hashCode
-
toString
-
cmd
public int cmd()Returns the value of thecmdrecord component.- Returns:
- the value of the
cmdrecord component
-
subCmd
public int subCmd()Returns the value of thesubCmdrecord component.- Returns:
- the value of the
subCmdrecord component
-
cmdMerge
public int cmdMerge()Returns the value of thecmdMergerecord component.- Returns:
- the value of the
cmdMergerecord component
-