are a forward declaration. They are telling the code that there is a class called Webframe in the blink namespace.
The line CefFrameImpl(CefBrowserImpl* browser, blink::WebFrame* frame); says that we need a pointer to one of these Webframe objects. The compiler knows how big a pointer is, so it can allocate the memory for it. It knows that there is something called a Webframe, but since the pointer is never dereferenced in this code, it doesn't need to know what a Webframe is or what it does.
Code that dereferences the pointer needs to have the header file that defines the Webframe class. But code that only sees pointers and references can get away with a forward declaration.
I think there may be even a little bit more latitude than that in the arguments of function declarations, but this is the underlying reason.
If the pointer were dereferenced and the user wanted to access data from the WebFrame class, would that mean that an include file would be needed? (included WebFrame.h on line 88)
Such as in the following implementation file.
The namespace could have been named anything but in this case the developer chose to use blink. it could have been
No. The actual definition of the class would be still be in the blink namespace and you would run into linking issues.
If the pointer were dereferenced and the user wanted to access data from the WebFrame class, would that mean that an include file would be needed? (included WebFrame.h on line 88)
Yes. The definition is required anywhere such a pointer would be dereferenced.
that was very insightful answer. Where are namespaces defined in a program?
I assume it is similiar to a standard library namespace definition. I googled where standard library namespace was defined and it was said that it was so through several files. But there is a base standard library name and everyone is aware of it.
There must be something similar for the blink namespace. I will find it, just want clarification if my thinking is correct as far as how a namespace is defined.