php - Enabling a '.equals' equivalent for PHP5 Classes -


I have two examples of PHP5 class (called class), and I want to see if they are equal or No . In C #, I can write a .equals (ClassA other) method for ClassA, which will overload on the == operator.

Is PHP5 a method overload in class and can be used for comparison ==, or did I compel something like $ example A-> equal ($ instanceB) going?

Ah, sorry to miss the point of question about overloading. It does not seem that it is possible as mentioned above. However, I found a useful example to implement my own.

This link is showing me some example codes:


Comments

Popular posts from this blog

c# - sqlDecimal to decimal clr stored procedure Unable to cast object of type 'System.Data.SqlTypes.SqlDecimal' to type 'System.IConvertible' -

Calling GetGUIThreadInfo from Outlook VBA -

Obfuscating Python code? -