JavaÖл´øÓмýÍ·µÄÏß¶Î
×î½üÓÉÓÚÒª»»î¶¯Í¼£¬ËùÒÔÐèÒª»´øÓмýÍ·µÄÏ߶Σ¬ÓÚÊǽáºÏÓйØ×ÊÁÏ£¬Ð´³öÁËÕâ¸ö·½·¨¡£
import java.awt.*;
import javax.swing.*;
import java.awt.geom.*;
public class test//¶ÁÕß¿ÉÒÔ¸ü¸ÄÀàtestµÄÃû×Ö£¬ÒÔÊʺÏ×Ô¼º¶¨ÒåµÄ.javaÎļþ£¬ÒòΪËüÖ»ÊÇÓÃÀ´²âÊԵġ£
{
public static void main (String args[]){
DrawFrame frame=new DrawFrame();
frame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
frame.setVisible(true);
}
}
class DrawFrame extends JFrame
{
public DrawFrame()
{
setTitle("Activity Diagram");
setSize(DEFAULT_WIDTH,DEFAULT_HEIGHT);
// add panel to frame
ArrowLinePanel panel=new ArrowLinePanel();
add(panel);
}
// »î¶¯Í¼´°¿Ú´óС
public static final int DEFAULT_WIDTH=1000;
public static final int DEFAULT_HEIGHT=800;
}
class ArrowLinePanel extends JPanel
{
// confirm the line position
public ArrowLinePanel()
{
setBackground(Color.white);
}
public void paintComponent(Graphics g)
{
super.paintComponent(g);
Graphics2D g2=(Graphics2D) g;
g2.setPaint(Color.black);
drawAL(x1, y1, x2, y2, g2)£»//ÕâÀïx1, y1, x2, y2±ØÐëÒªÉùÃ÷²¢ÇÒ³õʼ»¯£¬¶ø¾ßÌåÉùÃ÷µÄλÖúͳõʼ»¯µÄÖµ
//ÓɱàÕß×Ô¼º¾ö¶¨£¬ÔÚÕâÀ±ÊÕßûÓÐÉùÃ÷ËüÃÇ¡£
}
public static void drawAL(int sx, int sy, int ex, int ey,Graphics2D g2)
{
double H = 6 ; // ¼ýÍ·¸ß¶È
double L = 6 ; // µ×±ßµÄÒ»°ë
int x3 = 0 ;
int y3 = 0 ;
int x4 = 0
Ïà¹ØÎĵµ£º
·½·¨¾ÍÊÇÒ»¶Î¿ÉÖØ¸´µ÷ÓõĴúÂë¶Ë
·½·¨µÄ¶¨ÒåÔÚJavaÖÐÓжàÖÖÐÎʽ£¬
ÏÖÔÚµÄÎÒËù˵µÄ·½·¨¾ÍÊÇÖ¸¿ÉÒÔÓÃmain·½·¨Ö±½ÓÈ¥µ÷Óõķ½·¨¡£
public class JavaDemo06
{
public static void main(String args[])
{
printTab() ;
}
// ¶¨ÒåÒ»¸ö·½·¨£¬´Ë·½·¨ÓÃÓÚ´òÓ¡Hello World
// public static±ØÐë¼ÓÉÏ£¬ÒòΪÊÇÓ ......
1 ×Ö·û´®±È½ÏÊÇ·ñÏàµÈÓÃʲô·½·¨£¿
2 equals£¨£©ºÍhashCode£¨£©µÄÇø±ð£¿
3 forwardºÍsenRedirectÇø±ð£¿
4 servletÉúÃüÖÜÆÚ£¿
5 ¹ýÂËÆ÷µÄ×÷ÓÃ
6 JSP°üº¬¾²Ì¬ÎļþµÄÓï·¨
7 JSP×¢ÊÍ£¨ÖÁÉÙÁ½¸öÒÔÉÏ£©
8 tableÖÐborder£¬cellpadding,tdÖÐcolspan,rowspanµÄÒâÒå
9 jsÈýÖÖµ¯³ö´°¿Ú a ¾¯¸æ b È·ÈÏ c ÐÅÏ¢ ......
±±¾© ÁõÓñÇ¿ Èí¼þ¹¤³Ìʦ ¼òÀú java php
ÇóÖ°¼òÀú
· »ù±¾ÐÅÏ¢
ÐÕ Ãû:
ÁõÓñÇ¿
³öÉúÈÕÆÚ:
1988Äê10ÔÂ23ÈÕ
ÐÔ ±ð:
ÄÐ
Ãñ ×å:
ºº×å
ר Òµ£º
Èí¼þ¼¼Êõ
½¡¿µ×´¿ö:
½¡¿µ
E - Mail:
mengxiangbaidu@qq.com
ÁªÏµµç»° ......
Chapter I.
JavaµÄÓÅȱµã¸÷ÖÖÊéÉ϶¼ÓУ¬ÕâÀïֻ˵˵ÓÃJava×öACM-ICPCµÄÌØµã£º
(1) ×îÃ÷ÏԵĺô¦ÊÇ£¬Ñ§»áJava£¬¿ÉÒԲμÓJava Challenge
(2) ¶ÔÓÚÊìϤC/C++µÄ³ÌÐòÔ±À´Ëµ£¬Java ²¢²»ÄÑѧ£¬ÕÒ±¾Ê飬һÁ½ÖÜÒµÓàʱ¼ä¾Í¿ÉÒԸ㶨ÁË¡£µ±È»£¬ÕâÀïÖ»ÊÇÖ¸Ò»°ã±à³Ì£¬ÏëÊìϤËùÓеÄJava¿â»¹ÊÇÐèҪЩʱ¼äµÄ¡£ÊÂʵÉÏ£¬Java Ö ......
////////////////////////////////////////////////½ÚµãÀà TreeNode.java //////////////////////////
package com.tree;
class TreeNode {//°ü·ÃÎÊȨÏÞ
long data ;
long x,y;
String adrr;
Tre ......