I have a TableView that is populated on a scene. I am searching the objects properties to see if they match, and the property is returning StringProperty [value: 3]. I am just trying to see the proper way to complete this comparison.

Here is the code:

```
@FXML
public void searchParts(ActionEvent event) throws IOException{
  System.out.println("Searching for part: " + searchPart.getText());
  String partSearchable = searchPart.getText();
      for (int i = 0; i < parts.size(); i++) {
         System.out.println(parts.get(i).nameProperty());           

          if (parts.get(i).nameProperty().equals(new SimpleStringProperty(partSearchable))) {
            partsList.clear();
            partsList.add(parts.get(i));
            populateTable();
            break;
         }  
     }
    partsList.clear();
    populateTable();
}

```

Here is the getter method in the part class:

```
public SimpleStringProperty nameProperty(){
    return new SimpleStringProperty(name.get());
}

```

What would the proper way to do this comparison?