Article:
 |
|
The PHP Scalability Myth
|
| Subject: |
|
Dude's right! |
| Date: |
|
2003-10-18 01:23:46 |
| From: |
|
anonymous2
|
Response to: Dude's right!
|
Not to be disrespectful, but I do think you left out a few things.
For just a terminal
class HelloWorldApp {
public static void main(String[] args) {
System.out.println("Hello World!"); //Display the string.
}
}
For an Applet
import java.applet.Applet;
import java.awt.Graphics;
public class HelloWorld extends Applet {
public void paint(Graphics g) {
g.drawString("Hello world!", 50, 25);
}
}
For a Java Bean
package org.acme;
import java.rmi.RemoteException;
import javax.ejb.*;
public class HelloBean implements SessionBean {
private SessionContext sessionContext;
public void ejbCreate() {
}
public void ejbRemove() {
}
public void ejbActivate() {
}
public void ejbPassivate() {
}
public void setSessionContext(SessionContext sessionContext) {
this.sessionContext = sessionContext;
}
public String sayHello() throws java.rmi.RemoteException {
return "Hello World!!!!!";
}
}
|
Showing messages 1 through 1 of 1.
-
Dude's right!
2003-10-19 00:32:44
anonymous2
[View]
<% out.println("Hello world"); %>
pretty much the same as php isnt it...