Yes, that's correct. Just keep in mind that a whole note need not fit in a single measure. For example, in 6/8 time, a whole note gets eight beats, but each measure only has 6. Similarly, for 3/4 time, a whole note gets four beats, but each measure contains only three.
See also I don't understand the bottom number in a time signature, which explains the same concept in a different way.