53 lines
979 B
Org Mode
53 lines
979 B
Org Mode
#+title: Tp4
|
|
|
|
#+begin_src plantuml :file ejercicioApadaptador.jpg
|
|
class Cliente
|
|
|
|
class Balanza implements AdaptadorBalanza{
|
|
+ pesar()
|
|
}
|
|
|
|
interface IAdaptadorBalanza{
|
|
+ pesar()
|
|
- balanza: NuevaBalanza
|
|
}
|
|
|
|
class NuevaBalanza{
|
|
+ leerPeso()
|
|
}
|
|
|
|
Cliente --> Balanza: Utiliza
|
|
IAdaptadorBalanza "*" o--> "1" NuevaBalanza
|
|
#+end_src
|
|
|
|
#+begin_src plantuml :file tp4.jpg
|
|
class Compound{
|
|
# boilingPoint: float
|
|
# boilingPoint: float
|
|
# meltingPoint: float
|
|
# molecularWeight: double
|
|
# molecularFormula: string
|
|
+ <<Virtual>> Display(): void
|
|
}
|
|
|
|
class RichCompound extends Compound{
|
|
- chemical: string
|
|
- bank: ChemicalDatabank
|
|
+ RichCompound(string chemical)
|
|
+ <<override>> Display(): void
|
|
}
|
|
RichCompound "1" -r-> "1" ChemicalDatabank
|
|
|
|
class ChemicalDatabank{
|
|
+ GetCriticalPoint(string compound, string point): float
|
|
+ GetMolecularStructure(string compound): stirng
|
|
+ GetMolecularWeight(string compound): double
|
|
}
|
|
|
|
class Program
|
|
{
|
|
- compound: Compound
|
|
}
|
|
Program "1" -l-> "1" Compound
|
|
#+end_src
|