[#BloombergLP-bdlb-TypeTraitHasPrintMethod]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdlb.adoc[bdlb]::TypeTraitHasPrintMethod
:relfileprefix: ../../
:mrdocs:

Old&hyphen;style trait tag indicating that a class provides a BDE&hyphen;style `print` method&period;

== Synopsis

Declared in `&lt;bdlb&lowbar;printmethods&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
struct TypeTraitHasPrintMethod;
----

== Description

A class should declare this trait if it has a `print` method with the following signature&colon; &grave; bsl&colon;&colon;ostream&amp; print(bsl&colon;&colon;ostream&amp; stream, int level &equals; 0, int spacesPerLevel &equals; 4) const&semi; &grave;

== Types

[cols="1,4"]
|===
| Name| Description
| xref:BloombergLP/bdlb/TypeTraitHasPrintMethod/Metafunction.adoc[`Metafunction`] 
| Metafunction that evaluates to `HasPrintMethod&lt;TYPE&gt;&colon;&colon;type`&period;
| xref:BloombergLP/bdlb/TypeTraitHasPrintMethod/NestedTraitDeclaration.adoc[`NestedTraitDeclaration`] 
| This class template ties the `bdlb&colon;&colon;TypeTraitHasPrintMethod` trait tag to the `bdlb&colon;&colon;HasPrintMethod` trait metafunction&period;
|===



[.small]#Created with https://www.mrdocs.com[MrDocs]#
