| c++ Programming Glossary: managesWhy is it not possible to overload class templates? http://stackoverflow.com/questions/11968994/why-is-it-not-possible-to-overload-class-templates  struct Foo template unsigned int N struct Foo The compiler manages to handle overloaded functions and function templates wouldn't.. 
 What is Linux?™s native GUI API? http://stackoverflow.com/questions/12717138/what-is-linuxs-native-gui-api  independent part and a device dependent part. The former manages screen resources such as windows while the latter communicates.. 
 Difference between string and char[] types in C++ http://stackoverflow.com/questions/1287306/difference-between-string-and-char-types-in-c  is a class that contains a char array but automatically manages it for you. Most string implementations have a built in array.. 
 1D or 2D array, what's faster? http://stackoverflow.com/questions/17259877/1d-or-2d-array-whats-faster  The C way of doing it is probably to write a class that manages your memory while considering important things like What is.. 
 When is overloading pass by reference (l-value and r-value) preferred to pass-by-value? http://stackoverflow.com/questions/18303287/when-is-overloading-pass-by-reference-l-value-and-r-value-preferred-to-pass-by  operator. For example look at std vector This class manages a dynamically sized buffer and maintains both a capacity maximum.. 
 Why was std::strstream deprecated? http://stackoverflow.com/questions/2820221/why-was-stdstrstream-deprecated  it wrong. The stringstreams return a string object which manages itself which is far less error prone. There was also the issue.. 
 What is the copy-and-swap idiom? http://stackoverflow.com/questions/3279543/what-is-the-copy-and-swap-idiom  this question   Overview Why do we need it Any class that manages a resource a wrapper like a smart pointer needs to implement.. private std size_t mSize int mArray This class almost manages the array successfully but it needs operator to work correctly... mArray 3 return this And we say we're finished this now manages an array without leaks. However it suffers from three problems.. 
 Convert std::string to const char* or char* http://stackoverflow.com/questions/347949/convert-stdstring-to-const-char-or-char  any external library . You use std vector which completely manages the memory for you. std string str std vector char writable.. 
 Const method that modifies *this without const_cast http://stackoverflow.com/questions/3484233/const-method-that-modifies-this-without-const-cast  program I'm writing. I hope it's not too contrived but it manages to mutate a Foo object in the const method Foo Questionable.. to FooOwner and vice versa and in Questionable Foo manages to modify itself in a const method by calling mutate_foo on.. 
 What is The Rule of Three? http://stackoverflow.com/questions/4172722/what-is-the-rule-of-three  those special member functions explicitly When our class manages a resource that is when an object of the class is responsible.. rule of three Sometimes you need to implement a class that manages a resource. Never manage multiple resources in a single class.. 
 Why doesn't C++ support functions returning arrays? http://stackoverflow.com/questions/5157439/why-doesnt-c-support-functions-returning-arrays  it in to the version with pointers for you. It also manages your memory for you. And automatic memory management while helpful.. 
 Can a local variable's memory be accessed outside its scope? http://stackoverflow.com/questions/6441218/can-a-local-variables-memory-be-accessed-outside-its-scope  Compilers are in the business of generating code which manages the storage of the data manipulated by that program. There are.. 
 Speeding up file I/O: mmap() vs. read() http://stackoverflow.com/questions/8056984/speeding-up-file-i-o-mmap-vs-read  work well but only for the moderate cases the read method manages our overall file cache much better and can deal well with 100s.. 
 Programatically disable/enable network interface http://stackoverflow.com/questions/860673/programatically-disable-enable-network-interface  pop up. Hopefully this helps anyone else and if anyone manages to find another way that works in more situations I'd love to.. 
 |