UML for OCaml immediate objects
问题 I have created an immediate object in OCaml. let x = object (self) val dataMember = 3 method aMethod = print_endline "Called a method" end;; As the object doesn't have a name (is it considered anonymous?), how can it be correctly represented in UML? Thanks. 回答1: You could give it a nonce-name, or some other formulaic value. "Correctly" in this context really just means something that will be clear. There is no "right answer" handed down from the International UML Standards Body or anything.