[hibernate-issues] [Hibernate-JIRA] Created: (HHH-1977) SortedSet property won't get sorted

Lóránt Pintér (JIRA) noreply at atlassian.com
Fri Aug 4 21:05:10 EDT 2006


SortedSet property won't get sorted
-----------------------------------

         Key: HHH-1977
         URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1977
     Project: Hibernate3
        Type: Bug

  Components: core  
    Versions: 3.1.3, 3.2.0.cr2    
    Reporter: Lóránt Pintér


I have an entity with a SortedSet property that should be sorted by its natural order:

	private SortedSet<DBField> fields;

	@OneToMany(cascade = CascadeType.ALL, mappedBy = "table", fetch = FetchType.EAGER)
	@Sort(type = SortType.NATURAL)
	public SortedSet<DBField> getFields() {
		return fields;
	}

	public void setFields(SortedSet<DBField> fields) {
		this.fields = fields;
	}

but it is not sorted. The compareTo() method gets called a few times, but the result is not sorted.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira





More information about the hibernate-issues mailing list