By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
449,140 Members | 1,298 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 449,140 IT Pros & Developers. It's quick & easy.

function Declaration&Definition

P: 1
function Declaration&Definition

" Geroty (const vector<Point3D>& poly, const Plane& Tr)"

As i'm c++ beginner the following Function Declaration and Definition couldnt understandable? so explain me what kind of Declaration this is."const vector<Point3D>& poly....." ? and where do I find study materials for the kind of function declaration"

Also pleas explain *this without more complex technical terms.
Jun 24 '07 #1
Share this Question
Share on Google+
1 Reply

Expert Mod 5K+
P: 9,197
const vector<Point3D>&

is a reference to a vector containing Point3D objects. The const means the container is constant. That is, you can access the objects inisde but you can't change them.

vector is a C++ Standard Library container.

Find out about vector and references in any C++ textbook.

*this is the object pointed at by the this pointer. this pointers are used in member functions to access the object being used by the member function. Again, you will need to read up on classes and member functions in a C++ textbook.

I recommend the "C++ Primer Plus" 5th Ed. by Stephen Prata. This one is non-technical and assumes you know nothing. I would make a serious attempt to read this book.

There are also C++ classes offered where this material is covered. Check your local colleges.
Jun 24 '07 #2

Post your reply

Sign in to post your reply or Sign up for a free account.