Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

What is the use of static functions?

Answer Posted / reejusri

Static function is basically used in creating factory
objects.
You can make your constructor private and expose static
function. And user can use the static methods to create the
object of that class.
Using NONSHARABLE_CLASS you can restrict the usage of
static functions/method also.

Is This Answer Correct ?    15 Yes 16 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

In c++, what is the difference between method overloading and method overriding?

1147


What are the implicit member functions of class?

1090


What is difference between n and endl in c++?

1096


What are the various arithmetic operators in c++?

1130


What is the best book for c++ beginners?

1047


daily Routine of father

1412


What is a class template in c++?

1054


Can you be able to identify between straight- through and cross- over cable wiring? And in what case do you use straight- through and cross-over?

1110


What are the differences between java and c++?

1082


Explain about templates of C++.

1156


Write a code/algo to find the frequency of each element in an array?

1122


What is stack unwinding?

1145


What is the identity function in c++? How is it useful?

1054


What are c++ storage classes?

1103


Differentiate between realloc() and free().

1056