org.drools.eclipse.dsl.editor
Class DSLMappingSorter

java.lang.Object
  extended by org.eclipse.jface.viewers.ViewerComparator
      extended by org.eclipse.jface.viewers.ViewerSorter
          extended by org.drools.eclipse.dsl.editor.DSLMappingSorter

public class DSLMappingSorter
extends org.eclipse.jface.viewers.ViewerSorter

Provides sorting for the natural language table viewer.


Field Summary
static int EXPRESSION
           
static int MAPPING
           
static int OBJECT
           
static int SCOPE
           
 
Fields inherited from class org.eclipse.jface.viewers.ViewerSorter
collator
 
Constructor Summary
DSLMappingSorter(int criteria)
          Creates a resource sorter that will use the given sort criteria.
 
Method Summary
 int compare(org.eclipse.jface.viewers.Viewer viewer, Object o1, Object o2)
           
 int getCriteria()
           
 
Methods inherited from class org.eclipse.jface.viewers.ViewerSorter
getCollator
 
Methods inherited from class org.eclipse.jface.viewers.ViewerComparator
category, getComparator, isSorterProperty, sort
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

OBJECT

public static final int OBJECT
See Also:
Constant Field Values

EXPRESSION

public static final int EXPRESSION
See Also:
Constant Field Values

MAPPING

public static final int MAPPING
See Also:
Constant Field Values

SCOPE

public static final int SCOPE
See Also:
Constant Field Values
Constructor Detail

DSLMappingSorter

public DSLMappingSorter(int criteria)
Creates a resource sorter that will use the given sort criteria.

Parameters:
criteria - the sort criterion to use: one of NAME or TYPE
Method Detail

compare

public int compare(org.eclipse.jface.viewers.Viewer viewer,
                   Object o1,
                   Object o2)
Overrides:
compare in class org.eclipse.jface.viewers.ViewerComparator

getCriteria

public int getCriteria()
Returns:
the sort criterion


Copyright © 2001-2012 JBoss by Red Hat. All Rights Reserved.