@use Control. @plugin "plugin.so" (SAbrFunctions). Object : Teoria (aka Teorias) { + variables: ptr (pointer). + to init named name (string) with-action action (string) executed k = 1 (int) succeeded p = 1 (int): ptr = TeoriaNew(name, action, k, p). + to add-dato-inicial name theName (string) value theValue (float): TeoriaAddDatoInicial(ptr, theName, theValue). + to add-dato-final name theName (string) value theValue (float): TeoriaAddDatoFinal(ptr, theName, theValue). - to get-ptr: return ptr. + to destroy: TeoriaDelete(ptr). } Object : SistemaAutonomo { + variables: ptr (pointer). + to init: ptr = SistemaAutonomoNew(). + to add teoria theTeoria (object): SistemaAutonomoAddTeoria(ptr, (theTeoria get-ptr)). + to set value theValue (float) with-name theName (string): SistemaAutonomoSetValue(ptr, theName, theValue). + to update entorno theEntorno (hash): foreach nombre in keys(theEntorno): { self set value theEntorno{nombre} with-name nombre. } + to plan: SistemaAutonomoPlan(ptr). + to get-next-action: return SistemaAutonomoGetNextAction(ptr). + to validate-current-theory: return SistemaAutonomoValidateCurrentTheory(ptr). + to destroy: SistemaAutonomoDelete(ptr). }