Top "Class-design" questions

Refers to structural definition of class unit in object-oriented languages.

How to decide between C# static and non-static methods?

[Edit] My original-question was "Why to decide between static and non-static? Both do the same..." Unfortunately it was edited to …

c# oop class-design
How to change the access modifier of a user control

I have a user control created in xaml, lets name it "View". In the View.xaml.cs I changed the …

c# wpf xaml class-design access-modifiers
How do I resolve: "error C2039: '{ctor}' : is not a member of" in Visual Studio 2005?

I am extending a template class using C++ in Visual Studio 2005. It is giving me an error when I try …

c++ visual-studio-2005 templates class-design visual-c++-2005
Why is 16 byte the recommended size for struct in C#?

I read the Cwalina book (recommendations on development and design of .NET applications). He says that a good designed struct …

c# struct memory-management class-design
C++: Bad practice to use friend classes instead of writing getters / setters?

I have two classes which in one aspect work together tightly. They both use functionality of each other that should …

c++ oop design-patterns class-design friend
What is the nicest toString builder class you have used or seen ? What made it nice

Lets face it writing nice toString messages is a boring messy chore that needs to be done as it can …

java class-design
what is the differences between class and dataType

As i read through UML specification that: class has a set of attributes/operations and data type has a set …

class-design modeling uml class-diagram
Using Qt signals and slots vs calling a method directly

Lets say I have a main window with a slider and a widget inside that window with a method called …

c++ qt user-interface class-design signals-slots
What's wrong with Copy Constructors? Why use Cloneable interface?

When programming C++ we used to create copy constructors when needed (or so we were taught). When switching to Java …

oop class-design
What are the pros/cons of choosing between static and instance data access classes in a web app?

I've read several other questions on this topic (here, here, and here), but have yet to see a great answer. …

c# asp.net class-design data-access-layer