1 package org.apache.ojb.otm.states; 2 3 17 18 22 public class PersistentNewDeleted extends State 23 { 24 25 PersistentNewDeleted() 26 { 27 } 28 29 32 public String toString() 33 { 34 return "Persistent-new-deleted"; 35 } 36 37 39 42 public State makePersistent() 43 throws IllegalObjectStateException 44 { 45 return State.PERSISTENT_NEW; 46 } 47 48 51 public State deletePersistent() 52 throws IllegalObjectStateException 53 { 54 return this; 55 } 56 57 60 public State commit() 61 throws IllegalObjectStateException 62 { 63 return State.TRANSIENT; 64 } 65 66 69 public State rollback() 70 throws IllegalObjectStateException 71 { 72 return State.TRANSIENT; 73 } 74 75 public boolean isDeleted() 76 { 77 return true; 78 } 79 } 80 | Popular Tags |