Topincs Reference
IndexComponents showcase
0Sign in
PHP instance method A-Z Ongoing

Tobject->equals

Description

Test if a tobject is equal to another.

Comments

Domain classes use temporary created objects in method calls which makes the comparison of a tobject to "this" in a domain class method by the strict equality operator impossible. The introduction of the %equals% method solves this problem and gives the developer a reliable way to test if two tobjects represent the same topic.

Examples

[%$kurt = Tobject::get("si:kurt"); $mary = Tobject::get("si:mary"); // Another tobject if ($kurt->equals($mary)) ... // A topic reference if ($kurt->equals("si:mary")) ... // A system id if ($kurt->equals(779)) ...%]

Class

Tobject(PHP class)

Arguments

Coding name other
Position 1
Type
  • Tobject(PHP class)
  • Topic reference(Custom type)
  • Integer(Primitive type)
Description The tobject to test for equality.

Returns

Boolean(Primitive type)

Introduced in

Topincs 8.2.1

We are sorry

This page cannot be displayed in your browser. Use Firefox, Opera, Safari, or Chrome instead.

Saving …

   

Before we continue …

No internet connection

Refreshed lab_unknown

Edit