This project is read-only.
Project Description
SPDX makes it easier to write software that works with data stored in SharePoint Lists. It generates strongly-typed entity classes based on the List or the Content Type definition, enabling use of InstelliSense and virtually eliminating run-time errors. It is developed in C#.

When writing code that accesses the data stored in SharePoint lists, one always needs an in-memory representation for that data. There are two ways to represent the data.

The “Quick and Dirty” way -- using SPListItem object directly to represent the data in memory.

  • Quick: no need to write additional code

  • No IntelliSense
  • Not strongly-typed
  • High chance of run-time errors
  • Need to keep code in synch with underlying Content Type or List
The “Right” (but Tedious) Way -- write your own strongly type representation for list items and map it SPList fields

  • IntelliSense
  • Strongly-typed
  • If custom class code is correct, very low chance of run-time errors
  • Good OO design: can extend the class

  • Tedious to map every column
  • Mapping is error-prone
  • Pain to keep in-synch with the underlying Content Type, List or Doc Library
  • Not much fun

Both of these approaches are less than ideal. It would be great to use second approach without the extra work it requires.

Enter SPDX: The “Quick” and “Right” Way
  • Automatically generates and regenerates strongly-typed wrapper entity classes based on List or Content Type definition (the List or the Content Type must already be defined in SharePoint).
  • Works with Lists, Document Libraries, and Content Types
  • Majority of errors are now found at the compile time
  • SPDX is distributed as a SharePoint solution (it is a .WSP file) that installs in the development SharePoint environment and is used to generate the wrappers. There is no need to have it installed in production in order to use the wrapper classes.
  • Batch support – a command line executable that can generate the wrapper classes. Sometimes this can be useful to include in the pre-build event.
  • Automatic validation based on SharePoint meta-data
  • Treat SharePoint choice columns almost like enums
  • Easily traverse lookups columns (lazy loading)
  • Detailed exception error messaages (unlike generic SharePoint exceptions)
  • Facilitates good OO practices
  • etc.

Last edited Aug 27, 2010 at 10:14 PM by ibasin, version 12