That was the first time I was introduced to the concept of operator overloading.
这是我第一次被介绍给了操作符重载的概念。
As you've seen, operator AD hoc polymorphism, or operator overloading to the rest of us, can be quite powerful if carefully employed and documented.
可以看到,操作符的即时多态,或操作符重载,对于我们来说,如果小心使用和记录,会非常强大。
I remember asking this Gosling in one of my interviews of him why he left out operator overloading (I don't think that question and answer ended up getting published).
我记得在采访Gosling时曾问过他为何放弃操作符重载(我想该问题和答案还尚未公开过)。
In this installment of Practically Groovy, I introduce you to Groovy's support for operator ad-hoc polymorphism, also known as operator overloading.
在实战groovy的这一期中,我将介绍Groovy对操作符即时多态(也称为操作符重载)的支持。
If your programming language supports operator overloading, you should also provide an implementation of the equality and inequality operators.
如果编程语言支持运算符重载,则还应提供等号和不等号运算符的实现。
The reason I say that is, by having operator overloading I can use 1 generic interface to all of the objects that I want to use.
他在大多数情况下都是对的,我要这么说的原因是,通过运算符重载我可以,用一个通用的借口对。
The reason I say that is, by having operator overloading I can use 1 generic interface to all of the objects that I want to use.
他在大多数情况下都是对的,我要这么说的原因是,通过运算符重载我可以,用一个通用的借口对。
应用推荐