473,569 Members | 2,789 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Graph Search Algorithm (Visual Web Developer Express)

12 New Member
Hi,

I wonder if someone could help me. I'm trying to develop a search algorithm as I need an engine that can determine the shortest route between two locations based on the number of stops.

I have found an article called An Extensive Examination of Data Structures Using C# 2.0 (http://msdn2.microsoft .com/en-us/library/ms379574(VS.80) .aspx) which is a very good article and it supplied four classes which I can in theory use:
Node;
NodeList;
GraphNode; and
Graph
Unfortunately the code doesn't work (in Visual Web Developer Express). I keep getting the following errors:
1 NodeList<T>' does not implement interface member 'System.Collect ions.Generic.IC ollection<Node< T>>.Add(Node<T> )'
2 'NodeList<T>' does not implement interface member 'System.Collect ions.Generic.IC ollection<Node< T>>.Clear()'
3 'NodeList<T>' does not implement interface member 'System.Collect ions.Generic.IC ollection<Node< T>>.Contains(No de<T>)'
4 'NodeList<T>' does not implement interface member 'System.Collect ions.Generic.IC ollection<Node< T>>.CopyTo(Node <T>[], int)'
5 'NodeList<T>' does not implement interface member 'System.Collect ions.Generic.IC ollection<Node< T>>.Remove(Node <T>)'
6 'NodeList<T>' does not implement interface member 'System.Collect ions.Generic.IC ollection<Node< T>>.Count'
7 'NodeList<T>' does not implement interface member 'System.Collect ions.Generic.IC ollection<Node< T>>.IsReadOnly '
8 'NodeList<T>' does not implement interface member 'System.Collect ions.Generic.IE numerable<Node< T>>.GetEnumerat or()'
9 'NodeList<T>' does not implement interface member 'System.Collect ions.IEnumerabl e.GetEnumerator ()'

Can anyone advise what these are and how I can fix these? I also get the same erros when I run it in Visual Studio Express.

Alternatively are there any prebuilt search algorithms that I can use in Visual Web Developer express.

Thank you for taking the time to read this. Regards, Ian
May 17 '07 #1
1 2076
gihope
12 New Member
I have incidentally figured out why the code isn't working. The data structures used in this article no longer exist in the class libraries quoted "System.Collect ions.Generic" such as Collection. I therefore altered the code to use ICollection which does exist in the "System.Collect ions.Generic" namespace.

The problem with this is that ICollection is an interface and not a class that I can directly inherit from using the articles code. This could be wrong, but from what I have deduced I would need to have also implemented the methods of this interface also in order to inherit fro it??

If anyone else comes accross this problem, I suggest using the "System.Collect ions.ObjectMode l" namespace as it has a collection base class from which you can inherit the NodeList class.

It would have saved me considerable time if the article had reflected the current state of developments, but then I guess I wouldn't have understood it better!

Thank you to anyone who may have spent time trying to work out what the isue was. Kind Regards, Ian
May 18 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

3
3447
by: Paul Moore | last post by:
I'm trying to check a graph (represented in the usual Python adjacency list format) for loops. This is dead simple - you use a depth-first search, and look out for "back edges" (edges from a vertex "back" to one you've already seen). I already have a DFS algorithm which generates each edge in turn. It's great for what it does, but it...
25
3768
by: Magnus Lie Hetland | last post by:
Is there any interest in a (hypothetical) standard graph API (with 'graph' meaning a network, consisting of nodes and edges)? Yes, we have the standard ways of implementing graphs through (e.g.) dicts mapping nodes to neighbor-sets, but if one wants a graph that's implemented in some other way, this may not be the most convenient (or...
4
5021
by: sasha.mal | last post by:
Hello everybody! Could anyone help with a practical graph isomorphism algorithm, coded in C++ (C would also do), to work with genus bounded graphs of a bounded degree. Currently, any algorithm to work with planar graphs with degree bounded by 4 (on a quadratic grid) would also help.
3
1864
by: clintonG | last post by:
Visual C# 2005 Express Edition is a simple, lightweight, integrated development environment designed for beginning programmers and non-professional developers interested in building Windows Forms, class libraries, and console-based applications. Visual C# 2005 Express Edition includes many of the same productivity features found in Visual...
3
2126
by: Amol | last post by:
I am working on an interesting graph optimization problem and I would like to have a few expert opinions for helping me with a solution. So here goes ... I have a black box with a complex internal circuitry that is represented in the form of a graph. I have to abstract the graph by reducing the number of internal points and constructing...
4
12085
by: Shuch | last post by:
Hi all, I am in shortage of time...and i want to know if someone has a code written in c++ or c for finding the shortest path using stack or queue??????my specifications r as follow: Input data: n = integer number representing the number of vertices k = small integer number representing the maximal vertex degree G = unoriented labeled...
5
2207
by: cj | last post by:
I'm getting started writing WEB program in VB2005. I'm been doing windows apps to date. A friend told me to get Visual Web Developer Express Edition. But I have Visual Studio Pro 2005 and it says I have Visual Web Developer in it. I'm just not sure what that is and how to start it. Any advise?
10
1890
by: andrea | last post by:
I'm studying some graphs algorithm (minumum spanning tree, breath search first topological sort etc etc...) and to understand better the theory I'm implementing them with python... I made my own graph class, the constructor is simply this: class graph: "in forma di matrice e' una matrice normale, in forma di lista uso un dizionario" def...
2
3384
by: Cramer | last post by:
So, what is the relationship between Visual Studio and Visual Web Developer. I find a lot of documentation on MSDN that presents Visual Web Developer as it's own stand-alone product (which I'd expect of the Express editions), but apparently there are NON Express versions of Visual Web Developer. Is Visual Web Developer only built-in to...
0
7697
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7612
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
7924
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
0
8120
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7672
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
1
5512
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
5219
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3640
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
937
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.