0
A
回答
2
方括號表示法只是訪問對象屬性或方法的另一種方法,通常通過某種變量來訪問,而不是通過符號或關鍵字訪問屬性的點符號。
說aa.nodeValue
等於字符串「harCode」。這將這樣的工作
var s = String["fromCharCode"];
即相當於
var s = String.fromCharCode;
所以s
現在是一個指針上String
靜態fromCharCode
方法。
同樣,如果aa.nodeValue
等於「odePoint」,你會被引用String.fromCodePoint
1
它只是String.fromCharCode(),寫在模糊化的方式,也可以是這樣的:
aa = document.createTextNode("harCode");
s = String["fromC" + aa.nodeValue];
這將終於變成String["fromCharCode"]
這相當於String.fromCharCode
相關問題
- 1. 數組操作的想法
- 2. .string僞操作的替代方法?
- 3. 數組的操作
- 4. PHP數組操作
- 5. 操作數'=='不能應用於bool和string類型的操作數
- 6. 無法在數組類型String上調用replace(String,String)[]
- 7. 數組操作
- 8. 數組操作
- 9. 數組操作
- 10. 數組操作?
- 11. startsWith(String)方法和數組
- 12. 操作> =不能應用於類型的方法組的操作數和int
- 13. 無法用STRING鍵創建數組
- 14. 鮮明操作<string>
- 15. 如何從jsp檢索String []的數組以便使用Struts2執行操作?
- 16. PHP數組操作
- 17. Julia:數組操作
- 18. Matlab數組操作
- 19. 慢數組操作
- 20. 數組操作(PHP)
- 21. Perl數組操作
- 22. php數組操作
- 23. PHP數組操作
- 24. 數組操作 - PHP
- 25. 慢數組操作
- 26. JavaScript數組操作
- 27. PHP數組操作
- 28. R數組操作
- 29. PHP數組操作
- 30. Matlab數組操作
你從哪裏看到的?我需要一個鏈接,否則我無法相信。 – Bergi