>  Docs Center  >  IDL Reference  >  Object-Oriented Programming  >  IDL_Object::_overloadPrint

IDL_Object::_overloadPrint

IDL_Object::_overloadPrint

The IDL_Object::_overloadPrint function method can return a variable of any type to be printed out, although in this default method the self object reference is returned to the PRINT/PRINTF procedures.

This method is designed to replicate the default behavior of objects that do not use operator overloading. As a result, object classes that do inherit from the IDL_Object class but that do not override this particular method will behave in the same manner as object classes that do not inherit from the IDL_Object class.

Tip: If you write an object class that inherits from IDL_Object and overloads this method, you can call the superclass method directly to achieve the default behavior for specific cases.

Syntax


In most cases, this method is called indirectly by the PRINT/PRINTF procedure. When called explicitly, the syntax is:

Result = Obj->[IDL_Object::]_overloadPrint()

Return Value


This method is called by the PRINT/PRINTF procedure when it is called with an object that inherits from the IDL_Object class, but that does not implement its own _overloadPrint function method. The return value replicates the behavior of calling the PRINT/PRINTF procedure with an object that does not inherit from the IDL_Object class.

Arguments


None

Keywords


None

Routine Signature


To overload this function method for an object class, implement a method with the following signature:

FUNCTION class::_overloadPrint

The return value of this function can be a variable of any type, which will be printed out instead of the default self object reference.

Version History


8.0

Introduced

See Also


IDL_Object::_overloadImpliedPrint, IDL_Object::_overloadHelp, Overloading the Help and Print Procedures

 



© 2019 Harris Geospatial Solutions, Inc. |  Legal
My Account    |    Store    |    Contact Us