Package tech.checkhim.models
Class VerificationResponse
java.lang.Object
tech.checkhim.models.VerificationResponse
Represents the response from a phone number verification request.
Contains information about the phone number's validity, carrier information,
and other relevant verification details.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanGets the carrier/network provider name.Gets the country code (ISO 3166-1 alpha-2).Gets the numeric country code.Gets the full country name.Gets the line type (mobile, landline, etc.).Gets the network code.Gets the verification status code.getValid()Gets the validation status as a Boolean object.inthashCode()booleanisValid()Checks if the phone number is valid.voidsetCarrier(String carrier) Sets the carrier/network provider name.voidsetCountry(String country) Sets the country code.voidsetCountryCode(String countryCode) Sets the numeric country code.voidsetCountryName(String countryName) Sets the full country name.voidsetLineType(String lineType) Sets the line type.voidsetNetworkCode(String networkCode) Sets the network code.voidSets the verification status code.voidSets the validation status.toString()
-
Constructor Details
-
VerificationResponse
public VerificationResponse()Default constructor for JSON deserialization.
-
-
Method Details
-
isValid
public boolean isValid()Checks if the phone number is valid.- Returns:
- true if the phone number is valid, false otherwise
-
getValid
Gets the validation status as a Boolean object.- Returns:
- Boolean indicating validity, or null if not set
-
setValid
Sets the validation status.- Parameters:
valid- true if valid, false otherwise
-
getCarrier
Gets the carrier/network provider name.- Returns:
- The carrier name (e.g., "UNITEL", "VIVO")
-
setCarrier
Sets the carrier/network provider name.- Parameters:
carrier- The carrier name
-
getCountry
Gets the country code (ISO 3166-1 alpha-2).- Returns:
- The two-letter country code (e.g., "BR", "US")
-
setCountry
Sets the country code.- Parameters:
country- The country code
-
getCountryCode
Gets the numeric country code.- Returns:
- The country calling code (e.g., "55" for Brazil, "1" for US)
-
setCountryCode
Sets the numeric country code.- Parameters:
countryCode- The country calling code
-
getCountryName
Gets the full country name.- Returns:
- The country name (e.g., "Brazil", "United States")
-
setCountryName
Sets the full country name.- Parameters:
countryName- The country name
-
getLineType
Gets the line type (mobile, landline, etc.).- Returns:
- The line type
-
setLineType
Sets the line type.- Parameters:
lineType- The line type
-
getNetworkCode
Gets the network code.- Returns:
- The network code
-
setNetworkCode
Sets the network code.- Parameters:
networkCode- The network code
-
getStatus
Gets the verification status code.- Returns:
- The status code (e.g., "DELIVERED_TO_HANDSET", "REJECTED_NETWORK")
-
setStatus
Sets the verification status code.- Parameters:
status- The status code
-
toString
-
equals
-
hashCode
public int hashCode()
-