Interface Messenger

All Known Implementing Classes:
ASPSMS, TextAnywhere, TwilioMessenger

public interface Messenger
SMS messenger interface.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final Pattern
    International phone number pattern without spaces, brackets or hyphens.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Initialize.
    void
    sms(String toNumber, String text)
    Send SMS.
  • Field Details

    • INTL_PHONE_NUMBER_PATTERN

      static final Pattern INTL_PHONE_NUMBER_PATTERN
      International phone number pattern without spaces, brackets or hyphens. Example: +41991119911
  • Method Details

    • init

      void init() throws Exception
      Initialize.
      Throws:
      Exception - if initialization fails
    • sms

      void sms(String toNumber, String text) throws Exception
      Send SMS.
      Parameters:
      toNumber - to phone number
      text - text
      Throws:
      Exception - if SMS fails