Archive for the ‘Search Engine’ Category.
10 February, 2008, 02:28
Bloglines is still the only reader that provides an “official API” to make use of their services. I was working on a syndication application and decided to share the .NET Bloglines library that I wrote to use their web services.
Requirements
Quick Reference
- public Bloglines(string username, string password)
Member of CodingDay.Bloglines
Default constructor, password is optional for count function.
- public int Count()
Member of CodingDay.Bloglines
Returns number of unread items from your subscriptions
- public System.Collections.Generic.IEnumerable <Subscription> GetSubscriptionList()
Member of CodingDay.Bloglines
Gets the Subscription list from your account
- public System.Collections.Generic.IEnumerable<Channel> GetChannels(string SubId, bool markasRead)
Member of CodingDay.Bloglines
Get the rss feeds for a subscription ID returned from the subscription list function. MarkasRead parameter is the synchronization parameter to mark the changes on bloglines servers.
Download
Downloads: 140 File Name: Bloglines.cs
Downloads: 70 File Name: nBloglines.dll
Usage
- Create CodingDay.Bloglines object
var blines = new CodingDay.Bloglines("***@****.***", "******");
- Count unread items for the user
Console.WriteLine("{0}", blines.Count());
- Get list of subscriptions
var subscriptions = blines.GetSubscriptionList();
foreach (var item in subscriptions)
{
Console.WriteLine("id:{0}, url:{1}, parent:{2}", item.Id, item.Url, item.ParentId);
}
- Get items for a subscription feed or folder using the id returned from subscription function
// use a number from the subscriptions id
var channels = blines.GetChannels("64363260", false);
foreach (var item in channels)
{
Console.WriteLine("title:{0}, description:{1}", item.Title, item.Description);
foreach (var i in item.Items)
{
Console.WriteLine("{0}", i.Description);
}
}
For more details, check out http://www.bloglines.com/services/api/
11 December, 2007, 16:22
I really liked the XML expressiveness of Visual Basic, let’s build a very simple MSN History Search Engine using LINQ and XML Literals in Visual Basic.
The best thing is those literals could be used in LINQ expressions. Remember the simple XML file that MSN stores as a history.
- .@AttributeName : Accesses the attribute element in XML
- .<ElementName> : Accesses the element in XML
- …<Descendant name>: Accesses the descendant name in XML
Modifying the XML content is very neat as well either using the LINQ expressions or even in loops.
In .NET Framework 2.0 VB has one more feature called MY namespaces. It is very nice to access some dynamic data available like application or forms information. It also contains some helper functions to do some common tasks. Now I also found it very handy in a Windows Forms application.
Get the history files from the location and operate the XLINQ query:
Private Sub btnSearch_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
For Each file In My.Computer.FileSystem.GetFiles(dirLocation)
ProcessFile(file)
Next
txtOutput.Text = sBuild.ToString()
End Sub
The XLINQ query that does search magic for the messages is as follows :
Function ProcessFile(ByVal s As String) As Boolean
If s.EndsWith("xml") Then
Dim msn = XElement.Load(s)
Dim q = From message In msn.<message> _
Where message.<text>.Value.Contains(txtSearch.Text) _
Select From = (message.<from>.@FriendlyName), Too = (message.<to>.@FriendlyNam), _
Message = message.<text>.Value
For Each msgFound In q
sBuild.AppendLine(msgFound.From + " says to " + msgFound.Too + _
" : " + msgFound.Message)
Next
End If
End Function
What makes this different is the usage of literals. In C# that query would be longer than that.
In the sample message.<From>.@FriendlyName
means that it will get the From element and get the friendlyname attribute from it.
It is basically like having the XML data in your hands but there is no need to parse it or access the elements using the classes provided rather this work is done by the compiler at the compile time.
In a couple lines of code we have a fully featured MSN history searching. Let me know if you still want the source code (although that is all about it) or even the executable in case you are not into programming.
1 April, 2007, 05:06
I usually don’t use WordPress’ “write post” page to write blog entries unless I am using linux. Although there are some web clients as well, it is not better than wordpress’ post screen. I was using Windows Live Writer but nowadays I have switched to Word 2007 to post blogs. First of all, Word 2007 offers a reach interface comparing to Windows Live Writer. On the other hand Live Writer’s plugin support is better than Word’s; however I don’t use any plugin for the user interface. Second, Windows Live Writer is so slow to start and work. Windows Live Writer is not as good at formatting html as Word 2007 does. With Word 2007 you have the benefits of the rich platform, especially if you have a document written in word, it is easy to post it.
I am surprised with the support of many blog platforms, including wordpress of course.


You are able to use existing documents to format your post and the interface is nice to use for formatting the post.


16 February, 2007, 22:19
Yahoo! Pipes is a great idea implemented by Yahoo! with an incredibly amazing user interface. When I first played with I just shocked and suspected about flashy stuff. However it is based on only Javascript with the help of Yahoo’s great Yahoo! User Interface Library on the back-end.
The idea is simple to explain if you know the pipes from the operating systems. Basically linking the output of something to the input of something else or vice versa. Something in this case is the RSS feeds or web services provided from different sources.
Pipes are one of the main concepts in parallel computing for pipelining the process. Since web is enormously distributed, what you can do is infinite. There are some operators available like for each, count, sort, filter that you can do various operations to the feeds. So with this tool, you can parallellise web and get the processed result.
The create pipe user interface is very similar to the IDE interface even it has a debugger as we used to do. On the left you have the toolbox and you have the design surface where you drag and drop the components. Beside creating your own pipes, you can also use people’s pipes as well.
10 December, 2006, 05:31
My windows became unbootable, I was receiving and I logged to my linux partition. I was looking for the bootdisks for my flash drive because I don’t have an XP cd (Laptop gave only the ghost image of Windows CD), I needed to have chkdsk command at least, so I googled for “windows boot disk usb chkdsk” then clicked the 2nd result which is “Bootdisk.Com Top Ten TuneUp Tips” the link goes to http://www.google.co.uk/interstitial?url=http://www.bootdisk.com/topten.htm site and the Malware Warning page.

I wouldn’t know, It is nice to know that, although I am totaly in an another platform (I am in linux and can’t boot windows) it is nice to have that.
I found BartPE bootable cd for the solution of my problem. It is uses Windows XP files and can be used for the bootable cd or bootable flash disk.
Here are links that you can find more information :
6 October, 2006, 19:35
Google announced and released their code search engine in Google Code blog. It crawls and indexes for the program file types and also some compressed file types. Unlike the succesful results in the web query I just couldn’t find the things I want. So apparently their page rank algorithm won’t work there. Anyway it is just a start and it still in the labs..