[gmpi] Re: low level API - Abstract Factory summary

  • From: "gogins@xxxxxxxxxxxx" <gogins@xxxxxxxxxxxx>
  • To: gmpi@xxxxxxxxxxxxx
  • Date: Wed, 9 Feb 2005 16:06:23 -0500

Ron, my experience is that Windows programmers use C++ quite a bit more
than Linux programmers, who tend to use C. I have no idea why this is so,
except as a legacy from the history of Unix, especially since Windows comes
without any compilers at all, and Unix and Linux tend to come with C++
compilers.

Perhaps one reason is that C++ compiler vendors were not as compliant with
the language standard in the past, as compared with C compiler vendors.
This would be a problem for Unix/Linux programmers since they face many
processor choices and many variants of the operating system.

Standards compliance is no longer a serious issue for C++. gcc, msvc, and
Intel are all adequately compliant with ISO C++.

I have encountered many incorrect presuppositions about C++ from C
programmers...

Original Message:
-----------------
From: Ron Kuper RonKuper@xxxxxxxxxxxx
Date: Wed, 9 Feb 2005 15:42:00 -0500
To: gmpi@xxxxxxxxxxxxx
Subject: [gmpi] Re: low level API - Abstract Factory summary


>>>
It's simpler because there is less code, less entities, less
explanation.
:)
<<<

I assert that the OO version has the same code, and less explanation
than the C version.  When I see C code that does in a few steps what
simple class can do, I am reminded why I no longer code in C.

>>>
And to me it's a hack to squeeze another class into the system.  One of
the biggest problems I have with OO is that it gets over-normalized.
You
end up with a bazillion factories and message passers and so on and so
forth.  
<<<

That's an overgeneralization if I ever heard one.  How "over normalized"
can OO get in general?  Who said a bazillion factories?  There's 1
factory, with a case statement, each each case creating a new object.
Done, clean and simple.

>>>
If something is an entity, make it an entity - a Plugin has data
and code and begs to be encapsulated.  If something is a process, make
it
a process - a Factory exists to do something just the same as a
function.
<<<

Everything is an object.  A factory isn't a process, a factory is an
object that performs an action.

>>>
Contrary to some OO pundits, it's not always bad to have functions that
aren't attached to an object.
<<<

On whose authority are you making that claim?

>>>
I *barely* program C++, but I know OO very well.  I see part of my
job as reminding you all that the API is still meant to be usable from C
:)
<<<

Of course the API will be usable from C, by requirement.  I thought we
chose C for portability, to make it easier for hosts and plugins written
in a variety of languages to interoperate.

But all this time, I for one assumed that 99.9% of use were writing
plugs and hosts in C++.  The C part was interface layer only.  I don't
think many of us expect to code to straight C.

----------------------------------------------------------------------
Generalized Music Plugin Interface (GMPI) public discussion list
Participation in this list is contingent upon your abiding by the
following rules:  Please stay on topic.  You are responsible for your own
words.  Please respect your fellow subscribers.  Please do not
redistribute anyone else's words without their permission.

Archive: //www.freelists.org/archives/gmpi
Email gmpi-request@xxxxxxxxxxxxx w/ subject "unsubscribe" to unsubscribe


--------------------------------------------------------------------
mail2web - Check your email from the web at
http://mail2web.com/ .



----------------------------------------------------------------------
Generalized Music Plugin Interface (GMPI) public discussion list
Participation in this list is contingent upon your abiding by the
following rules:  Please stay on topic.  You are responsible for your own
words.  Please respect your fellow subscribers.  Please do not
redistribute anyone else's words without their permission.

Archive: //www.freelists.org/archives/gmpi
Email gmpi-request@xxxxxxxxxxxxx w/ subject "unsubscribe" to unsubscribe

Other related posts: