Discussion:
Tags
Franz Philipp Moser
2005-11-28 05:39:18 UTC
Permalink
Hi list,

because I want some tag implementation, I'd like to introduce my view as
UML. OK, ok I'm reading and learning UML, so I tried it for this "small"
Project. I think it captures the design very good. Any suggestions?

The * relations can be seen as collections, the 1:1 relations as object,
the relation with a closed not colored arrow is an _extend and the open
arrow meens that the 1:1 (or *) relation is not bidirectional (so no
arrow on both sides of the relation is bidirectional).

for example:
type.properties of TagMembership
##
## object references
##
taggedstory = object(Story)
taggedstory.local = TAGMEMBERSHIP_F_STORY
taggedstory.foreign = STORY_ID

taggedimage = object(Image)
taggedimage.local = TAGMEMBERSHIP_F_IMAGE
taggedimage.foreign = IMAGE_ID

taggedfiles = object(File)
taggedfiles.local = TAGMEMBERSHIP_F_FILE
taggedfiles.foreign = FILE_ID

creator = object(User)
creator.local = TAGMEMBERSHIP_F_USER_CREATOR
creator.foreign = USER_ID

tag = object(Tag)
tag.local = TAGMEMBERSHIP_F_TAG
tag.foreign = TAG_ID

##
## primitive properties
##
createtime = TAGMEMBERSHIP_CREATETIME

and the Story prototype:
_extends = Content

##
## object references
##
tags = collection(TagMembership)
tags.local = STORY_ID
tags.foreign = TAGMEMBERSHIP_F_STORY


Hope thats not to complicated :)

cu Philipp
--
XML is the ASCII for the new millenium
(Cocoon Documentation)
Loading...