StrataFrame Forum
Home      Members   Calendar   Who's On
Welcome Guest ( Login | Register )
      



Loading Selective BO in a WebsiteExpand / Collapse
Author
Message
Posted 10/31/2006 7:26:04 PM
StrataFrame Beginner

StrataFrame BeginnerStrataFrame BeginnerStrataFrame BeginnerStrataFrame BeginnerStrataFrame BeginnerStrataFrame BeginnerStrataFrame BeginnerStrataFrame Beginner

Group: Forum Members
Last Login: 11/19/2007 4:06:18 AM
Posts: 41, Visits: 99
Lets say i have 10 Business Objects which i declare in ApplicationBasePage and then i inherit all my pages from ApplicationBasePage, so on load of all pages are ALL the 10 Business Objects loaded & populated or only the selective ones are loaded ?

Basically, on a Item Details page i would not like to load the CustomerBO to have less amount of processing.

Request you to please elobarate a bit on this concept and clarify my concern.

Post #4020
Posted 10/31/2006 10:06:44 PM


StrataFrame Developer

StrataFrame Developer

Group: StrataFrame Developers
Last Login: Today @ 10:13:07 AM
Posts: 4,799, Visits: 4,768
All of the BOs declared in the ApplicationBasePage would be available on any page that inherits this.  But inheriting this page does not add any additional overhead.  These business objects are loaded into session variables when the session is started.  So this would be nothing more than an object reference if nothing is done on the page.

But if you do not like this approach, you can create another base page and have only those business object which you wish to have available.  You can have as many base pages as you would like.

Post #4024
Posted 11/01/2006 3:02:38 AM
StrataFrame Beginner

StrataFrame BeginnerStrataFrame BeginnerStrataFrame BeginnerStrataFrame BeginnerStrataFrame BeginnerStrataFrame BeginnerStrataFrame BeginnerStrataFrame Beginner

Group: Forum Members
Last Login: 11/19/2007 4:06:18 AM
Posts: 41, Visits: 99
Hello Trent,

I have another small problem, i have a base class which i use for all my pages in all the projects and have implemented authentication and many more useful functions. now, my base class is very generic and is not modified specifically for any project whereas the SF ApplicationBasePage needs to be modified for each project.

I want best of both the worlds and want to use my base page & SF base page as well. The best way i can think of is inherit my base class from MicroFour.StrataFrame.UI.Web.BasePage and inherit my SF ApplicationBase Page from my base class. Do you foresee any issues with this approach, for the deployment perspective, do i just need to put the StrataFrame Base.dll or any more SF Dlls in the bin folder ?

Thanks in advance

Vikram.

Post #4025
Posted 11/01/2006 7:42:06 AM


StrataFrame Developer

StrataFrame Developer

Group: StrataFrame Developers
Last Login: Today @ 10:13:07 AM
Posts: 4,799, Visits: 4,768
Your approach for your base class should work just fine.  One option that we use from time to time is a shared class in cases that we need to re-use code from several locations and subclassing is not really an option.  In your case you can subclass, but just to show you another option, you can create a shared class that never requires an instance to be created and you can call directly anytime:

Public Notinheritable Class MySharedClass

'-- Prevent the class from being instantiated
Private Sub New()
End Sub

'-- A shared sub
Public Shared Sub MySharedMethod()
    '-- Do whatever you need to do
End SUb

'-- A shared function
Public Shared Function MySharedFunction() As Boolean
    '-- Do some stuff
    Return True
End Sub

End Class

As for the DLLs required, you will need the following:

MicroFour StrataFrame Base.DLL
MicroFour StrataFrame Business.DLL
MicroFour StrataFrame UI.DLL

and if you are using security you will need:

MicroFour StrataFrame Security.DLL

Post #4026
« Prev Topic | Next Topic »


Reading This TopicExpand / Collapse
Active Users: 0 (0 guests, 0 members, 0 anonymous members)
No members currently viewing this topic.
Forum Moderators: Ben Chase, Trent L. Taylor, Steve L. Taylor

PermissionsExpand / Collapse

All times are GMT -6:00, Time now is 12:51pm

Powered by InstantForum.NET v4.1.4 © 2008
Execution: 0.125. 12 queries. Compression Enabled.
Site Map - Home - My Account - Forum - About Us - Contact Us - Try It - Buy It

Microsoft, Visual Studio, and the Visual Studio logo are trademarks or registered trademarks of Microsoft Corporation in the United States and/or other countries.