Ask Question

Regardless of the type of communications device, there must be a way to transmit and receive data. Define an interface, CommDevice, with two methods: transmit, that accepts two parameters - - reference to a Destination object, and a string (in that order), and returns a boolean; and receive, that accepts a parameter of type Duration, and returns a reference to a String.

+4
Answers (1)
  1. 16 March, 20:26
    0
    abstract interface CommDevice {

    public abstract boolean transmit (Destination a, String b);

    public abstract String receive (Duration a);

    }

    Explanation:

    Line 1 of the above codes starts with defining the interface CommDevice that will accept two methods transmit and receive. The parameters of the method 'transmit' in the above code are (Destination a, String b). The boolean in line 2 of the code will ensure that the method returns a boolean.

    The parameters of the second method 'receive' in the above code is (Duration a) which will then return the reference to a string as indicated in line 3 of the code.
Know the Answer?
Not Sure About the Answer?
Find an answer to your question 👍 “Regardless of the type of communications device, there must be a way to transmit and receive data. Define an interface, CommDevice, with ...” in 📗 Computers & Technology if the answers seem to be not correct or there’s no answer. Try a smart search to find answers to similar questions.
Search for Other Answers