| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 623 人关注过本帖
标题:基础的东东。帮一下忙。谢谢
只看楼主 加入收藏
yushengou
Rank: 1
等 级:新手上路
帖 子:401
专家分:0
注 册:2005-3-30
收藏
 问题点数:0 回复次数:5 
基础的东东。帮一下忙。谢谢
public Payment(Tenders tender)//这是什么意思??
{
this.Tender=tender;//这是什么意思??
}
***********************************************
public Color()   //这是什么意思???
{
this.red=0;    //为什么要用this??
this.green=137;
this.blue=255;
}
protected int red;
...
就先这么多吧。明天来发钱^_^
多多发言哦
搜索更多相关主题的帖子: 东东 基础 
2005-04-13 17:31
冰封谷主
Rank: 4
等 级:贵宾
威 望:10
帖 子:226
专家分:20
注 册:2005-1-7
收藏
得分:0 
你写的代码不全吧,第一行是在传递参数,为了保护数据的安全,this是为了方便书写,public color()是一个构造函数,应该上面还有一个class color {}

2005-04-14 07:51
幻风幻云
Rank: 1
等 级:新手上路
帖 子:762
专家分:0
注 册:2005-1-14
收藏
得分:0 
this在类的方法中出现作为一个值类型,表示对该方法对象的引用

2005-04-14 08:54
yushengou
Rank: 1
等 级:新手上路
帖 子:401
专家分:0
注 册:2005-3-30
收藏
得分:0 
谢谢

我是初学者,希望大家能多多帮助我 /bbs/showimg.asp?BoardID=34&filename=2005-4/200542294030151.gif" border="0" onload="if(this.width>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt='Click here to open new window\nCTRL+Mouse wheel to zoom in/out';}" onmouseover="if(this.width>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.style.cursor='hand'; this.alt='Click here to open new window\nCTRL+Mouse wheel to zoom in/out';}" onclick="if(!this.resized) {return true;} else {window.open('http://bbs./bbs/showimg.asp?BoardID=34&filename=2005-4/200542294030151.gif');}" onmousewheel="return imgzoom(this);" alt="" />
2005-04-14 09:35
frwang
Rank: 1
等 级:新手上路
帖 子:43
专家分:0
注 册:2006-12-3
收藏
得分:0 
this是当前窗体,引用它是为了书写代码方便,提高编写代码的速度!

2006-12-04 20:05
舞雪
Rank: 1
等 级:新手上路
威 望:1
帖 子:1786
专家分:0
注 册:2006-10-11
收藏
得分:0 

这个this和C++里面的this指针基本一样


呵呵,不愧是BC论坛
2006-12-04 22:41
快速回复:基础的东东。帮一下忙。谢谢
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.012189 second(s), 7 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved