#!/usr/bin/env python
from coral import *

UML14=Language.__getLanguage__("UML",1,4)
UML14Class = UML14.getElement("Class")

o = Set()

for n in range(10):
    c=UML14Class(name="class"+str(n))
    o.add(c)

print o
print o.select(lambda e: e.name=="class2")
print o.collect(lambda e: e)
print o.collect(lambda e: e.__getSlotByName__("name")[0])
print o.collect(lambda e: e.name)
print o.name
    

