View this PageEdit this PageAttachments to this PageHistory of this PageHomeRecent ChangesSearch the SwikiHelp Guide
Hotspots: Admin Pages | Turn-in Site |
Current Links: Cases Final Project Summer 2007

How Do I?

There are a number of ways to search Squeak for existing code. This page describes several of them. Note, it won't always work out, but it's usually worth at least a try.

  1. Look it up in the text book's index – you never know!
  2. Look through the apendix to the text book – it has a number of basic Squeak examples.
  3. Try some obvious names. Eg,
    'abc' shuffled
    actually works! Try to think like the code's author would have; it's an extremely useful skill, and you will get better at it over time.
  4. Browse code in relevant-sounding classes and their superclasses. If you are trying to find a numeric operation, look in classes like Number, Integer, and Float.
  5. Give the method finder some examples and see if it can turn up a method that does exactly what you need. Using the method finder this way make take a bit of getting used to, but it's well worth it.
  6. Give the method finder part of a method name to search for, eg "token".
  7. As a last resort, you can search the entire source code base for a string. For example, if you type "concatenate" into a workspace and select "method source with it", you will (eventually) be shown a list of 9 methods including #, .

Link to this Page