Redefine the Task Bag interface from Exercise 8.1 in IDL so that it makes use of a struct to represent a Pair, which consists of a Key and a Value. Note that there is no need to use a typedef to define a struct.

What will be an ideal response?


```
typedef string Key;
typedef sequence Value;
struct Pair { Key key; Value value;
};
interface TaskBag {
readonly attribute int numberOfTasks;
exception TaskBagException { int no; string reason; };
void pairOut (in Pair) raises (TaskBagException);
// pairIn and readPair might use the pair, or could be left unchanged
};
```

Computer Science & Information Technology

You might also like to view...

Which of the following statements about critical sections is false?

a) Only one thread at a time can execute the instructions in its critical section for a particular resource. b) If one thread is already in its critical section, another thread must wait for the executing thread to exit its critical section before continuing. c) Once a thread has exited its critical section, a waiting thread may enter its critical section. d) All threads must wait whenever any critical section is occupied.

Computer Science & Information Technology

The Group, Sort, and Total pane appears when the Group & Sort button is selected

Indicate whether the statement is true or false

Computer Science & Information Technology

Both program instructions and the data to be processed must be stored in RAM.

Answer the following statement true (T) or false (F)

Computer Science & Information Technology

The MaskFull property will return a value of ____ if the mask area of a masked textbox is not completely filled.

A. True B. False C. 0 D. -1

Computer Science & Information Technology