— Scott McNealy, Sun Microsystems Chairman, President and ceo



Download 40,57 Mb.
Pdf ko'rish
bet318/555
Sana26.05.2022
Hajmi40,57 Mb.
#609235
1   ...   314   315   316   317   318   319   320   321   ...   555
Bog'liq
Head First Java (Kathy Sierra, Bert Bates) (z-lib.org)

1
2
3
A try with only a finally (no catch) 
must still declare the exception.
void go() throws FooException {
try {
x.doStuff();
} finally { }
}
4
A try without a catch 
doesn’t satisfy the 
handle or declare law


you are here
4
exception 
handling
339
Code Kitchen
There is NO way 
I’m letting Betty win the 
code-off this year, so I’m 
gonna make it myself from 
scratch.
But why don’t 
you just use 
Ready-bake code?
You don’t have to do it 
yourself, but it’s a lot 
more fun if you do.
The rest of this chapter 
is optional; you can use 
Ready-bake code for all 
the music apps.
But if you want to learn 
more about JavaSound, 
turn the page.


340
 
chapter 11
Remember near the beginning of the chapter, we looked at how MIDI data holds 
the instructions for what should be played (and how it should be played) and we 
also said that MIDI data doesn’t actually create any sound that you hear. For sound 
to come out of the speakers, the MIDI data has to be sent through some kind of 
MIDI device that takes the MIDI instructions and renders them in sound, either 
by triggering a hardware instrument or a ‘virtual’ instrument (software synthe-
sizer). In this book, we’re using only software devices, so here’s how it works in 
JavaSound:
Making actual sound
You need FOUR things:
Sequencer
plays
has a
Midi 
Event
Midi 
Event
Midi 
Event
Sequence
Track
Midi 
Event
holds
The Sequencer is the thing 
that actually causes a song 
to be played. Think of it like 
music CD player.
The Sequence is the 
song, the musical piece 
that the Sequencer will 
play. For this book, think 
of the Sequence as a 
music CD, but the whole 

Download 40,57 Mb.

Do'stlaringiz bilan baham:
1   ...   314   315   316   317   318   319   320   321   ...   555




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©hozir.org 2024
ma'muriyatiga murojaat qiling

kiriting | ro'yxatdan o'tish
    Bosh sahifa
юртда тантана
Боғда битган
Бугун юртда
Эшитганлар жилманглар
Эшитмадим деманглар
битган бодомлар
Yangiariq tumani
qitish marakazi
Raqamli texnologiyalar
ilishida muhokamadan
tasdiqqa tavsiya
tavsiya etilgan
iqtisodiyot kafedrasi
steiermarkischen landesregierung
asarlaringizni yuboring
o'zingizning asarlaringizni
Iltimos faqat
faqat o'zingizning
steierm rkischen
landesregierung fachabteilung
rkischen landesregierung
hamshira loyihasi
loyihasi mavsum
faolyatining oqibatlari
asosiy adabiyotlar
fakulteti ahborot
ahborot havfsizligi
havfsizligi kafedrasi
fanidan bo’yicha
fakulteti iqtisodiyot
boshqaruv fakulteti
chiqarishda boshqaruv
ishlab chiqarishda
iqtisodiyot fakultet
multiservis tarmoqlari
fanidan asosiy
Uzbek fanidan
mavzulari potok
asosidagi multiservis
'aliyyil a'ziym
billahil 'aliyyil
illaa billahil
quvvata illaa
falah' deganida
Kompyuter savodxonligi
bo’yicha mustaqil
'alal falah'
Hayya 'alal
'alas soloh
Hayya 'alas
mavsum boyicha


yuklab olish