OS X Mavericks and Before
Historically, in fact, that green button at the top left has had two kinds of behaviors. If you're in a Finder window, clicking the green dot will expand the window as much as it can in order to show as many files as it can. Sometimes it can do that with a slight expansion and not take up the full display. Other times, expanding as much as it can in one direction cannot show all the files in that folder.
Note that if you hold the cursor over the green button, a “+” symbol appears as a prompt, reminding you what will happen.
For applications, each app tries to expand as much as possible, to maximize according to the developer's design, but the OS X menu bar remains visible. Clicking it again puts the window's size back to where it was before.
Finally, if you want to go full-screen, and the app supports it, the icon at the top right will do that. You leave full-screen mode with the ESC key.
Full-screen icon (top right).
OS X Yosemite
In Yosemite, for apps that have converted, the behavior changes. Apple's own Safari and Preview, flagship apps, are suggestive of how this will go, but not all apps in the public beta have been converted.
In Yosemite, the green button changes its default behavior.
1. The default behavior in OS X 10.10 is for the green button to go full-screen. (No menu bar.) That full-screen icon is now tiny and squished inside when you hover the mouse over it.
The full-screen icon is squished inside the green button.
2. Optional (previous) behavior. Hold the OPTION key down when you click, and the green button will behave as before. You'll see the familiar “+” symbol inside the green button.
I think this is a good move by Apple. Having a green button on the left side to do one similar thing and a full-screen icon on the right side to do another similar thing isn't great design. In Yosemite, we have a simpler, consistent interface.
It's always good to remember the prime directive of OS X computing. When in doubt, hold down the OPTION key and click. (Or CMD. Or CTRL.)