• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Should I learning Swing or applets?

 
Greenhorn
Posts: 19
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello
in my tutorial I arrive to applet chapter.
on of my old freind(C++/java fan)told me than dont waste your time to learning applet and swing and ...
populer browsers will not support them in near future.is it right ? cause I saw people asking a lot of question about them so seems they are important.
thanks
 
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Applets are deprecated and modern browsers disable them by default. You should not waste time on them.

Swing is used for more than just applets, so it might be worthwhile for creating desktop apps (though I believe that JavaFX is preferred).

If your aim is to create applications that run in the browser, then no, neither applets or Swing are viable. Web applications are not created using desktop GUI systems such as Swing.
 
Marshal
Posts: 28177
95
Eclipse IDE Firefox Browser MySQL Database
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Greg Sully wrote:cause I saw people asking a lot of question about them so seems they are important.



It usually takes people about five years before they let go of ideas which are obsolete, at least in the programming business. It's only been a couple of years since applets were finally rejected by the browser writers for their security failures, so you can expect people to be asking your question for a few more years.
 
Greg Sully
Greenhorn
Posts: 19
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
thanks for clarification.
 
Marshal
Posts: 79151
377
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Paul Clapham wrote:. . . It usually takes people about five years before they let go of ideas which are obsolete . . .

Unfortunately some of us in academia still seem to teach things which were obsolete or superseded twelve or fifteen years ago.
 
Saloon Keeper
Posts: 27752
196
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Likes 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Applets, alas, are a good idea whose timing was bad and then on top of that, there was the whole security debacle.

When applets first arrived, Microsoft got all snitty because they tried to embrace, extend, and extinguish Java and got slapped down in court. Thus, Java support was an expensive (in bandwidth/time) add-on to Windows that no one wanted to mess with. The Internet got faster, so the download issue got less (although a 78MB download is nothing to dismiss lightly). But by then there was a mess because too many different versions of Java were in use, and the mechanisms to co-ordinate them were lacking. Who want 7 different JVM versions at once? By the time bandwidth AND disk space became essentially non-issues, we then had the ruckus about all the security holes despite the idea that Java was a language with security built-in. So applets have been a spectacular failure.

Swing, on the other hand, is less so. Swing is actually one of 3 primary GUI platforms for Java. There was the original - AWT - which was weak and ugly, Swing, which built AWT into something decent, and SWT, which was a third-party GUI not created or supported directly by Sun, later Oracle. SWT is actually quite popular. The IBM-written Eclipse IDE is written in it, as are the GUI utilities for the Pentaho Business Intelligence suite from Hitachi Corp.

The nice thing about Java GUIs is that they are OS-independent. You can run a Swing-based Java app on Windows, MacOS, Linux and whatever Unixes are still kicking around. As well as  several more obscure java hosts. That makes it good for "universal" applications. Among the examples that take advantage of this write-once/run-anywhere capability are the ArgoUML design tool, the Universal GCode Sender (I've been playing with CNC equipment lately), and a high-performance video editor called ProjectX.

Although applets are a lost cause, there is still a way to get web users up and running on Java apps. The JNLP standard allows the fetching and caching of Java apps (not applets) from the web. This is the preferred way of installing ArgoUML, for example. Because JNLP is an app system, you don't run in a browser, you run as an independent OS process and the applet sandbox does not apply. There's no special coding required, either. Any Java app can be managed via jnlp.
 
What could go wrong in a swell place like "The Evil Eye"? Or with this tiny ad?
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic