What is Reification?

Reification is a concept that gets realized in programming in a handful of different ways.

1. Reification in RDF

In RDF, reification takes claims like "John is a tool" and adds in the contextual information about who is making the claim, turning them into claims like "Dave says John is a tool." This is useful because RDF documents don't have to have authority statements within them; if you obtain one from me, you may want the effect of reading it to be something like "Daniel says contents of daniel.rdf." rather than just the contents of my file.

2. Reification in object-oriented terms

Often during the evolution of a program, a method winds up sort of taking over a class and acquiring a large number of parameters. Something like this:

class Plotter:
  def plot_schedule(schedule): ...

evolves into something a little worse like this:

class Plotter:
  def plot_schedule(schedule, weather, program, authors, start, stop, ...): 
    ...

At some point you have to package up that whole method into an object, which will usually have the word "request" in the name, and then the method will take one of these requests instead of a billion parameters:

class Plotter:
  def plot_schedule(schedule_request):
    ...

class ScheduleRequest:
  def set_schedule(schedule): ...
  def set_weather(weather): ...

What's happened here is that the arguments to plot_schedule have been reified into an object called ScheduleRequest. The process could be taken as far as moving the actual plot method onto the schedule request. Maybe the plotter should just have lower-level methods anyway, and then ScheduleRequest becomes something more specific like SchedulePlot.

In general, converting verbs into nouns is a kind of reification.