Question: Which SOLID design principles (if any) does the following pseudo code violate? interface i_pet string get_name) string get_species() color get_fur_color() end interface interface i_cat implements


Which SOLID design principles (if any) does the following pseudo code violate? interface i_pet string get_name) string get_species() color get_fur_color() end interface interface i_cat implements i_pet end interface interface i fish implements i_pet end interface class cat implements i_cat bool get_is_fresh_water() string name string species color fur color cat(string name, string sepcies, color fur_color): this.namename this.species species this.fur_color-fur_color string get species () string get_name ): color get_fur_color) return species returnname return fur_color end class class fish implements i_fish string name string species bool is_fresh_water fish(string name, string sepcies, bool is_fresh_water) this.name name this. species species this.is_fresh_water-is_fresh_water Which SOLID design principles (if any) does the following pseudo code violate? interface i_pet string get_name) string get_species() color get_fur_color() end interface interface i_cat implements i_pet end interface interface i fish implements i_pet end interface class cat implements i_cat bool get_is_fresh_water() string name string species color fur color cat(string name, string sepcies, color fur_color): this.namename this.species species this.fur_color-fur_color string get species () string get_name ): color get_fur_color) return species returnname return fur_color end class class fish implements i_fish string name string species bool is_fresh_water fish(string name, string sepcies, bool is_fresh_water) this.name name this. species species this.is_fresh_water-is_fresh_water
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
