什么是Java的混合 - 小程序+应用程序? [英] What's Java Hybrid - Applet + Application?

查看:150
本文介绍了什么是Java的混合 - 小程序+应用程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

和我怎么能写一个?

从评论到我的回复,这遵循:

From comments to my reply, this followed:

我们曾在过去 - 一个applet和应用 - 不再提供

"What we had in the old days - An Applet and Application - is not available anymore."

和反驳:

垃圾。它[一个applet和应用程序]被称为混合动力车,并活得很好。问一个单独的问题,如果你想澄清。

Rubbish. It [An Applet and Application] is called an hybrid, and is alive and well. Ask on a separate question if you would like clarification.

我想问一下这个Java混合动力是什么?

我已经搜查,但由于某些原因无法找到任何东西有用的信息,那就是活得很好。我也许用微客这样的关键词可能是一个原因。

I have searched but for some reason can't find any useful information for something that is "alive and well". The keywords I used maybe slightly off so that could be a reason.

推荐答案

一个的混合的小程序/应用程序只是抽象的two顶层容器的JFrame JApplet的。例子可见这里,的这里这里

A hybrid applet/application simply abstracts the initialization of two top-level containers, JFrame and JApplet. Examples are seen here, here and here.

附录:?如何运作

  • The first example exposes a factory method, createGUI(), and it adds the returned panel to the extant top-level container.
  • The second provides a static initContainer() method, passing the enclosing top-level container as a parameter.
  • The third creates a class Hybrid that has a static fireup() method and a WindowListener for error reporting.

这篇关于什么是Java的混合 - 小程序+应用程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆