if you look at the last line of code you wrote, the word Factory suggests he is using software factories. Software factories is a bit vague as you can use different patterns to implement it, i,e Abstract Pattern. If you want to learn more than download the
Microsoft .NET PetShop application and see how its software factories are implemented.
I started using ClickOnce in my project last month.. I used the dynamic updates from code..
#1. No way to get the list of latest modules..
I was tying to implement the Firefox-Plugin auto-update style in my application.. I wanted to show the list of updated modules that suppose to be downloaded. Unfortunately, there is no way to get the list of updated modules through code....
#2. The version of the whole application need to be updated if we wanna update just one module
It's really suck about ClickOnce... If we wanna update just one module, we will need to change the version of application (e.g. "shell.application" ) and the version of manifest (shell.manifest)... i dont really like that thing..
#3. ClickOnce doesn't care about the version of assemblies.
I don't understand why ClickOnce doesn't care about the version of assemblies. What it cares about the version of *.application, the verison of manifest and the file hash of each assemblies... I dont think that it's is very good idea...
#4. DownloadFileGroup ("") works only if "optional" is checked. There is no way to download the group of file by force
Why "optional" need to be checked in order to make DownloadFileGroup work..... What I wanna do is that I wanna the application ( all file groups) to be downloaded at the first time.. later, I wanna download a particular group of files by force.. if I can download the group of file by force, I don't need to change the version of the whole file for updating new module..
I have a mind to create a plug-in based application. This type of architecture seems appropriate to my current project as it would make the application extensible so that new functionality can be added simply by distributing new plug-ins.
One question that keeps popping to the front of my mind, however, is how to enable inter-communication between various seperate, but related, plug-ins (for instance, Customer information might be useful to more than one plug-in). Has anyone got any links to any resources that describe known (and presumably successful / recommended) methods for achieving such a thing?
Me: Can you see the "up" arrow?
Me: Can you see an arrow that points upwards?
User: Oh yes, I see it now!
-Excerpt from a support call taken by me, 08/31/2007
I'm looking at creating a CSV (or, in general, delimited) file compare tool. Using an everyday diff tool is OK, but I would like to get results in terms of columns, i.e. I want to highlight columns added or delete, and just make the user experience a little better for the testers for a mammoth test project I'm embarking on. Where can I find out more about compare algorithms?
It hasn't been, due to other month-end pressures at work, but I've just found a wikipedia article on the algorithm used by diff. It's based on the Longest Common Sequence problem, but it's now 03:40, and it's a little difficult to understand.
I wasn't sure whether to post this in ASP.NET or Design and Architecture forum, but decided to land it here after all as I believe the same would apply to a WinForms app or even a web service.
I am working on an ASP.NET 2.0 project, this is my first attempt at a real multi tier architecture, before I was just binding a DataSet to my WebForms directly. I have a DAL, a BLL and an UI. All is fine, they work well together, but I came to the point where I need to display some reports in a GridView and my grasp of business layer started to fall apart.
Look, the project is about embeddable web widgets, every widget belongs to some user. I have (among others) some classes in BLL (they communicate with DAL for CRUD and other database operations, BLL does not know anything about the database):
1. WidgetsBLL - this class 'manages' Widgets. You can create new widgets here, retrieve all widgets, retrieve widgets belonging to a particular user, etc.
2. Widget - this class represents a particular widget. It knows the widget's URL, clickthru count, theme and so on.
3. UsersBLL - same as WidgetsBLL, just deals with Users.
4. User - represents a user, stores data such as first & last name, e-mail address, etc.
It all worked great so far, but now I came to the point where I must display combined data in a GridView. I need data from Widget class (such as widget's ID, name and clickthru count) as well as owner's data from User class (first & last name, e-mail). Now, this data cannot be retrieved from a single class as you can see. I need to get a Widget instance, then get a User instance and display a list of rows which are built from those two classes, so the GridView needs columns such as:
I am not sure what one should do to solve such problem, I don't have experience with this kind of architecture. I might just create a new class (WidgetStats?) - this seems like the easiest approach, but somehow it looks like bad design to me, because widget statistics is not a real object - it looks kind of artificial, doesn't it?
What is the best way to return an object composed of other objects? I began by calling WidgetsBLL.GetWidgets() and binding the result to the GridView. Then I can have TemplateFields and retrieve for example user's e-mail. But what about sorting in this scenario?!
Please, help. I have been trying to work this out for two days.
but now I came to the point where I must display combined data in a GridView. I need data from Widget class
If I understand your post correctly a "widget" is a presentation object or "view" object, therefore other views are never going to "get data" from it. The GridView is another presentation object so it would get all it's data through the back end services ( business, session, database ).
Pawel Krakowiak wrote:
this is my first attempt at a real multi tier architecture
Pawel Krakowiak wrote:
I don't have experience with this kind of architecture.
That's not architecture it's software design. You are designing your business logic and views that all execute in the middle tier. You are not creating tiers you are designing.
If I understand your post correctly a "widget" is a presentation object or "view" object
Not exactly, it is a domain object which represents data from the database and allows the user to modify that data - such as giving it a name, assigning a URL to it, choosing a theme, etc. The user control which renders this is another subject.
I need to display GridView rows composed of some fields from Widget class and some fields from User (widget's owner) class. I am wondering whether I shouldn't just create a WidgetStatistics class which would have 1 property of type Widget and 1 property of type User and just bind my grid to that. I don't know if it's a good idea, definitely easier.
If the user interacts with it, it is a presentation object.
Class user, not application user. I guess I can't express my problem better.
How it works in code is like this:
WidgetsBLL widgetsLogic = new WidgetsBLL();
Widget widget = widgetsLogic.GetWidgetById(13);
Now you can access various fields of the widget:
And so on. You also have a User class, which has properties such as FirstName, LastName, etc.
I need to present combined data, so in one row we have WidgetId but also user's FirstName - as you can see this data belongs to two different classes. I am not sure whether to design a third class and include both Widget and User by composition or to do something else. That is my problem I tried to describe.
It seems to me you should be binding your datagrid to
Widget.WidgetId | Widget.WidgetName | Widget.Owner.LastName | Widget.Owner.Email
This is a fairly important distinction - the example you gave doesnt appear to take advantage of the relationship between Widgets and Users. You might not want your BLL to know about the exact FK relationship in the database, but the fact that Widgets have an Owner is part of your domain, and there is no escaping that.
How you implement these properties on the Widget class is up to you.
You might also want to consider using a tool that handles the database mapping for you. My company (linked in my signature) provides such a product, which is free for non-commercial use.