:relfileprefix: ../../../
[#8BFBF955FAB8E0E9E52DBB8A810D8ABE05A066AA]

= Function url_view_base::has_userinfo

pass:v,q[Return true if a userinfo is present]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L597[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
has_userinfo() const noexcept;
----

== Description

pass:v,q[This function returns true if this] pass:v,q[contains a userinfo.]

=== Example
[,cpp]
----
assert( url_view( "http://jane%2Ddoe:pass@example.com" ).has_userinfo() );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
userinfo    = user [ ":" [ password ] ]

authority   = [ userinfo "@" ] host [ ":" port ]
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[3.2.1. User Information (rfc3986)]



== Return Value

* `bool` 




