473,654 Members | 3,129 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

is PetShop 2.0 Anti pattern?

Hi,

I was seeing code of PetShop 2.0 and find is quite .. differnet design
and architecture ..

too much of clutter in classes .. order class using and Iorder and
Iorder using an orderInfo and same for product, is this good design
...is it MS design principles?

I just learning the nacks of application designing and architecture and
i dont know how should be my thinking process ..should i think in
Classes/object or what way.. ?

by the way i have joined these formums just few days back ..and i say
its simply superb you all experts out there trying to help people like
us.. SALUTES.
Comments Please

Aug 31 '06 #1
3 1558
a large group of developers (especially the test first design) believe in
interface design, and that only interfaces should be used. Interfaces define
contracts, and classes implement contracts in this design model.

-- bruce (sqlwork.com)
"pratham" <pr************ @gmail.comwrote in message
news:11******** *************@i 3g2000cwc.googl egroups.com...
Hi,

I was seeing code of PetShop 2.0 and find is quite .. differnet design
and architecture ..

too much of clutter in classes .. order class using and Iorder and
Iorder using an orderInfo and same for product, is this good design
..is it MS design principles?

I just learning the nacks of application designing and architecture and
i dont know how should be my thinking process ..should i think in
Classes/object or what way.. ?

by the way i have joined these formums just few days back ..and i say
its simply superb you all experts out there trying to help people like
us.. SALUTES.
Comments Please

Aug 31 '06 #2
I have read this line many times " Interface define Contracts" what
does this mean technically, can please explain me with an example, also
i want to know whether having interfaces for all your classes is good
idea?

Thanks in advance
bruce barker (sqlwork.com) wrote:
a large group of developers (especially the test first design) believe in
interface design, and that only interfaces should be used. Interfaces define
contracts, and classes implement contracts in this design model.

-- bruce (sqlwork.com)
"pratham" <pr************ @gmail.comwrote in message
news:11******** *************@i 3g2000cwc.googl egroups.com...
Hi,

I was seeing code of PetShop 2.0 and find is quite .. differnet design
and architecture ..

too much of clutter in classes .. order class using and Iorder and
Iorder using an orderInfo and same for product, is this good design
..is it MS design principles?

I just learning the nacks of application designing and architecture and
i dont know how should be my thinking process ..should i think in
Classes/object or what way.. ?

by the way i have joined these formums just few days back ..and i say
its simply superb you all experts out there trying to help people like
us.. SALUTES.
Comments Please
Sep 3 '06 #3
Interfaces define contracts of service.
Interfaces do not define implementation details.

The specification of the contract of a component includes the
input/output behavior, invariance and dependencies to other components.

Architecturally , interfaces encapsulate nodes and provide clear access points.
A component or a service is visible exclusively through its interface.

If your class doesn't include a component or a service,
i.e., if its properties and/or methods can be called directly, it doesn't need an interface.

See :
http://discuss.develop.com/archives/...&F=&S=&P=93506
and :
http://scholar.lib.vt.edu/theses/ava...ontracts%22%22

Juan T. Llibre, asp.net MVP
aspnetfaq.com : http://www.aspnetfaq.com/
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
=============== =============== =====
"pratham" <pr************ @gmail.comwrote in message
news:11******** *************@m 79g2000cwm.goog legroups.com...
>I have read this line many times " Interface define Contracts" what
does this mean technically, can please explain me with an example, also
i want to know whether having interfaces for all your classes is good
idea?

Thanks in advance
bruce barker (sqlwork.com) wrote:
>a large group of developers (especially the test first design) believe in
interface design, and that only interfaces should be used. Interfaces define
contracts, and classes implement contracts in this design model.

-- bruce (sqlwork.com)
"pratham" <pr************ @gmail.comwrote in message
news:11******* **************@ i3g2000cwc.goog legroups.com...
Hi,

I was seeing code of PetShop 2.0 and find is quite .. differnet design
and architecture ..

too much of clutter in classes .. order class using and Iorder and
Iorder using an orderInfo and same for product, is this good design
..is it MS design principles?

I just learning the nacks of application designing and architecture and
i dont know how should be my thinking process ..should i think in
Classes/object or what way.. ?

by the way i have joined these formums just few days back ..and i say
its simply superb you all experts out there trying to help people like
us.. SALUTES.
Comments Please


Sep 3 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
1210
by: Roy Peng | last post by:
Hi All, After the installation of PetShop 3.0, every time my machine reboots, Windows Explorer runs "C:\Program Files\Microsoft\". Any ideas? I checked \Startup, \\SOFTWARE\Microsoft\Windows\CurrentVersion\Run, etc. but found nothing with it... Did I miss anything?
2
2903
by: Magesh | last post by:
Is it not possible to install PetShop 3.0 without having either SqlServer or Oracle in the local machine or a remote machine?? Cant i bypass the database installation part while installing PetShop??
1
4900
by: eAW | last post by:
Is there any forum for Microsoft .NET Petshop sample? I have problems running the v 3.1 sample downloaded from Microsoft. The error message is: Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.UnauthorizedAccessException: Access to the
0
1049
by: Mas Jabier | last post by:
Warnar, I cannot see your images attached. You should verify these procedures first : - Check your database server, has mspetshop db already installed ?. If not, then this is your db issue. - You may have to uninstalled the previous version first,and then reinstall the newest version.
0
1314
by: Marco Mendonça | last post by:
Hi, I've noticed that in the ASP.NET PetShop Sample, there are 2 WebServers running IIS in LoadBalancing. The presented architecture requires 2 ISA Servers, one for each WebServer running IIS. Is it necessary to have 2 ISA Servers? Why not just 1 ISA Server for the 2 WebServers in LoadBalancing? If we have the configuration with 2 ISA Servers, can we have just 1 EntryPoint for the application (PetShop Sample)?
16
1800
by: lisa.engblom | last post by:
I have two semi related questions... First, I am trying to output a list of strings to a csv file using the csv module. The output file separates each letter of the string with a comma and then puts each string on a separate line. So the code is: import csv output = csv.writer(open('/Python25/working/output.csv', 'a')) a = for elem in range(len(a)):
0
898
by: shishir | last post by:
Hi, Am trying to expose the order submission in petshop as a WCF service.I have all required service running on the server side too but the problem is whenever i try to call the order service from client side it goes to the server side identifies the correct order method n while trying to get an instance of BLL order it throws an error stating "The type initializer for 'PetShop.BLL.Order' threw an exception." and the inner exception is...
0
1201
by: shishir | last post by:
Hi, Am trying to expose the order submission in petshop as a WCF service.I have all required service running on the server side too but the problem is whenever i try to call the order service from client side it goes to the server side identifies the correct order method n while trying to get an instance of BLL order it throws an error stating "The type initializer for 'PetShop.BLL.Order' threw an exception." and the inner exception is...
0
1256
by: shishirdk | last post by:
Hi, Am trying to expose the order submission in petshop as a WCF service.I have all required service running on the server side too but the problem is whenever i try to call the order service from client side it goes to the server side identifies the correct order method n while trying to get an instance of BLL order in my serviceclass it throws an error stating "The type initializer for 'PetShop.BLL.Order' threw an exception." and the inner...
0
8372
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8706
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8475
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8591
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7304
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6160
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5621
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
2709
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1592
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.