tasks a-s
This commit is contained in:
parent
47bf37c096
commit
b83f433714
12433 changed files with 156208 additions and 123 deletions
|
|
@ -0,0 +1,19 @@
|
|||
File objectStore = new File('objectStore.ser')
|
||||
if (objectStore.exists()) { objectStore.delete() }
|
||||
assert ! objectStore.exists()
|
||||
def os
|
||||
try {
|
||||
os = objectStore.newObjectOutputStream()
|
||||
os << new Person()
|
||||
os << 10.5
|
||||
os << new Person('Cletus')
|
||||
os << new Date()
|
||||
os << new Person('Pious')
|
||||
os << java.awt.Color.RED
|
||||
os << new Person('Linus')
|
||||
os << 'just random garbage'
|
||||
os << new Person('Lucy')
|
||||
os << ['lists', 'are', 'serializable']
|
||||
os << new Person('Schroeder')
|
||||
} catch (e) { throw new Exception(e) } finally { os?.close() }
|
||||
assert objectStore.exists()
|
||||
Loading…
Add table
Add a link
Reference in a new issue