United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
JDK-4916909 : SPEC: MidiDevice should specify open/close behaviour precisely

Details
Type:
Bug
Submit Date:
2003-09-03
Status:
Resolved
Updated Date:
2003-11-07
Project Name:
JDK
Resolved Date:
2003-11-07
Component:
client-libs
OS:
generic
Sub-Component:
javax.sound
CPU:
generic
Priority:
P4
Resolution:
Fixed
Affected Versions:
5.0
Fixed Versions:
5.0 (b28)

Related Reports

Sub Tasks

Description
For the class javax.sound.midi.MidiDevice, the behaviour on calls to open() and close() is not specified if used in combination with getReceiver(), getTransmitter, Receiver.close(), Transmitter.close(), MidiSystem.getReceiver() and MidiSystem.getTransmitter().

The specification should tell:
- MidiSystem.getReceiver() and MidiSystem.getTransmitter() open the underlying device implicitly.

- Receivers/Transmitters retrieved via MidiSystem close the underlying device implicitly if their close() method is called and the device hasn't been opened explicitly. If more than one Transmitter or Receiver (that implicitly opened the device) are open, the device is closed after the last Receiver or Transmitter has been closed (and the device hasn't been opened explicitly).

- Receivers and Transmitters retrieved via the device's getReceiver() and getTransmitter() methods do not open the underlying device implicitly. Closing such Receivers or Transmitters does not close the device implicitly. This is true even if there are Receivers or Transmitters for the same device that opened the device implicitly.

- a call to the device's open() method explicitly openes the device. After such a call, the device stays open even if all Transmitters or Receivers has been closed. (The only way to close a device after an explicit call to open() is an explicit call to close().)

- a call to the device's close() method closes all Transmitters and Receivers related to this device, then closes the device itself. This behaviour is independend on wether the Transmitters and Receivers opened the device implicitly or not. Furthermore, it is independant on wether the device has been opened explicitly via open().

###@###.### 2003-11-03
checked in fix

                                    

Comments
CONVERTED DATA

BugTraq+ Release Management Values

COMMIT TO FIX:
tiger
tiger-beta

FIXED IN:
tiger-beta

INTEGRATED IN:
tiger-b28
tiger-beta


                                     
2004-06-14
PUBLIC COMMENTS

SPEC: MidiDevice should specify open/close behaviour precisely
                                     
2004-06-10
EVALUATION

###@###.### 2003-09-03
Valid request. No coding work required.
                                     
2003-09-03



Hardware and Software, Engineered to Work Together