日期:2014-05-16 浏览次数:20392 次
<html>
<head>
<script type="text/javascript">
function myClass()
{
//假设以下隐藏
this.name;
this.play = function()
{
//..
}
//假设以上隐藏
}
</script>
</head>
<body>
</body>
</html>
<html>
<head>
<script type="text/javascript">
function myClass()
{
//假设以下隐藏
this.name;
this.play = function()
{
//..
}
//假设以上隐藏
}
myobj = new myClass()
for(key in myobj){
document.write(key+":"+myobj[key].toString()+" <br>");
}
</script>
</head>
<body>
</body>
</html>
------解决方案--------------------
function classA()
{
this._name="hello";
}
window.alert(classA.toString());
------解决方案--------------------
js的类为什么会看不到阿?不是都可以下载的吗?
------解决方案--------------------
关注
------解决方案--------------------
"被集成到硬件里面去了"
????,怎么集成的?
------解决方案--------------------
有些会显示成native code
------解决方案--------------------
你是想看myClass这个函数的写法吗??
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title> New Document </title>
<script type="text/javascript">
<!--
function myClass(a){
this.a=a;
alert("OK");
}
alert(myClass.toString());
//-->
</script>
</head>
<body>
</body>
</html>
------解决方案--------------------
------解决方案--------------------
我也想了解,谢谢LZ.
------解决方案--------------------
var o=new myClass()
for(i in o)
{
alert("o["+i+"]="+o[i]);
}