Record Class Phone
java.lang.Object
java.lang.Record
com.maxmind.minfraud.response.Phone
- Record Components:
country- The two-character ISO 3166-1 country code for the country associated with the phone number.isVoip- Whether the number is VoIP.matchesPostal- Whether the phone number matches the postal code.networkOperator- The name of the original network operator associated with the phone number. This field does not reflect phone numbers that have been ported from the original operator to another, nor does it identify mobile virtual network operators.numberType- One of the following values:fixedormobile. Additional values may be added in the future.
- All Implemented Interfaces:
JsonSerializable
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncountry()Returns the value of thecountryrecord component.final booleanIndicates whether some other object is "equal to" this one.Deprecated, for removal: This API element is subject to removal in a future version.Deprecated, for removal: This API element is subject to removal in a future version.UsenetworkOperator()instead.Deprecated, for removal: This API element is subject to removal in a future version.UsenumberType()instead.final inthashCode()Returns a hash code value for this object.isVoip()Returns the value of theisVoiprecord component.Returns the value of thematchesPostalrecord component.Returns the value of thenetworkOperatorrecord component.Returns the value of thenumberTyperecord component.final StringtoString()Returns a string representation of this record class.Methods inherited from interface JsonSerializable
toJson
-
Constructor Details
-
Phone
public Phone()Constructs an instance ofPhonewith no data. -
Phone
public Phone(String country, Boolean isVoip, Boolean matchesPostal, String networkOperator, String numberType) Creates an instance of aPhonerecord class.- Parameters:
country- the value for thecountryrecord componentisVoip- the value for theisVoiprecord componentmatchesPostal- the value for thematchesPostalrecord componentnetworkOperator- the value for thenetworkOperatorrecord componentnumberType- the value for thenumberTyperecord component
-
-
Method Details
-
getCountry
Deprecated, for removal: This API element is subject to removal in a future version.Usecountry()instead. This method will be removed in 5.0.0.- Returns:
- The two-character ISO 3166-1 country code for the country associated with the phone number.
-
getNetworkOperator
Deprecated, for removal: This API element is subject to removal in a future version.UsenetworkOperator()instead. This method will be removed in 5.0.0.- Returns:
- The name of the original network operator associated with the phone number. This field does not reflect phone numbers that have been ported from the original operator to another, nor does it identify mobile virtual network operators.
-
getNumberType
Deprecated, for removal: This API element is subject to removal in a future version.UsenumberType()instead. This method will be removed in 5.0.0.- Returns:
- One of the following values:
fixedormobile. Additional values may be added in the future.
-
toString
-
hashCode
-
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 withObjects::equals(Object,Object). -
country
-
isVoip
-
matchesPostal
Returns the value of thematchesPostalrecord component.- Returns:
- the value of the
matchesPostalrecord component
-
networkOperator
Returns the value of thenetworkOperatorrecord component.- Returns:
- the value of the
networkOperatorrecord component
-
numberType
Returns the value of thenumberTyperecord component.- Returns:
- the value of the
numberTyperecord component
-
country()instead.