So there are 115 documented properties that you can query the Google Desktop API for, on files. To get the info you have to call the “GetProperty()” method on the Search Result object and pass in the string value of the property name.

However, there’s a catch…. not all the properties work for all the different schemas…. The documented schemas are:

But there is no mention in the documentation as to which properties will work for each schema. Also… the actual values of the schemas, are:

public class GoogleSchema
  {
    private GoogleSchema( ) {}
    public const String Text = "Google.Desktop.TextFile";
    public const String File = "Google.Desktop.File";
    public const String Media = "Google.Desktop.MediaFile";
  }

These are the only file schema’s that I was able to receive from Google Desktop API. Out of all 115 properties documented here are the properties, I was actually able to pull info for… based on the “schema”:

public class MediaSchemaProperty
  {
    private MediaSchemaProperty( ) {}
    public const String Author = "author";
    public const String InfoTip = "info_tip";
    public const String Title = "title";
    public const String Uri = "uri";
  }

  public class TextSchemaProperty
  {
    public const String Content = "content";
    public const String TextContent = "text_content";
    public const String Uri = "uri";
  }

  public class FileSchemaProperty : TextSchemaProperty
  {
    private FileSchemaProperty( ) {}
  }

That would be it… So it turns out the querying using the XML/HTTP approach yields a whole lot more information.

Attached is the source code… enjoy!

DesktopSearch.zip (751.27 KB)

comments powered by Disqus