·¢ÏÖÒ»¸öc++¶à̬Óëjava¶à̬²»Í¬µÄµØ·½
¸Õ¸Õ¿´µ½Ò»ÆªÎÄÕÂÌá³öc++¶à̬Óëjava¶à̬²»Í¬µÄµØ·½£¬»ù±¾Òâ˼ÈçÏ£º
Çë¿´C++´úÂ룺
class Base
{
public:
Base()
{
init();
}
virtual ~Base() {}
protected:
int value;
virtual void init()
{
value = 100;
}
};
class Derived : public Base
{
public:
Derived()
{
init();
}
protected:
void init()
{
cout << "value = " << value << endl;
// ×öһЩ¶îÍâµÄ³õʼ»¯¹¤×÷
}
};
int main(int argc, char* argv[])
{
Base* pb;
pb = new Derived();
delete pb;
return 0;
}
Ö´Ðнá¹ûÊÇ
value = 100
ÔÙ¿´java´úÂ룺
class Base
{
public Base()
{
init();
}
protected int value;
protected void init()
{
value = 100;
}
}
class Derived extends Base
{
public Derived()
{
init();
}
protected void init()
{
System.out.println("value = " + value);
// ×öһЩ¶îÍâµÄ³õʼ»¯¹¤×÷
}
}
public class Test
{
public static void main(String[] args)
{
Base base = new Derived();
}
}
Ö´Ðнá¹ûÊÇ
value = 0
value = 0
ÔÚjavaÖÐ×ÓÀàµÄinit·½·¨ÖØдÁ˸¸ÀàµÄinit·½·¨£¬µ¼Ö²»ÄÜÕýÈ·Íê³É³õʼ»¯¡£¿´µ½ÕâÀïÎÒ˼¿¼ÁËһϣ¬ÓÉÓÚ×ÓÀàÖØдÁ˸¸ÀàµÄͬÃûº¯Êý£¬²Åµ¼Ö±¾Ó¦¸ÃÖ´Ðеĺ¯ÊýûÓÐÖ´ÐУ¬Èç¹ûÐ޸ĸ¸ÀàµÄ³õʼ»¯º¯Êý»òÕß×ÓÀàµÄ³õʼ»¯º¯Êý£¬Ê¹×ÓÀ಻»á·¢ÉúÖØд£¬ÊDz»ÊǾͲ»»á·¢ÉúÉÏÃæµÄÇé¿ö£¿»òÐí¼´Ê¹ÊÇ×ÓÀàÓ븸À࣬µ±Éæ¼°µ½¸÷×Եijõʼ»¯µÄµØ·½Ê±¾Í²»Ó¦¸ÃʹÓöà̬ÐÔ¡£
Ïà¹ØÎĵµ£º
×î½ü¹«Ë¾Åöµ½ÐèÒªÓÃͼ±íµÄÐÎʽÏÔʾһЩÊý¾Ý£¬ÎҾͿªÊ¼µ½ÍøÉϲéѯ£¬²éµ½ÁËjfreechartºÍamcharts,ÕâÁ½ÕßÎÒ¶¼ÊµÏÖ¹ýÁË£¬jfreechart×îºóÉú³ÉͼƬ£¬µ«ÊÇͼƬЧ¹û²»ÊÇÎÒÏëÒªµÄ£¬È»ºóÓÖÑо¿amcharts ËüµÄЧ¹ûȷʵºÜºÃ£¬¶øÇÒ¹Ù·½ÍøÕ¾ÉÏ»¹ÓкÃЩÀý×ӿɹ©ÏÂÔØ£¬ÍøÖ·ÊÇ:www.amcharts.com
£¨ÏëÒªÍê³ÉÒ»¸öamchartsͼÐÎÐèÒªswfobjects. ......
ÍøÉÏÒ»µÀ½ðɽµÄÃæÊÔÌ⣺
http://topic.csdn.net/u/20100524/14/0eff992a-2849-4db6-bdaa-d4a200e79b7c.html
Çë·Ö±ðÓÃC++µÄÃæÏò¶ÔÏóºÍ·ºÐÍ»úÖÆ£¬±àдʵÏÖTemplate MethodģʽµÄʾÀý´úÂ룬²¢±È½ÏÁ½ÖÖ·½Ê½¸÷×ÔµÄÓÅȱµã¡£
ÓÃÐ麯ÊýʵÏÖTemplate MethodµÄ·½Ê½¾Í²»¶à˵ÁË¡£Ó÷ºÐ͵ķ½Ê½ÊµÏÖ¶à̬ÔÚATLÀïÃæÓдóÁ¿µÄÓõ½£¡
·ºÐ͵ ......
JavaÖеÄstartsWithºÍendsWith·½·¨£¬ÔÚfilterµÄ¹¦ÄÜʵÏÖÖкܷ½±ã£¬PHP¿ÉÒÔÓÃstrncmp()
ʵÏÖstartsWith£¬µ«ÊÇÎÞ·¨ÊµÏÖendsWith£¬ÓÐЩÈË»áÓÃÕýÔòÀ´ÊµÏÖ£¬µ«´ó¶àÊýÈ˶¼²»Ï²»¶ÕýÔò±í´ïʽµÄ²Ù×÷¡£
ÕâÀïÎÒͨ¹ýÒ»¸ö½Ðsubstr_compareµÄ·½·¨ÊµÏÖ(ͬʱËûÒ²ÄÜʵÏÖsta ......
import java.awt.Robot;
import java.io.IOException;
import java.lang.reflect.Field;
public class TestServer {
Class<?> key;
Robot ro;
{//·Ç¾²Ì¬¿éÓÃÓÚ³õʼ»¯ÀàÀàµÄ·Ç¾²Ì¬³ÉÔ±
try {
key = Class.forName("java.awt.event.KeyEvent");
ro = new Robot();
}
catch (Excep ......
Óкܳ¤Ò»¶Îʱ¼äûÓÐд²©¿ÍÁË¡£×î½üÒ»Ä꣬ÊÕµ½²»ÉÙ½»Á÷Óʼþ¶¼ÊǹØÓÚwebservice£¬´ó²¿·Ö¶¼ÊÇËØÒªwebserviceʵÀý¡£
Æäʵ¶Ôwebservice Á˽ⲻÊǺÜÉֻÊǸù¾Ý¹¤×÷ÐèҪȥ½Ó´¥£¬È¥Ñ§Ï°¡£×î½üÏîÄ¿ºÍÆäËûÒ»¸ö.netÏîÄ¿ÐèÒª×öÊý¾Ý½»»¥£¬½»»¥·½Ê½¾Í²ÉÓÃWebservice.
Ìؽ«¿ª·¢ÖÐÓöµ½µÄÎÊÌâ×ܽᲢ·ÖÏí£»
¿ª·¢ÖÐÓöµ½µÄÎÊÌâÓУº
1£©jav ......