Why you should avoid using abstraction and interface

Using abstraction lead us to write another higher-level of abstraction if it’s not leads, then your abstraction is bad.

e.g

abstract class CrazyExample
{
abstract protected function getValue();
abstract protected function getOptions();


This content originally appeared on DEV Community and was authored by Muhammad Fauzan

Using abstraction lead us to write another higher-level of abstraction if it's not leads, then your abstraction is bad.

e.g

abstract class CrazyExample
{
    abstract protected function getValue();
    abstract protected function getOptions();
    abstract protected function getValueAndOptions(); //??
}

what is the benefit of hiding the complexity of a system? is it just to waste your time, you would be find the way back to your complexity during development again.


This content originally appeared on DEV Community and was authored by Muhammad Fauzan


Print Share Comment Cite Upload Translate Updates
APA

Muhammad Fauzan | Sciencx (2021-10-02T09:07:40+00:00) Why you should avoid using abstraction and interface. Retrieved from https://www.scien.cx/2021/10/02/why-you-should-avoid-using-abstraction-and-interface/

MLA
" » Why you should avoid using abstraction and interface." Muhammad Fauzan | Sciencx - Saturday October 2, 2021, https://www.scien.cx/2021/10/02/why-you-should-avoid-using-abstraction-and-interface/
HARVARD
Muhammad Fauzan | Sciencx Saturday October 2, 2021 » Why you should avoid using abstraction and interface., viewed ,<https://www.scien.cx/2021/10/02/why-you-should-avoid-using-abstraction-and-interface/>
VANCOUVER
Muhammad Fauzan | Sciencx - » Why you should avoid using abstraction and interface. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2021/10/02/why-you-should-avoid-using-abstraction-and-interface/
CHICAGO
" » Why you should avoid using abstraction and interface." Muhammad Fauzan | Sciencx - Accessed . https://www.scien.cx/2021/10/02/why-you-should-avoid-using-abstraction-and-interface/
IEEE
" » Why you should avoid using abstraction and interface." Muhammad Fauzan | Sciencx [Online]. Available: https://www.scien.cx/2021/10/02/why-you-should-avoid-using-abstraction-and-interface/. [Accessed: ]
rf:citation
» Why you should avoid using abstraction and interface | Muhammad Fauzan | Sciencx | https://www.scien.cx/2021/10/02/why-you-should-avoid-using-abstraction-and-interface/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.