definition

Controllers in the context of Composite WPF

What is a Controller in the context of Composite WPF? ...

can size of array be determined at run time in c?

As I know, an array needs to have a specific size before compiling time in c. I wonder why this code still works? int s; printf("enter the array size: "); scanf("%d",&s); int a[s]; // Isn't s value determined at run time? ...

Referencing classes in Python

Hi all I'm having a spot of bother with Python (using for app engine). I'm fairly new to it (more used to Java), but I had been enjoying....until now. The following won't work! class SomeClass(db.Model): item = db.ReferenceProperty(AnotherClass) class AnotherClass(db.Model): otherItem = db.ReferenceProperty(SomeClass) As far as...

Best practice: ordering of public/protected/private within the class definition?

I am starting a new project from the ground up and want it to be clean / have good coding standards. In what order do the seasoned developers on here like to lay things out within a class? A : 1) public methods 2) private methods 3) public vars 4) private vars B : 1) public vars 2) private vars 3) public methods 4) private methods C :...

What exactly does "closure" refer to in JavaScript?

I understand what closures are, but I am having some trouble grokking exactly what the term closure refers to. I have seen the term used in many websites, but rarely do they agree on the actual definition of it. Is it the variables that are kept on the stack frame? Is it the function that is being returned? Is it the scope of the oute...

Sharepoint upgrade: Map custom site definition to out of the box definition

I'm currently working on upgrading a Sharepoint 2003 installation to a Sharepoint 2007 installation. I am using a custom site definition in 2003 and would like to map that to the out of the box "Team Site" definition in 2007. Assume my custom site definition is called CustomSiteDef. I have created an upgrade definition file called Cus...

name collision in C++

Hi all, While writing some code i came across this issue: #include <iostream> class random { public: random(){ std::cout << "yay!! i am called \n" ;} }; random r1 ; int main() { std::cout << "entry!!\n" ; static random r2; std::cout << "done!!\n" ; return 0 ; } When i try to compile this code i get the error error: ârandomâ d...

How to declare a static variable but not define it

Some times we need to pre-declare a static variable and then use it. But the variable name of this declaration may be wrong, and the compiler can not detect it, oops! Example: /* lots of codes */ static some_type some_name; /* pre-declaration */ /* but it may define "some_name" */ /* use some_name */ /* lot...

In LaTeX, how does one get a colon instead of a full stop after a theorem?

I want to know if there is some way to change that full stop after Definition. to a colon, i.e. to get Definition: (and for the other environments in the "definition" theoremstyle). ...

Declare default parameter circular reference without pointers?

Is there any way to declare these classes in a header file without indirection? // Forwards declaration of B class B; class A { public: // Default parameter referring to B. May return its parameter const B& func(const B& b = B()); }; class B { public: // B ctors B() {} B(const B&) {} // B has A as a member ...

Multiple definitions of `GamepadControll::GamepadControll()'

I got this error message: multiple definition of `GamepadControll::GamepadControll()' After being frustrated for hours I reduced the code to: GamepadControll.h: #ifndef GAMEPADCONTROLL_H_ #define GAMEPADCONTROLL_H_ #include <iostream> class GamepadControll { public: GamepadControll(); virtual ~GamepadControll(); }; #en...

What is a "CDR"?

I'm reading on Vertica's web site (database vendor) that many of their customer use their database for "CDR" purposes. Question: What is a "CDR"? http://www.vertica.com/customers/success ...

What is a callback?

Is it a function? Is it a function being called from the source? Or, is it a function being returned from the destination? Or, is it just executing a function at the destination? Or, is it a value returned from a function passed to the destination? ...

What is a "Java Bean"?

The name really throws me off. I'm hoping someone can explain it in a way I won't forget :) ...

How to define threadsafe?

Threadsafe is a term that is thrown around documentation, however there is seldom an explanation of what it means, especially in a language that is understandable to someone learning threading for the first time. So how do you explain Threadsafe code to someone new to threading? My ideas for options are the moment are: Do you use a l...

Separate policy from mechanism: What does it mean?

I've often heard the mantra of "separating policy from mechanism", especially in the context of the Unix philosopy. What does this mean and what are some concrete examples of it? When/why is/isn't it a good thing? ...

What does threadsafe mean?

Recently I tried to Access a textbox from a thread (other than the UI thread) and an exception was thrown, it said something about the "code not being thread safe" and so I ended up writing a delegate (sample from MSDN helped) and calling it instead. But even so I did'nt quite understand why all the extra code is necessary Update: Will...

Definition of Multimedia Authoring Services

Hi. I d like to know what exactly is behind term "Multimedia Authoring Services". Any related examples about it? Does this service exists nowadays? Does creating a dvd or media player related software belong to such services? Thank you in advance! ...

Neural Network Definitions

I am writing a neural network class and have come across two concepts I don't understand. Would anyone be able to tell me what the bias and momentum is and does ...

What does it mean for a browser to be "webkit-based" or "gecko-based"?

I hear these terms bandied around quite a bit, especially when discussing feature compatibility... but what do they mean? ...