def non_id_search_attribute_values
      # if there is a secondary key, then search on those attributes.
      # otherwise, search on all attributes.
      key_props = self.class.secondary_key_attributes
      pas = key_props.empty? ? self.class.nondomain_java_attributes : key_props
      # associate the values
      attr_values = pas.to_compact_hash { |pa| send(pa) }
      # if there is no secondary key, then cull empty values
      key_props.empty? ? attr_values.delete_if { |pa, value| value.nil? } : attr_values
    end
def non_id_search_attribute_values
      # if there is a secondary key, then search on those attributes.
      # otherwise, search on all attributes.
      key_props = self.class.secondary_key_attributes
      pas = key_props.empty? ? self.class.nondomain_java_attributes : key_props
      # associate the values
      attr_values = pas.to_compact_hash { |pa| send(pa) }
      # if there is no secondary key, then cull empty values
      key_props.empty? ? attr_values.delete_if { |pa, value| value.nil? } : attr_values
    end
Returns the attribute => value hash to use for matching this domain object.
 @see #search_attribute_values the method specification