docs: function(attrs, options) {
          var attr, key, val, eve;
          if (attrs === null) return this;
  
          if (attrs.eClass) {
              attrs = attrs.get('name');
          }
  
          // Handle attrs is a hash or attrs is
          // property and options the value to be set.
          if (!_.isObject(attrs)) {
              key = attrs;
              (attrs = {})[key] = options;
          }
  
          var eResource = this.eResource();
  
          for (attr in attrs) {
              val = attrs[attr];
              if (typeof val !== 'undefined' && this.has(attr)) {
                  if (this.isSet(attr)) {
                      this.unset(attr);
                  }
  
                  var feature = getEStructuralFeature(this.eClass, attr),
                      isContainment = feature.get('containment');
  
                  var settingContainmentAttribute = (attr === 'containment') && (typeof(val) === 'string') && (this.eClass.values.name === 'EReference');
                  if (settingContainmentAttribute) {
                      // Convert string 'true' to boolean true
                      val = (val.toLowerCase() === 'true');
                  }
  
                  this.values[attr] = val;
  
                  if (isContainment) {
                    val.eContainingFeature = feature;
                    val.eContainer = this;
                  }
                  eve = 'change:' + attr;
                  this.trigger('change ' + eve, attr);
                  if (eResource) eResource.trigger('change', this);
              }
          }
  
          return this;
      }