根据下面的代码,你能告诉我如何(如果可能的话)ComputationUnit
从类中引用类中定义的数组Service
吗?
class ComputationUnit {
contains Method[1..*] methods
}
class Method {
String name
String signature
Object sourceCode
contains Parameter[1..*] parameters
}
class Servic e {
contains Comment comment
contains Parameter[1..*] parameters
contains Contract[0..*] contracts
refers Method[] methods //How can I refer to the array defined inside the ComputationUnit class?
}