< prev index next >
src/java.desktop/share/classes/com/sun/media/sound/SoftProvider.java
Print this page
*** 1,7 ****
/*
! * Copyright (c) 2007, 2014, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
--- 1,7 ----
/*
! * Copyright (c) 2007, 2015, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
*** 23,32 ****
--- 23,34 ----
* questions.
*/
package com.sun.media.sound;
+ import java.util.Objects;
+
import javax.sound.midi.MidiDevice;
import javax.sound.midi.spi.MidiDeviceProvider;
/**
* Software synthesizer provider class.
*** 40,49 ****
--- 42,52 ----
return new MidiDevice.Info[]{SoftSynthesizer.info};
}
@Override
public MidiDevice getDevice(final MidiDevice.Info info) {
+ Objects.requireNonNull(info);
if (SoftSynthesizer.info.equals(info)) {
return new SoftSynthesizer();
}
throw MidiUtils.unsupportedDevice(info);
}
< prev index next >