implementation

Django app with selectable field types from admin panel?

Looking for some implementation ideas here. I am trying to design a custom polling system for my school, to allow teachers to give students polls to take. I have a Poll model, Question model (with a foreignkey to Poll model), and Choice model (with a foreignkey to the Question model). What I need to be able to do is allow whoever is ad...

[How-to] Create a Delegate for iphone (in a separate file)

Hey guys, I have been looking for hours and didn't find anything so I decided to give up and ask for your precious knowledge ;) In order to make my code cleaner, I would like to implement the delegate methods of NSXMLParser in another file ... but I couldn't find any tutorials ... Could someone explain me briefly how to do that ? Ch...

Implementing Loops from Pseudocode

Hi everyone, I was wondering if anyone could suggest to me how to implement this loop in the following pseudocode: 8: loop 9: while f[0] = 0 do 10: for i = 1 to N do 11: f[i ¡ 1] = f[i] 12: c[N + 1 - i] = c[N - i] 13: end for 14: f[N] = 0 15: c[0] = 0 16: k = k + 1 17: end while 18: if deg(f) = 0 then 19: go...

Understanding the library functions in c++

If I'd like to know how a function written in like standard C++ library work (not just the MSDN description). I mean how does it allocate, manage, deallocate memory and return you the result. where or what do you need to know to understand that? ...

MPI implementation: Can MPI_Recv receive messages from many MPI_Send?

Now I am trying to use MPI_Sendand MPI_Recv to pass best found solutions among several processes. The best solutions found in each process are supposed to pass to the control process what stores all best solutions and send to other processes when required. My question is how to implement it? For example, once process 1 find a new best, i...

Simplest database implementation

I am looking for a really simple database implementation; basically one with no complex parsing SQL engine. What I am looking for is something demonstrating B+ trees and ACID storage (Suitable for educational purposes). What I have found up-till now form my current searches was hamster-db. I am looking for something even simpler with a s...

How is the PHP array implemented on the C level?

The PHP array is one of the language's core features IMHO. It is sparse, allows multi-typed keys in the same array, and supports set, dictionary, array, stack/queue and iterative functionality. BUT after working with PHP for a while now, I've found that quite a few of the array_* functions are much slower than you'd think at first glanc...

PHP tree implementation: Accessing parent node

I have an own Tree object implemented in PHP. Say we have a tree like: Root |_ Folder 1 |_ Folder 2 |_ Subfolder 1 I can access Subfolder 1 like this: $sf1 = $Tree->NavigateTo("Folder 2/Subfolder 1") And $sf1 will hold the Subfolder 1 node. I want to implement a GetParentNode() method, so that $parent = $sf1->GetParent...

Inheritance from multiple interface with the same method name in C#

If we have a class that inherits from multiple interfaces, and the interfaces have methods with the same name, how can we implement these methods in my class? How we can specify that which method of which interface is implemented? ...

How to implement an interface in VB.Net when two methods have the same name but different parameters

I am a C# programmer but I have to work with some VB.Net code and I came across a situation where I have two methods on an interface with the same name but different method parameters. When I attempt to implement this interface in a class, VB.Net requires explicitly declaring "Implements MethodName" after the method signature. Since both...

Adding implementation without recompiling in Java?

Hey everyone, I'm a college senior with my first real job opportunity (exciting). I'm at the stage now where they need to see a programming example, and they gave me the task of implementing a random number generator service in Java, with two different implementations (one using the built-in stuff and another of my choice). The code is t...

LinkedList copy constructor implementation details.

Hello all. My first post here so be please be kind :) I searched SO before posting but I couldn't find an answer (it's possible that my search wasn't the best though) I'm starting to learn C++ and as an exercise decide to implement a simple LinkedList class (Below there is part of the code). I have a question regarding the way the cop...

How to tell if an object supports scalar comparisons?

Does anyone have a quick snippet or direction of how i would check to see if a given class supports the >, = and < operators? Given an object passed in, I am looking for code that implements the following logic: If GetType(someObj).SupportsScalarComparisons() Then ... I don't know if this is a case for Reflection, or ? Thanks in ad...

Need a sample function implement for array interface member...

I have a interface member like this. AppInterface.cs ObjLocation[] ArrayLocations { get; } App.cs public ObjLocation[] ArrayLocations { get { return **something**; } } I dont know how to complete it, Or there is another way to implement the array members. Then It...

Problem implementing Interceptor pattern

I'm attempting to develop an Interceptor framework (in C#) where I can simply implement some interfaces, and through the use of some static initialization, register all my Interceptors with a common Dispatcher to be invoked at a later time. The problem lies in the fact that my Interceptor implementations are never actually referenced by...

webdav implementation in c

Hello Everyone, I would like to know do we have any webdav protocol implementation in c or c++. Thank You in advance.. ...

Advantages/Disadvantages of different implementations for Comparing Objects using .NET

This questions involves 2 different implementations of essentially the same code. First, using delegate to create a Comparison method that can be used as a parameter when sorting a collection of objects: class Foo { public static Comparison<Foo> BarComparison = delegate(Foo foo1, Foo foo2) { return foo1.Bar.CompareTo(fo...

Hashtable implementation tutorial

Does anyone know a good website for learning how to create and implement hash tables for beginners in java? ...

How to implement a web app with blazeds+java+flex+tomcat?

Hi, i'm doing a web app in flex blazeds and java, i installed the eclipse plugs for using WTP mixed project, i use the flex's server that uses an emulate of tomcat when i ran my flex service the web app got the datas, everythings is ok. the problem is when i copy the proyect with all files generated by flex in my tomcat or the blazeds's ...

implementing google wave into a website

How do I implement my own personal copy of google wave into a website? Im talking about something similar to the "Acme Wave" example. I found http://www.waveprotocol.org/ but am unsure how I go from there to install it on a web host. ...