×
  • Share
  • Email
  • Embed
  • Like
  • Save
  • Private Content
 

Ruby For Java Programmers

by Entrepreneur on May 07, 2008

  • 12,641 views

One of the advantages of learning a new language is being exposed to new idioms and new approaches to solving old problems. In this talk, we will introduce the Ruby language with particular focus on ...

One of the advantages of learning a new language is being exposed to new idioms and new approaches to solving old problems. In this talk, we will introduce the Ruby language with particular focus on the idioms and concepts that are different from what is found in Java.

We will introduce concepts such as closures, continuations and meta programming. We will also examine powerful techniques that are practically impossible in Java due to its compile time binding of types.

No experience with Ruby is assumed although an understanding of Java would be helpful.

This talk was given at the Toronto Java Users Group in April 2008

Statistics

Views

Total Views
12,641
Views on SlideShare
12,215
Embed Views
426

Actions

Likes
43
Downloads
706
Comments
3

19 Embeds 426

http://www.jornaljava.com 141
http://localhost 83
http://jrubyscout.com 62
http://claudson.com.br 33
http://192.168.1.100 26
http://www.brijj.com 16
http://www.sphericalimprovement.com 14
http://www.slideshare.net 12
http://sutocom.net 11
http://lurnq.com 8
http://www.linkedin.com 6
http://lousyprogrammer.wordpress.com 4
http://new.lurnq.com 3
http://192.168.1.102 2
http://test.lurnq.com 1
http://www.techgig.com 1
http://static.slideshare.net 1
http://192.168.1.101 1
http://www.lurnq.com 1
More...

Accessibility

Categories

Upload Details

Uploaded via SlideShare as Microsoft PowerPoint

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel

13 of 3 previous next Post a comment

  • vstoyanov1 Vassil Stoyanov Mike, yes, it was helpful to understand what you meant. However, I still don't agree that java classes are not objects. The whole deal with static methods is that they are not really part of the class, just the java class construct doubles as placeholder for static methods (something like Modules in Ruby) and calling them through instances is indeed considered a bad practice (some IDEs generate warnings by default). There were many discussions on this topic and the general consensus is that it is an early design mistake already made.
    Other than that, java classes (their pure OOP part) are 100% objects and are treated as such both internally (by classloaders) and externally (by the Reflection API). The rest of the presentation is excellent though and it helped me grasp a couple of concepts I had been struggling with.

    Cheers and thanks,
    Vasil
    1 year ago
    Are you sure you want to
    Your message goes here
    Processing…
  • mbowler Mike Bowler, Entrepreneur Hi Vassil,

    Class objects appear in some ways to be objects and yet they aren't.

    Java has static methods which are just functions that are scoped to the class and that have access to the corresponding static variables. There is no 'this' pointer when executing a static method and there is no overriding of methods (although static methods in subclasses are able to hide methods with the same signatures in their superclass).

    In languages where classes are objects, the instances cannot call class methods on themselves, only on their classes. For example, in java I can say myObject.myClassMethod() whereas if the class was a true object, I would have to say myObject.getClass().myClassMethod()

    Does this help?
    1 year ago
    Are you sure you want to
    Your message goes here
    Processing…
  • vstoyanov1 Vassil Stoyanov Hello Mike,

    I have a question - on slide 15 you mention that unlike java classes, ruby classes are objects. However, Java classes are also instances of Class[1], which extends object and are constructed by the class-loader (also an object) upon their loading. What is the actual difference?

    Best, Vasil

    1. http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html
    1 year ago
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

Ruby For Java Programmers Ruby For Java Programmers Presentation Transcript