3 Replies - 507 Views - Last Post: 03 November 2009 - 07:48 AM Rate Topic: -----

#1 Coodle  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 2
  • Joined: 03-November 09

Design problems, Help!

Posted 03 November 2009 - 06:44 AM

Hey there,

I'm taking a C++ class and got a two staged assignment to hand in soon. I'mhaving troubles
with it and was wondering if anybody could lend me a hand?
We are to design and implement a web forum in C++. It is supposed to be a stand-alone
application, meaning no CGI, no browser, no client-server... the emphasis is on its functionality.

Now... we first got to hand in a design, as complete as possible. That's the point I'm struggling
with - I just don't have enough experience in object oriented design. My background is more
procedural.

Specs

The user interface will be console driven, data is to be stored in files through serialization. There
are to be different types of users(visitor,member,moderator,administrator); they can send
private messages to each other and create/edit threads and posts.


Components/Classes


Anyway, I identified 4 "components" of the program; each should be implementable by itself:

1) User Interface
2) Functionality
3) Data management
4) Persistence/Serialization

I can't really think of any class names there.. any suggestions?
I also attached a class diagram (far from being complete) ... should I split the classes any
further? The functionality class seems to grow and grow ...

How should I organise the classes? What class is part of what? Is the data management
#included in the functionality and then instantiated as part of it?

Object management

I was thinking that all objects are instantiated in the data management; the functionality
classes and the user interface only work with references to them. Does that make sense?

Further, how should I organise the forum/thread/posts...? Tree like with parent/child pointers?
Composition/Aggregation (cant remember the difference, duh); "a thread is part of a forum"?


HELP guys! I just don't have anybody to ask these things, our professor is an idiot who can't
speak proper english, and my classmates are still struggling with concepts and syntax ... and the assignments themself isquite demanding I find.

Thanks a lot in advance! :)

Flo

Attached image(s)

  • Attached Image


Is This A Good Question/Topic? 0
  • +

Replies To: Design problems, Help!

#2 JackOfAllTrades  Icon User is offline

  • Saucy!
  • member icon

Reputation: 6058
  • View blog
  • Posts: 23,496
  • Joined: 23-August 08

Re: Design problems, Help!

Posted 03 November 2009 - 07:14 AM

Quote

We are to design and implement a web forum in C++. It is supposed to be a stand-alone
application, meaning no CGI, no browser, no client-server

Well, that there doesn't seem to make much sense. A web forum as a standalone app? Holy oxymoron, Batman!
Was This Post Helpful? 0
  • +
  • -

#3 Coodle  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 2
  • Joined: 03-November 09

Re: Design problems, Help!

Posted 03 November 2009 - 07:28 AM

Erm, yea.. I can't help it. I do what I'm being told to...
Was This Post Helpful? 0
  • +
  • -

#4 KYA  Icon User is offline

  • g++ jameson.cpp -o beverage
  • member icon

Reputation: 3101
  • View blog
  • Posts: 19,141
  • Joined: 14-September 07

Re: Design problems, Help!

Posted 03 November 2009 - 07:48 AM

This assignment isn't really about the web forum, it seems to be more of an exercise to get you to think about design with data structures.


Objects:
User
Post
Thread
Forum Section

Each has a various amount of data, etc...

All of which could be done rudimentary with Linked Lists, but you could get fancier, queues or a stack depending on how you define the timestamp on each thread/post and sort accordingly.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1