def materialize(classnames)
      classes = (classnames.is_a?(Array) ? classnames : [classnames]).collect do |clazz|
        original_classname = clazz
        clazz = original_classname[0,1].capitalize + original_classname[1..-1]
        unless const_defined_in_module(module_namespace, clazz)
          new_class = module_namespace.const_set(clazz, Class.new(Databasedotcom::Sobject::Sobject))
          new_class.client = self
          new_class.materialize(original_classname)
          new_class
        else
          module_namespace.const_get(clazz)
        end
      end

      classes.length == 1 ? classes.first : classes
    end
def materialize(classnames)
      classes = (classnames.is_a?(Array) ? classnames : [classnames]).collect do |clazz|
        original_classname = clazz
        clazz = original_classname[0,1].capitalize + original_classname[1..-1]
        unless const_defined_in_module(module_namespace, clazz)
          new_class = module_namespace.const_set(clazz, Class.new(Databasedotcom::Sobject::Sobject))
          new_class.client = self
          new_class.materialize(original_classname)
          new_class
        else
          module_namespace.const_get(clazz)
        end
      end

      classes.length == 1 ? classes.first : classes
    end
Dynamically defines classes for Force.com class names.  _classnames_ can be a single String or an Array of Strings.  Returns the class or Array of classes defined.

    client.materialize("Contact") #=> Contact
    client.materialize(%w(Contact Company)) #=> [Contact, Company]

 The classes defined by materialize derive from Sobject, and have getters and setters defined for all the attributes defined by the associated Force.com Sobject.