|
|
EXPERT VIEW
Why Use Java in IBM Lotus Domino?
If you have a choice, try to use Java whenever possible. Why? Well, these reasons come to mind.
If you want to quickly start a heated argument in the IBM Lotus Domino development community, simply state that you think all code in a Domino application should be written in Java. Then quietly step back and watch the fireworks. You'll get as many opinions on Java as there are developers in the room (if not more). Why is the issue of Java in Domino so contentious?
We believe there are a number of reasons why there's such a passionate debate over Java. We've all developed cool Domino applications with the existing set of formula language and LotusScript. If it isn't broken, why fix it? In addition, the hype over Java has been constant for many years. There's a tendency to get into philosophical arguments about one language over another, and we often defend what we know best. And, finally, the IBM Lotus direction is moving more towards open standards and the use of Java everywhere. There's a fear that Domino is being killed off in favor of something that's harder to use and slower to develop. All understandable concerns, but there's another side.
In many cases, there truly is no advantage to doing an agent in Java as opposed to LotusScript. It ends up being a matter of preference or a case of writing code that others can maintain. If no one else in your office knows Java, you don't want to be the only one who can maintain the application. But if you have a choice, try to use Java whenever possible. Why? Well, some reasons come to mind...
- Java has an incredibly rich class library you can use. Java is a constantly evolving language with new classes, methods, and properties being added on a regular basis. When you import a class in Java, you get all the features that have been coded for you automatically. And if someone else has written a class that would do what you want, you can import it into your agent and start using it without reinventing the wheel. For instance, if you wanted to read a Web page in LotusScript to find some specific data, you'd have quite a chore ahead of you. But in Java, you can use the java.net classes to read a URL just like you'd read a file on your hard drive. And with the String classes, you have a wide choice of methods for parsing data. You can use a hammer to pound the nail instead of trying to find a rock that fits your hand.
- Java can interface to other non-Domino applications more easily. Java has become a common language in the non-Domino world. And because the language is designed to run the same code on many different platforms, it uses a standard definition of data types. If you want to use or pass an integer from Domino to some other program, there's no need to worry whether an integer means the same thing on both platforms. It will.
- You'll need it in the future envisioned by IBM Lotus. The Domino world is in the midst of a transition right now. The Notes/Domino we've come to know and love is still alive and kicking and will be for years to come. But Domino can now also take advantage of J2EE technology, such as servlets and JavaServer Pages. If you want to play in that brave new world, you're going to need to know Java. Why wait? You have a great opportunity to do so now.
- And finally, it's good for you! Personal success in the information technology field is largely determined (in our opinion) by your ability to continually learn new skills. Domino presents a unique opportunity to learn "mainstream" skills (such as HTML and JavaScript) and use them in an environment with which you're comfortable. That opportunity is once again present with Java. You can start learning a valuable new skill without leaving the safe confines of your familiar Notes application. What more could you ask for?
This article is an excerpt from "Java for Domino Developers" in LOTUS ADVISOR magazine, the first in a series on Java and Domino. In the article, Tom and Joe show you how to get into the Domino Designer IDE and code a Java agent, compile it, and view the output. Magazine subscribers can read the full article at http://Advisor.com/doc/13168.
In subsequent articles, they help you get familiar with Java by writing an e-mail notification agent in Java and then get into the details of the Java language by parsing a Web page from a Domino Java agent.
ARTICLE INFO
Web Edition: 2004 Week 34, Doc #14534
FREE ACCESS
Keyword Tags: application development, Application Development, collaboration, development, E-Mail, ibm, ibm lotus, ibm software, ibm websphere, IBM, IBM Lotus, IBM Lotus Domino, IBM Software, java, Java, lotusscript, Lotus @Formula Language, LotusScript, messaging, microsoft .net framework, Programming, software development
|
|