public Set<String> getAttributeNames() {
    checkMapUsage();
    Set<String> names = new HashSet<String>();
    for (String name : this.attributes.keySet()) {
      if (getAttribute(name) != null) {
        names.add(name);
      }
    }
    if (feature_set != null) {
      for (String name : feature_set.getRequiredFeatures()) {
        if (getAttribute(name) != null) {
          names.add(name);
        }
      }
      if (feature_set.class_attribute != null) {
        if (getAttribute(feature_set.class_attribute) != null) {
          names.add(feature_set.class_attribute);
        }
      }
    }
    return names;
  }