Search code examples
oopobjectmethodology

How do I build object oriented software with seemingly objectless ideas?


My question, is not a philosophical one, but one of methodology. I understand how we build software to mimic everyday processes and objects, like the 'car' object so well demonstrated. My question is about lesser concrete things. For example, If I were to build a search application that returns products and prices from a database (as a part of a much larger application), would I imagine this in terms of how it might be implemented in life? For example, a 'search agent' object in code that would mimic a real life 'human search agent' (create attributes and methods from that)? Essentially, if something doesn't have an obvious real-life counterpart, do we take that idea and create a representation of it so we CAN code it? How should I think about objects in an application that do not mimic life so much?

Thanks for all your input


Solution

  • Object Oriented design is not about mimicking real life objects.

    That is just a lazy guidance on how to abstract objects for your problem domain. A good start but is not sufficient for more abstract problem domains.

    The underlying idea is to be able to abstract those units that can be abstracted from other units within you problem domain based on data and behavior.