Slashdot Mirror


Stanford Offers Cocoa Class

An anonymous reader writes "Back in the early 90's Stanford University offered a class on Objective-C for students interested in writing applications for NeXTSTEP. After a long hiatus it appears that class will be offered again as CS193E, 'Object-oriented User Interface Programming.' It will be covering the Apple development tools, Objective-C, Foundation and AppKit, and Quartz. Any other schools out there planning or already offering Objective-C courses?"

13 of 91 comments (clear)

  1. Re:Why? by phch · · Score: 5, Informative

    This class is in the Stanford CS193 series, which consists of lighter workload classes often taken by students outside the CS department, and geared for specific technologies. I don't believe CS majors get much credit for taking these classes. The core CS classes at Stanford are much less focused on details of specific languages (although Java is featured in the main intro OOP class; I guess you have to pick something).

    Stanford has offered classes in .NET, Microsoft MFC, and Java, so a class in Cocoa is not too surprising.

  2. Berkeley teaches Cocoa courses by JoshWurzel · · Score: 5, Informative

    UC Berkeley has already had a handful of Cocoa and mac development courses, most taught by my roommate. These courses, though student run, earned real CS credits and had labs, projects, etc. He just graduated, so someone else will have to take up the torch. And it won't be me.

    Personally, I think its a great idea. Many, many students get out of CS schools with vague notions of how to write a compiler in LISP, or what the best way to implement XYZ (without understanding why it SHOULD be implemented). As if anyone cares. Macs may be a small market, but a Cocoa class is teaching a useful, marketable skill that can be directly applied to real-world application development.

  3. Re:Why? Don't Know by WasterDave · · Score: 2, Informative

    Wouldn't it be better to focus (as an elective course) on cross-platform development like Java, which can run on Mac?

    No, because Java on a Mac runs slowly like you wouldn't believe. Objective-C is faster and, honestly, is no harder than Java.

    Apart from the memory management.

    Dave

    --
    I write a blog now, you should be afraid.
  4. As a Stanford CS graduate... by John+Harrison · · Score: 4, Informative
    I can tell you that 193 courses are optional and do not count towards your degree. They are offered to give students practical exposure to real world concepts and languages that they otherwise would not get. They are often taken by majors in other engineering departments, so that they can get the programming skills they need for their own projects.

    The Stanford CS courses required for graduation are much more theory based than the 193 series. Even without the 193 series (which many students completely ignore), Stanford CS majors learn to program well. The 106 series is considered a model of how to teach students to program. Business Week even did a large article on it a few years ago. Oh, and we get an algorithms course or two as well.

  5. you want 193J by John+Harrison · · Score: 2, Informative

    I know they offer a similar course in Java because I took it. It just isn't offered for winter quarter. It was a good course, especially considering how new Java was.

  6. Re:what's the difference from C++ by MouseR · · Score: 4, Informative

    One of the coolest features of Objective-C, also available in Java (though I'm no expert on Java), is introspection.

    Through introspection, an object, or a class object (loosely, that's a static class instance for static methods of your class), can interrogate themselves for variable names and types as well as the functions they support.

    Only with object introspection can you send message (aka, method calls) to objects who may or may not understand (aka, implement), said message.

    With this, i've created a really nifty (and open source) SQLite-based object persistence library called Objective-SQL.

    Basically, you just derive a class from my Objective-SQL classes and they can automatically instantiate themselves from SQL table rows through various Find* methods I've implemented in there. Simply change data member values and call [myObject commit] and voila.

    Also, there is relational capabilities given a Category to the system NSString class that allows you to turn an object into a string reference, and this string reference back into an object automatically fetched from the SQL database.

    One could derive the SQLTransport and redirect actual storage and retrieval to other SQL solutions, like PostGre, MySQL, oracle etc.

  7. course website by patrickoehlinger · · Score: 5, Informative

    Following the schema of all Stanford CS courses, it will soon be at: /class/cs193e/
    Since it already has a "Under construction...", the professor's assistant is probably already busy preparing the page.

    --
    >> Had I been going to bed earlier every night? Have I been sleeping later? Has Tyler been in charge longer and l
  8. Re:what's the difference from C++ by awhite · · Score: 5, Informative

    IANAOCP (I Am Not An Objective C Programmer), but from my limited experience, Objective-C and C++ went in pretty much completely opposite directions in how they decided to add object-orientation to C.

    In C++, everything is statically typed, and performance is a primary goal. Objective C has more overhead, but is much more dynamic. Some cool Objective-C features (note: in Objective-C parlance, "message passing" is basically method invocation):

    - Very weak typing. If you want to, you can just pass around all your objects as variables of the built-in type "id", and this allows you to send any message to any object without casting, and of course to build container classes that hold any object. If you want some more typing help from the compiler, you can use typed pointer variables to reference objects, in which case it'll warn you about passing messages that the class doesn't implement.

    - Message forwarding. I've always loved this feature in languages that have it. Makes it so easy to create delegating objects -- you can implement a single "catch-all" type method that allows you to forward any unsupported messages someone passes to your object on to another object.

    - Categories/mix-ins. Add functionality to existing classes without having to extend them. The functionality is automatically given to all instances of the class the program creates.

    - Sending messages to nil (null). Rather than throwing an exception when you try to send a message to a nil reference, Objective-C just returns nil back. Sounds weird, but this actually saves a lot of nil checks in practice.

    - Introspection, which others have mentioned. Facilities to figure out what messages an object or type can respond to, to create new instances given the type name, to send messages based on the method name, etc.

    - Methods as first-class objects. You can elegantly pass around method pointers, and the Cocoa frameworks take advantage of this for GUI callbacks and such. If you're familiar with C# and Java, Objective-C is similar to to C# in this respect, and I much prefer these sorts of method callbacks to Java's system of creating (usually anonymous) listener classes.

    There are a lot of other advanced late-binding things you can do in Objective C too. I have some complains with the language (it's a little too verbose for my tastes, for one), but overall it seems like a great language for building dynamic systems and GUIs.

  9. Re:what's the difference from C++ by bay43270 · · Score: 3, Informative

    Introspection isn't possible without late binding, but not all languages with late binding have introspection. In Java (and other languages) introspection is called Reflection. It simply allows the attributes of an object to be queried. I don't program in C++, but from my understanding, it doesn't have this feature.

  10. Re:what's the difference from C++ by MouseR · · Score: 2, Informative

    I'm a Cocoa developer. I know about EOF, but it's been both canned by Apple, and I am gearing some of my work towards a partial replacement to EOF (at least for my very own needs).

    Objective-SQL also contains a SQLWebForm class whose purpose it to show SQL object data into template pages to yield final html pages.

  11. I'm glad you asked.. by jcr · · Score: 4, Informative

    why would a C++ programmer want to program in objective C or vica versa?

    This is one of the best descriptions of the difference between C++ and Obj-C, and the benefits of dynamic binding, that I've ever happened across.

    -jcr

    --
    The only title of honor that a tyrant can grant is "Enemy of the State."
    1. Re:I'm glad you asked.. by jcr · · Score: 2, Informative

      Whatever happened to kdyke?

      He's at Apple, in the Graphics & Imaging department.

      If you attended Apple's developer conferences, he usually presents topics related to OpenGL.

      He's got a web site at www.nsobject.com. Some cool stuff there, but it hasn't been updated in quite a while..

      -jcr

      --
      The only title of honor that a tyrant can grant is "Enemy of the State."
  12. Yeah, by ernstp · · Score: 2, Informative

    my school does.
    The cource is called Human-Computer Interaction and it's on the CS Department at Lund University (Sweden).

    http://www2.cs.lth.se/dat006/index.html

    I plan on taking it sometime soon, if they don't cancel the whole cource.

    I've seen them using Interface Builder on their labs and such. Unfortunately we only have 14 Macs, so the excercises may get a little crowded..