重慶分公司,新征程啟航
為企業(yè)提供網(wǎng)站建設(shè)、域名注冊、服務(wù)器等服務(wù)
為企業(yè)提供網(wǎng)站建設(shè)、域名注冊、服務(wù)器等服務(wù)
import java.awt.*;
成都創(chuàng)新互聯(lián)主營石樓網(wǎng)站建設(shè)的網(wǎng)絡(luò)公司,主營網(wǎng)站建設(shè)方案,重慶APP開發(fā)公司,石樓h5小程序定制開發(fā)搭建,石樓網(wǎng)站營銷推廣歡迎石樓等地區(qū)企業(yè)咨詢
import java.awt.event.*;
import java.util.Random;
import javax.swing.Timer;
public class PinBall
{
private final int TABLE_WIDTH = 300;//桌面寬度
private final int TABLE_HEIGHT = 400;//桌面高度
private final int RACKET_Y = 340;//球拍的垂直位置
private final int RACKET_HEIGHT = 20;//球拍高度
private final int RACKET_WIDTH = 60;//球拍寬度
private final int BALL_SIZE = 16;//球的大小
private Frame f = new Frame("彈球游戲");//實(shí)例化一個窗口
Random rand = new Random();//實(shí)例化一個隨機(jī)數(shù)生成器
private int ySpeed = 10;//小球的縱向運(yùn)動數(shù)度、
private double xyRate = rand.nextDouble() - 0.5;//返回一個-0.5到0.5之間的比率用控制小球運(yùn)動方向
private int xSpeed = (int)(ySpeed*xyRate*2);//這個橫向速度在-10到10之間,產(chǎn)生左右擺動運(yùn)動效果
private int ballX = rand.nextInt(200)+20;//小球開始的橫坐標(biāo)位置,200表示產(chǎn)生0到100之間的隨機(jī)數(shù)
private int ballY = rand.nextInt(10)+20;//小球開始的縱坐標(biāo)位置
private int racketX = rand.nextInt(200);//球拍開始時的橫坐標(biāo)位置
private MyCanvas tableArea = new MyCanvas();//實(shí)力化一個畫布工具,集成Canvas類
private String shape = "";//保存需要繪制圖形的字符串屬性
Timer timer;//聲明一個時間變量
private boolean isLose = false;//表示游戲是否結(jié)束
public void init()
{
tableArea.setPreferredSize(new Dimension(TABLE_WIDTH,TABLE_HEIGHT));//定義畫布大小
f.add(tableArea);//添加畫布到窗口
KeyAdapter keyProcessor = new KeyAdapter()//實(shí)例化一個鍵盤監(jiān)聽事件適配器
{
public void keyPressed(KeyEvent ke)//重寫適配器里面的按下某鍵盤方法
{
if(ke.getKeyCode()==KeyEvent.VK_LEFT)//按下鍵盤左鍵時
{
if(racketX 0)//球拍左邊框不能出畫布的左邊框
racketX -=10;//按一左鍵次向左移動10個像素
}
if(ke.getKeyCode()==KeyEvent.VK_RIGHT)//按下鍵盤右鍵時
{
if(racketX TABLE_WIDTH - RACKET_WIDTH)//球拍右邊框不能出畫布的右邊框
racketX +=10;//按一次右鍵移動向右移動10個像素
}
}
};
f.addKeyListener(keyProcessor);//給窗口添加鍵盤監(jiān)聽器
tableArea.addKeyListener(keyProcessor);//給畫布添加鍵盤監(jiān)聽器
ActionListener taskPerformer = new ActionListener()//這里是實(shí)例化了一個監(jiān)聽接口,這個接口里面只有一個方法
{
public void actionPerformed(ActionEvent evt)//重寫這個接口里面的方法,判斷小球的位置
{
if(ballX=0 || ballX=TABLE_WIDTH-BALL_SIZE)//保證小球橫向上在畫布之內(nèi)運(yùn)動
{
xSpeed = -xSpeed;//觸發(fā)反方向運(yùn)動
}
if(ballY=RACKET_Y-BALL_SIZE(ballXracketX||ballXracketX+RACKET_WIDTH))//出了球拍的可擊打范圍
{
timer.stop();//停止對監(jiān)聽器的觸發(fā)
isLose=true;//將標(biāo)志isLose變量置為true
tableArea.repaint();//調(diào)用畫布的重繪方法
}
else if(ballY=0||(ballY=RACKET_Y-BALL_SIZEballYracketXballX=racketX+RACKET_WIDTH))//小球在球拍之內(nèi),而其到達(dá)球拍的高度
{
ySpeed=-ySpeed;//上下方向改變,小球反彈
}
ballY+=ySpeed;//小球的坐標(biāo)在縱向上增加
ballX+=xSpeed;//小球的坐標(biāo)在橫向上的增加
tableArea.repaint();//調(diào)用畫布的重繪方法3
}
};
timer = new Timer(100,taskPerformer);//每隔0.1秒運(yùn)行一次監(jiān)聽器
timer.start();//計(jì)時器開始運(yùn)行
f.addWindowListener(new MyListener());//關(guān)閉窗口事件
f.pack();//設(shè)置窗口最佳大小
f.setVisible(true);//顯示窗口
}
class MyListener extends WindowAdapter//關(guān)閉窗口的類
{
public void windowClosing(WindowEvent e)
{
System.exit(0);
}
}
public static void main(String[] args)//程序入口
{
new PinBall().init();//調(diào)用PinBall類里面的init()方法
}
class MyCanvas extends Canvas//建一個集成Canvas類的類
{
public void paint(Graphics g)//重寫父類的繪圖方法
{
if(isLose)//如果isLose為真,則在畫布里打印“游戲已結(jié)束”
{
g.setColor(new Color(255,0,0));//當(dāng)前顏色
g.setFont(new Font("黑體",Font.BOLD,30));//字體名稱,樣式,大小
g.drawString("游戲已結(jié)束!",50,200);//按坐標(biāo)繪制文字圖形
}
else//負(fù)責(zé)
{
g.setColor(new Color(240,240,80));//當(dāng)前顏色
g.fillOval(ballX,ballY,BALL_SIZE,BALL_SIZE);//填充顏色,根據(jù)坐標(biāo)和長寬填充圓形
g.setColor(new Color(80,80,200));//當(dāng)前顏色
g.fillRect(racketX,RACKET_Y,RACKET_WIDTH,RACKET_HEIGHT);//填充顏色,根據(jù)坐標(biāo)和長寬填充矩形
}
}
}
}
只有矩形有圓形能移動,其它實(shí)現(xiàn)起來麻煩點(diǎn),辦法有的只是代碼太多。
畫圓弧改成了畫曲線,圓弧稍麻煩,當(dāng)然方法是很簡單的,你可以自己思考一下。
雙擊13個顏色中的任意一個都會彈出顏色選擇器。
有保存與打開功能。擴(kuò)展名請用 .jdr
基本滿足條件,細(xì)節(jié)可能不是很好,另,代碼比較亂,怕不好看懂咯,呼呼。
import java.awt.*;
import java.awt.event.*;
import java.awt.geom.*;
import java.awt.image.BufferedImage;
import java.io.*;
import java.util.ArrayList;
import javax.swing.*;
import javax.swing.filechooser.FileNameExtensionFilter;
public class JDraw {
public static void main(String[] args) {
JFrame f=new JFrame();
f.setDefaultCloseOperation(3);
f.setSize(880,600);
f.setLocationRelativeTo(null);
f.getContentPane().add(M.c);
f.getContentPane().add(M.m,"South");
f.setVisible(true);
}
}
class CVS extends Component implements ComponentListener,MouseListener,MouseMotionListener{
public void componentHidden(ComponentEvent e) {}
public void componentMoved(ComponentEvent e) {}
public void componentResized(ComponentEvent e) {resized();}
public void componentShown(ComponentEvent e) {}
private void resized() {
int w=this.getWidth();
int h=this.getHeight();
tbuff=new BufferedImage(w,h,3);
makeBuff(w,h);
}
private void makeBuff(int w,int h) {
Graphics g = tbuff.getGraphics();
g.drawImage(buff,0,0,null);
g.dispose();
buff=new BufferedImage(w,h,3);
g=buff.getGraphics();
g.drawImage(tbuff,0,0,null);
g.dispose();
}
BufferedImage buff,tbuff;
CVS(){
this.addComponentListener(this);
this.addMouseListener(this);
this.addMouseMotionListener(this);
buff=new BufferedImage(1,1,3);
}
public void paint(Graphics gr){
Graphics2D g = buff.createGraphics();
g.setBackground(new Color(0xff000000,true));
g.clearRect(0,0,getWidth(),getHeight());
g.setRenderingHint(RenderingHints.KEY_ANTIALIASING,
RenderingHints.VALUE_ANTIALIAS_ON);
M.sa.drawAll(g);
if(M.ts!=null)
M.ts.draw(g);
g.dispose();
gr.drawImage(buff,0,0,this);
gr.dispose();
}
public void mouseClicked(MouseEvent e) {}
public void mouseEntered(MouseEvent e) {}
public void mouseExited(MouseEvent e) {}
public void mousePressed(MouseEvent e) {
M.mp(e.getPoint());
}
public void mouseReleased(MouseEvent e) {
M.mr(e.getPoint());
}
public void mouseDragged(MouseEvent e) {
M.md(e.getPoint());
}
public void mouseMoved(MouseEvent e) {}
}
class Menu extends JComponent implements MouseListener,ActionListener{
JComboBox sbox,method;
CLabel[] cl;
JCheckBox fillC,drawB;
JRadioButton fc,bc;
ButtonGroup bg;
JButton clear,up,down,save,load;
Menu(){
this.setLayout(new FlowLayout());
method=new JComboBox(new Object[]{"draw","move","erase",});
add(method);
sbox=new JComboBox(new Object[]{"Pt","Ln","Rect","Cir","Arc",});
add(sbox);
cl=new CLabel[13];
for(int i=0; icl.length; i++){
cl[i]=new CLabel();
cl[i].addMouseListener(this);
add(cl[i]);
}
fc=new JRadioButton("fc",true);
bc=new JRadioButton("bc");
bg=new ButtonGroup();
bg.add(fc);bg.add(bc);
add(fc);add(bc);
fc.setOpaque(true);
bc.setOpaque(true);
fc.setBackground(Color.white);
bc.setBackground(Color.blue);
fillC=new JCheckBox("Fill",true);
drawB=new JCheckBox("Draw",true);
fillC.addActionListener(this);
drawB.addActionListener(this);
add(fillC);add(drawB);
clear=new JButton("clear");
clear.addActionListener(this);
add(clear);
up=new JButton("zUp");
up.addActionListener(this);
add(up);
down=new JButton("zDown");
down.addActionListener(this);
add(down);
save=new JButton("Save");
save.addActionListener(this);
add(save);
load=new JButton("Load");
load.addActionListener(this);
add(load);
}
public void mouseClicked(MouseEvent e) {
JLabel l=(JLabel)e.getSource();
if(e.getClickCount()==2){
Color sc=JColorChooser.showDialog(null, "Color chooser", l.getBackground());
l.setBackground(sc);
mousePressed(e);
}
}
public void mouseEntered(MouseEvent e) {}
public void mouseExited(MouseEvent e) {}
public void mousePressed(MouseEvent e) {
Color c=((JLabel)e.getSource()).getBackground();
if(fc.isSelected())
fc.setBackground(c);
else if(bc.isSelected())
bc.setBackground(c);
M.cp();
}
public void mouseReleased(MouseEvent e) {}
public void actionPerformed(ActionEvent e) {
if(e.getSource()==clear)M.clear();
else if(e.getSource()==up)M.up();
else if(e.getSource()==down)M.down();
else if(e.getSource()==save)M.save();
else if(e.getSource()==load)M.load();
else if(e.getSource()==fillC||e.getSource()==drawB)M.cp();
}
}
class CLabel extends JLabel{
static Color[] cs={Color.red,Color.orange,Color.yellow,Color.green,Color.cyan,
Color.blue,Color.magenta,Color.magenta.brighter(),
Color.white,Color.black,Color.gray,Color.LIGHT_GRAY,Color.DARK_GRAY,};
static int i;
CLabel(){
this.setOpaque(true);
this.setBackground(cs[i++]);
this.setBorder(BorderFactory.createLineBorder(Color.black));
this.setPreferredSize(new Dimension(10,20));
}
}
class M{
static JFileChooser jfc=new JFileChooser();
static Menu m=new Menu();
static CVS c=new CVS();
static SA sa=new SA();
static S ts=null,selected=null;
static Color fc,bc;
static void clear(){
sa.ss.clear();
c.repaint();
}
public static void cp() {
System.out.println(selected);
if(selected!=null){
selected.fillColor=m.fc.getBackground();
selected.borderColor=m.bc.getBackground();
selected.fc=m.fillC.isSelected();
selected.db=m.drawB.isSelected();
c.repaint();
}
}
public static void up() {
if(selected!=null){
sa.upZ(selected);
c.repaint();
}
}
public static void down(){
if(selected!=null){
sa.downZ(selected);
c.repaint();
}
}
static{
jfc.setFileFilter(new FileNameExtensionFilter("JDraw file (*.jdraw,*.jdr)","jdr","jdraw"));
}
static void save(){
int x=jfc.showSaveDialog(c);
if(x==JFileChooser.APPROVE_OPTION){
File f = jfc.getSelectedFile();
try{
ObjectOutputStream oos=new ObjectOutputStream(new FileOutputStream(f));
oos.writeObject(sa);
oos.flush();
oos.close();
}catch(Exception e){}
}
}
static void load(){
int x=jfc.showOpenDialog(c);
if(x==JFileChooser.APPROVE_OPTION){
File f = jfc.getSelectedFile();
try{
ObjectInputStream oos=new ObjectInputStream(new FileInputStream(f));
Object r=oos.readObject();
if(r!=null){
sa=(SA)r;
c.repaint();
}
oos.close();
}catch(Exception e){e.printStackTrace();}
}
}
static int mx,my,tx,ty,ox,oy;
static int pc=0,pmax;
static int sm;
static boolean ne=true;
static int mid;
static void mp(Point p){
mid=m.method.getSelectedIndex();
if(mid==0){
if(ne){
mx=p.x;my=p.y;
pc=0;
sm=m.sbox.getSelectedIndex();
pmax=sm==4?2:1;
ne=false;
}
++pc;
}
else if(mid==1){
checkSel(p);
mx=p.x;my=p.y;
}
else if(mid==2){
checkSel(p);
if(selected!=null){
sa.ss.remove(selected);
c.repaint();
}
}
}
private static void checkSel(Point p) {
selected=null;
for(int i=sa.ss.size();i0; i--)
if(sa.ss.get(i-1).shape.contains(p)){
selected=sa.ss.get(i-1);break;
}
sa.select(selected);
c.repaint();
}
static void mt(){
Shape s=null;
int cx,cy,cw,ch;
switch(sm){
case 0:
case 2:
cx=Math.min(mx,tx);
cy=Math.min(my,ty);
cw=Math.abs(mx-tx);
ch=Math.abs(my-ty);
if(sm==0)
s=new Ellipse2D.Double(cx,cy,cw,ch);
else
s=new Rectangle(cx,cy,cw,ch);
break;
case 1:
s=new Line2D.Float(mx,my,tx,ty);
break;
case 3:
cw=Math.abs(mx-tx);
ch=Math.abs(my-ty);
int cd=(int)Math.sqrt(Math.pow(mx-tx,2)+Math.pow(my-ty,2))*2;
cx=mx-cd/2;
cy=my-cd/2;
s=new Ellipse2D.Double(cx,cy,cd,cd);
break;
case 4:
Path2D p=new Path2D.Double();
p.moveTo(mx,my);
if(pc==1){
p.lineTo(tx, ty);
}
else{
p.quadTo(ox,oy,tx,ty);
}
s=p;
break;
}
ts=new S(s,m.fc.getBackground(),m.bc.getBackground(),m.fillC.isSelected(),m.drawB.isSelected(),null);
c.repaint();
}
static void md(Point p){
if(mid==0){
if(!sa.ss.isEmpty()){
sa.ss.get(sa.ss.size()-1).sel=false;
}
if(pc1){
ox=p.x;oy=p.y;
}
else{
tx=p.x;ty=p.y;
}
mt();
}
else if(mid==1){
if(selected!=null){
moveTo(selected,p);
c.repaint();
}
}
else if(mid==2){
checkSel(p);
if(selected!=null){
sa.ss.remove(selected);
c.repaint();
}
}
}
static void moveTo(S s, Point p) {
if(s.shape instanceof Rectangle){
Rectangle r=(Rectangle)s.shape;
r.setLocation(r.x+p.x-mx,r.y+p.y-my);
mx=p.x;my=p.y;
}
else if(s.shape instanceof Ellipse2D){
Ellipse2D e=(Ellipse2D)s.shape;
e.setFrame(e.getX()+p.x-mx,e.getY()+p.y-my,e.getWidth(),e.getHeight());
mx=p.x;my=p.y;
}
}
static void mr(Point p) {
if(pc==pmax){
pc=0;
ne=true;
sa.add(ts);
selected=ts;
ts=null;
}
}
}
class S implements Serializable{
boolean fc,db,sel=true;
Shape shape;
Color fillColor,borderColor;
Stroke stroke;
static Stroke bstroke=new MyBasicStroke();
static Stroke selectStroke=new BasicStroke(1,BasicStroke.CAP_BUTT,BasicStroke.JOIN_MITER,1,new float[]{5,2},1);
S(Shape s,Color c,Color b,boolean f,boolean d,Stroke k){
this.shape=s;this.fillColor=c;this.borderColor=b;this.fc=f;this.db=d;this.stroke=k==null?bstroke:k;
}
void draw(Graphics2D g){
if(fc){
g.setColor(fillColor);
g.fill(shape);
}
if(db){
g.setColor(borderColor);
g.setStroke(stroke);
g.draw(shape);
}
if(sel){
g.setColor(Color.green);
g.setStroke(selectStroke);
g.draw(shape.getBounds());
}
}
}
class MyBasicStroke extends BasicStroke implements Serializable{}
class SA implements Serializable{
ArrayListS ss=new ArrayListS();
void add(S s){
if(s!=null){
for(S sx:ss)
sx.sel=false;
ss.add(s);
}
}
S remove(int i){
return ss.remove(i);
}
void remove(S s){
ss.remove(s);
}
void upZ(S s){
indexZ(s,1);
}
void downZ(S s){
indexZ(s,-1);
}
void indexZ(S s, int i) {
int si=ss.indexOf(s);
if(si+i0||si+iss.size()-1)return;
swap(s,ss.get(si+i));
}
void swap(S a,S b){
int ai=ss.indexOf(a);
int bi=ss.indexOf(b);
ss.set(ai,b);
ss.set(bi,a);
}
void select(S s){
for(S x:ss)
x.sel=false;
if(s!=null)
s.sel=true;
}
void drawAll(Graphics2D g){
for(S s:ss)
s.draw(g);
}
}
看來是同道。你提到的這個問題很難。
java調(diào)用python容易。 java甚至可以直接調(diào)用python的類。python調(diào)用java更容易了。
不過GUI要想融合,據(jù)目前20年的技術(shù)來看,只有本土的可以。 比如以前的微軟件ActiveX,不管你是什么語言開發(fā)的都可以在windows下用OLE方式嵌入。
java的制圖功能,因?yàn)樗脑O(shè)計(jì)理念 ,它是封閉的。也就是說,除非你使用了它本地化的GUI方法,否則就不可能實(shí)現(xiàn)。
那么說,如果我一定要實(shí)現(xiàn)怎么辦呢?只能走很長的彎路。方法還是有幾個的。
方法1:
在java的panel里嵌入一個瀏覽器,然后在瀏覽器里顯示統(tǒng)計(jì)圖表。這個真是不要太容易了。 不管是你是python生成的本地圖片,還是直接用javascript生成的圖都可以嵌入進(jìn)去。美觀不用說
方法2:
繪圖使用開源的,比如plt之類的。不過它被本地化成java版本的。然后用java調(diào)用python,再用python產(chǎn)生數(shù)據(jù)后,通過jython調(diào)用java本地化的繪圖工具。
表面上看,這個東西就是沒有價值的,為什么不直接用java調(diào)用繪圖。關(guān)鍵在于python本身對于數(shù)據(jù)處理的優(yōu)勢太明顯。輕松就可以完成復(fù)雜的數(shù)據(jù)結(jié)構(gòu)處理。所以還是有價值的
方法3:
浮動窗口方式。這個就不說了。如果你的java是固定在窗口特定位置的。這個就容易了。怎么浮動窗口要根據(jù)操作系統(tǒng)而定。
方法4:簡單方案
python生成圖片后,輸出成JPEG或者是PNG或者是GIF,然后讓JAVA顯示這個圖片。這個可能是最最簡單的。
方法5:windows專用,不知道可否使用
僅限于特定場景,在要顯示圖片的地方,顯示一個品紅色的純色圖。然后讓python的圖形輸出轉(zhuǎn)到directshow之類的API,直接寫顯卡。這樣就可以顯示動畫效果。
上代碼:
import java.awt.BorderLayout;
import java.awt.Color;
import java.awt.FlowLayout;
import java.awt.Graphics;
import java.awt.Image;
import java.awt.LayoutManager;
import java.awt.Paint;
import javax.swing.JButton;
import javax.swing.JFrame;
import javax.swing.JLabel;
import javax.swing.JPanel;
import javax.swing.JTextField;
import java.awt.event.*;
public class YuanYiDong extends JFrame{
private static int BANJIN=0;
private static int X=0;
private static int Y=0;
JTextField rTxt=new JTextField(5);
JTextField xField=new JTextField(5);
JTextField yField=new JTextField(5);
JButton paintBt=new JButton("畫");
JLabel huaban=new huaban();
JPanel jPanel=new JPanel();
JLabel banjingLabel,xLabel,yLabel;
public YuanYiDong(){
banjingLabel=new JLabel("半徑");
xLabel=new JLabel("X坐標(biāo)");
yLabel=new JLabel("Y坐標(biāo)");
this.setTitle("圓的移動");
this.setLocation(300,100);
this.setSize(500, 400);
this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
this.setVisible(true);
this.add(rTxt);
jPanel.setLayout(new FlowLayout());
add(huaban,BorderLayout.CENTER);
jPanel.add(banjingLabel);
jPanel.add(rTxt);
jPanel.add(xLabel);
jPanel.add(xField);
jPanel.add(yLabel);
jPanel.add(yField);
jPanel.add(paintBt);
add(jPanel,BorderLayout.NORTH);
paintBt.addActionListener(new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
// TODO Auto-generated method stub
BANJIN=Integer.parseInt(rTxt.getText());
X=Integer.parseInt(xField.getText());
Y=Integer.parseInt(yField.getText());
huaban.repaint();
}
});
}
private void drawCirlce(Graphics g) {
g.setColor(Color.blue);
g.fillOval(X, Y, BANJIN,BANJIN);
}
public static void main(String[] args) {
YuanYiDong frame = new YuanYiDong();
}
public class huaban extends JLabel{
public huaban(){}
public void paint(Graphics g) {
Image image = createImage(getWidth(), getHeight());
drawCirlce(image.getGraphics());
g.drawImage(image, 0, 0, null);
}
}
}
給分吧!
JAVA編程常用的軟件:
1、Eclipse:
Eclipse 是一個開放源代碼的、基于 Java 的可擴(kuò)展開發(fā)平臺。就其本身而言,它只是一個框架和一組服務(wù),用于通過插件組件構(gòu)建開發(fā)環(huán)境。幸運(yùn)的是,Eclipse 附帶了一個標(biāo)準(zhǔn)的插件集,包括 Java 開發(fā)工具(Java Development Tools,JDT)。
2、MyEclipse:
MyEclipse是Eclipse的升級版,也是一款功能強(qiáng)大的J2EE集成開發(fā)環(huán)境,由Genuitec公司發(fā)布,提供免費(fèi)版和收費(fèi)版。被譽(yù)為最好用的Java IDE之一。
MyEclipse 是對Eclipse IDE的擴(kuò)展,利用它可以在數(shù)據(jù)庫和JavaEE的開發(fā)、發(fā)布以及應(yīng)用程序服務(wù)器的整合方面極大的提高工作效率。
3、IntelliJ IDEA:
IntelliJ IDEA是一款綜合的Java 編程環(huán)境,被許多開發(fā)人員和行業(yè)專家譽(yù)為市場上最好用的IDE之一,與MyEclipse齊名。
它提供了一系列最實(shí)用的的工具組合:智能編碼輔助和自動控制,支持J2EE,Ant,JUnit和CVS集成,非平行的編碼檢查和創(chuàng)新的GUI設(shè)計(jì)器。
4、NetBeans:
NetBeans IDE是一個屢獲殊榮的集成開發(fā)環(huán)境,可以方便的在Windows、Mac、Linux和Solaris中運(yùn)行。NetBeans包括開源的開發(fā)環(huán)境和應(yīng)用平臺,NetBeans IDE可以使開發(fā)人員利用Java平臺能夠快速創(chuàng)建Web、企業(yè)、桌面以及移動的應(yīng)用程序。
5、BlueJ:
BlueJ是一款支持Java編程語言的集成開發(fā)環(huán)境(IDE)。它原本是為了教育目的而開發(fā)的,同時也適合于那些想做小型軟件開發(fā)的開發(fā)人員。它的運(yùn)行需要JDK(Java開發(fā)工具包)的幫助。BlueJ主要是為面向?qū)ο蟮某绦蛟O(shè)計(jì)教學(xué)而開發(fā)的,因此它的設(shè)計(jì)不同于其他的開發(fā)環(huán)境。
參考資料來源:百度百科-BlueJ
參考資料來源:百度百科-IntelliJ IDEA
參考資料來源:百度百科-Netbeans
參考資料來源:百度百科-eclipse
參考資料來源:百度百科-MyEclipse