I'm refactoring some constantly hit code... migrating some multi- 
object selects to a VIEW in sql  + rose class -- and

The plan is such:
        migrate some multi-table conditional joins into views, with  
VIEW__##NAME## Rose DB classes
        cache the views into memcached, using storable or json.  ( leaning  
to json right now )

And so i run into this issue:

        myRoseClass::A
        myRoseClass::B

        becomes...

        myRoseClass::VIEW__a_b

        A and B both have a fair amount of functions defined within them for  
display.  i really don't want to duplicate them in VIEW__a_b.  so i'm  
looking at ways to handle the inheritance

        options:
                1)      have the view inherit from the original tables
                        VIEW__a_b
                                ISA( A, B)
                
                2)      migrate all the involved tables to have helper classes 
which  
contain the user defined functions, then inherit as needed
                        A
                                ISA ( A__helper )
                        B
                                ISA ( B__helper )
                        VIEW__a_b
                                ISA( A__helper, B__helper)

                3)      something else that is smarter than what I can come up 
with

anyone have a suggestion?
I need to maintain both the single classes and the view class under  
my setup -- the view is just offloading some complex querying onto  
postgres, not replacing everything the table is involved in.


                        
                




-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Rose-db-object mailing list
Rose-db-object@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rose-db-object

Reply via email to