title: Sort TreeView by name
body: <p>I have this very simple example of TreeView.</p>
  
  <pre><code>import javafx.application.Application;
  import javafx.beans.property.ReadOnlyStringWrapper;
  import javafx.scene.Group;
  import javafx.scene.Scene;
  import javafx.scene.control.TreeTableColumn;
  import javafx.scene.control.TreeTableColumn.CellDataFeatures;
  import javafx.scene.control.TreeItem;
  import javafx.scene.control.TreeTableView;
  import javafx.stage.Stage;
  
  public class TreeTableViewSample extends Application {
  
      public static void main(String[] args) {
          Application.launch(args);
      }
  
      @Override
      public void start(Stage stage) {
          stage.setTitle("Tree Table View Samples");
          final Scene scene = new Scene(new Group(), 200, 400);
          Group sceneRoot = (Group)scene.getRoot();  
  
          //Creating tree items
          final TreeItem&lt;String&gt; childNode1 = new TreeItem&lt;&gt;("Child Node 1");
          final TreeItem&lt;String&gt; childNode2 = new TreeItem&lt;&gt;("Child Node 2");
          final TreeItem&lt;String&gt; childNode3 = new TreeItem&lt;&gt;("Child Node 3");
  
          //Creating the root element
          final TreeItem&lt;String&gt; root = new TreeItem&lt;&gt;("Root node");
          root.setExpanded(true);   
  
          //Adding tree items to the root
          root.getChildren().setAll(childNode1, childNode2, childNode3);        
  
          //Creating a column
          TreeTableColumn&lt;String,String&gt; column = new TreeTableColumn&lt;&gt;("Column");
          column.setPrefWidth(150);   
  
          //Defining cell content
          column.setCellValueFactory((CellDataFeatures&lt;String, String&gt; p) -&gt; 
              new ReadOnlyStringWrapper(p.getValue().getValue()));  
  
          //Creating a tree table view
          final TreeTableView&lt;String&gt; treeTableView = new TreeTableView&lt;&gt;(root);
          treeTableView.getColumns().add(column);
          treeTableView.setPrefWidth(152);
          treeTableView.setShowRoot(true);             
          sceneRoot.getChildren().add(treeTableView);
          stage.setScene(scene);
          stage.show();
      }     
  }
  </code></pre>
  
  <p>I'm interested how I can sort the tree nodes by name?</p>
  
  <p>Is this functionality already implemented in JavaFX or I need to implement custom tree cell?</p>
  
  <p>Is there any example that I can use?</p>