Questions tagged [dynamic-binding]

Dynamic binding (aka dynamic dispatch) is the process of mapping a message to a specific piece of code (method) at runtime.

257 questions
1
vote
1 answer

Why two methods with the same name (belonging to different class) should have same prototype while using dynamic typing and dynamic binding?

Hi I'm a newbie to objective-C ,today I was learning the concept of dynamic typing and binding, all was well until I wrote and executed this program #import @interface A:NSObject @property int…
iamyogish
  • 2,372
  • 2
  • 23
  • 40
1
vote
1 answer

How can I bind a list of radioes with dynamic binding?

I wanna bind a list of controls in my controller. I don't have any problem with text box, check box or drop down. For instance, @Html.TextBox("tblContactPhones[0].description") @Html.DropDownList("tblContactPhones[0].phoneLable",…
1
vote
1 answer

How to set Eval("DropDownList.SelectedItem.text") programmatically to gridview in asp.net c#

aspx.cs file is: CS file code: My marks database structure is marks(Standard varchar(20),Type_of_Exam varchar(20),telugu varchar(20),hindi varchar(20),eng......) I give those subjects in dropdown list items like telugu,hindi,english,..... I use…
Ajay
  • 2,022
  • 19
  • 33
1
vote
1 answer

Dynamically binding an external html file after the data-bind in Durandal

I've been searching and I've found somewhat similar questions to mine, but none that quite match what I'm trying to do (or at least, the solutions have not worked for me). I'm really new to Durandal so I have little clue where to start to accomplish…
1
vote
1 answer

Difference between dynamic loading and dynamic binding

What is the main difference between dynamic loading and dynamic binding in c++? and why dynamic loading is called static?
MBMJ
  • 5,323
  • 8
  • 32
  • 51
1
vote
2 answers

C++ clone and create to act as virtual constructor?

I am learning C++ in class and am working on trying to return a pointer to a derived object using a virtual create/clone function. I found this implementation and am about to build around it…
Flexo1515
  • 1,007
  • 1
  • 10
  • 27
1
vote
1 answer

some questions about virtual method table in c++

class A { public : int a; virtual void fun() {} virtual void init() {} }; class B { public : int b; virtual void sum() {} }; class C : public A, public B{ public : int c; virtual void dud() { …
우지식
  • 21
  • 3
1
vote
4 answers

Trying to understand casting and dynamic binding in terms of inheritance

Let's say I have a GrandParentClass that gets inherited by ParentClass which gets inherited by ChildClass. Why can I only cast "up the chain" but not down? Why can I only dynamic bind "down the chain" but not up? I'm looking for some reasoning I…
Kacy Raye
  • 1,312
  • 1
  • 11
  • 14
1
vote
3 answers

How to bind jquery function to a dynamic DOM

I am using jquery file upload function on my page like following: $('.new-variant-image') .fileupload({ dataType: 'script', add: function(e, data){ } }); but the DOM class "new-variant-image" is dynamically created after the…
user1883793
  • 4,011
  • 11
  • 36
  • 65
1
vote
2 answers

How Overloading and Overriding work together?

I understand the basics of overloading and overriding- but something is confusing me. I will try to explain using a simple example: Class B has a function X(B& b) Class D inherits from Class B. Class D overrides X with X(B& b) and also overloads…
user997112
  • 29,025
  • 43
  • 182
  • 361
1
vote
1 answer

Is it possible to create a static property that is static for the derived class, and not for all classes that derive from it?

I am trying to implement something like this: $child1_instance1 = new \aae\web\ChildOne(); $child1_instance2 = new \aae\web\ChildOne(); $child2_instance1 = new \aae\web\ChildTwo(); $child2_instance2 = new \aae\web\ChildTwo(); // setting the…
DudeOnRock
  • 3,685
  • 3
  • 27
  • 58
1
vote
1 answer

C# dynamic binding and void method call

Why does the compiler let this expression to compile while the run-time exception is inevitable? I don't think that the Dynamic Binding should work for void methods static void Main(string[] args) { var res = Test((dynamic)"test"); // throws…
Kamyar Nazeri
  • 25,786
  • 15
  • 50
  • 87
1
vote
1 answer

Dynamic binding in static method php

class A { static function get_name_derived_class() { //This function must return the name of the real class //Is it possible without insert a methon in B class? { } class B extends A { } B::test() I'd like to have a static…
Belsen
  • 313
  • 3
  • 4
  • 17
1
vote
6 answers

Dynamic binding in C++ on copied object

I have a problem in virtual function: Here is some code as an example: class A { public : virtual void print(void) { cout<< "A::print()"<
alan.chen
  • 2,115
  • 3
  • 15
  • 13
0
votes
3 answers

Pointer to base class sub-object. Which version of virtual function is invoked?

In dynamic binding, the function call is bound to the function implementation based on the type of object to which the pointer is pointing to. Suppose we have the following code : base *bptr = new derived; bptr->func(); Let the function func be…
nitin_cherian
  • 6,405
  • 21
  • 76
  • 127