use of com.example.domain.Note in project javaee7-samples by javaee-samples.
the class NoteResourceImpl method removeNote.
@Override
public void removeNote(Long noteId) {
final Note note = entityManager.find(Note.class, noteId);
if (null == note) {
throw new NoResultException("No note with id " + noteId + " found");
}
entityManager.remove(note);
}
Aggregations