Class MachineToMachine

    • Method Detail

      • reader

        public static MachineToMachineReader reader​(String pathAccountSid,
                                                    String pathCountryCode)
        Create a MachineToMachineReader to execute read.
        Parameters:
        pathAccountSid - The SID of the Account requesting the AvailablePhoneNumber resources
        pathCountryCode - The ISO Country code of the country from which to read phone numbers
        Returns:
        MachineToMachineReader capable of executing the read
      • reader

        public static MachineToMachineReader reader​(String pathCountryCode)
        Create a MachineToMachineReader to execute read.
        Parameters:
        pathCountryCode - The ISO Country code of the country from which to read phone numbers
        Returns:
        MachineToMachineReader capable of executing the read
      • fromJson

        public static MachineToMachine fromJson​(String json,
                                                com.fasterxml.jackson.databind.ObjectMapper objectMapper)
        Converts a JSON String into a MachineToMachine object using the provided ObjectMapper.
        Parameters:
        json - Raw JSON String
        objectMapper - Jackson ObjectMapper
        Returns:
        MachineToMachine object represented by the provided JSON
      • fromJson

        public static MachineToMachine fromJson​(InputStream json,
                                                com.fasterxml.jackson.databind.ObjectMapper objectMapper)
        Converts a JSON InputStream into a MachineToMachine object using the provided ObjectMapper.
        Parameters:
        json - Raw JSON InputStream
        objectMapper - Jackson ObjectMapper
        Returns:
        MachineToMachine object represented by the provided JSON
      • getFriendlyName

        public final PhoneNumber getFriendlyName()
        Returns The A formatted version of the phone number.
        Returns:
        A formatted version of the phone number
      • getPhoneNumber

        public final PhoneNumber getPhoneNumber()
        Returns The The phone number in E.164 format.
        Returns:
        The phone number in E.164 format
      • getLata

        public final String getLata()
        Returns The The LATA of this phone number.
        Returns:
        The LATA of this phone number
      • getLocality

        public final String getLocality()
        Returns The The locality or city of this phone number's location.
        Returns:
        The locality or city of this phone number's location
      • getRateCenter

        public final String getRateCenter()
        Returns The The rate center of this phone number.
        Returns:
        The rate center of this phone number
      • getLatitude

        public final BigDecimal getLatitude()
        Returns The The latitude of this phone number's location.
        Returns:
        The latitude of this phone number's location
      • getLongitude

        public final BigDecimal getLongitude()
        Returns The The longitude of this phone number's location.
        Returns:
        The longitude of this phone number's location
      • getRegion

        public final String getRegion()
        Returns The The two-letter state or province abbreviation of this phone number's location.
        Returns:
        The two-letter state or province abbreviation of this phone number's location
      • getPostalCode

        public final String getPostalCode()
        Returns The The postal or ZIP code of this phone number's location.
        Returns:
        The postal or ZIP code of this phone number's location
      • getIsoCountry

        public final String getIsoCountry()
        Returns The The ISO country code of this phone number.
        Returns:
        The ISO country code of this phone number
      • getAddressRequirements

        public final String getAddressRequirements()
        Returns The The type of Address resource the phone number requires.
        Returns:
        The type of Address resource the phone number requires
      • getBeta

        public final Boolean getBeta()
        Returns The Whether the phone number is new to the Twilio platform.
        Returns:
        Whether the phone number is new to the Twilio platform
      • getCapabilities

        public final PhoneNumberCapabilities getCapabilities()
        Returns The Whether a phone number can receive calls or messages.
        Returns:
        Whether a phone number can receive calls or messages
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object