3

At the current point of time, I am modeling the project and I have a really serious question: how to describe the structure of the file(archive)?

What I mean: in this project, we will have our custom file extension, let's call it "anlib", it will be a rar archive with a pre-defined structure like jar.

But how to describe it in UML? Neither component diagram nor deployment diagram support aggregation or composition.

Roman Roman
  • 617
  • 1
  • 9
  • 16

1 Answers1

1

UML diagram describe the system structure (components, classes) and its behaviors (interactions, activities, states). UML doesn't represent files or other system resources. But you can represent these indirectly:

  • a class that represents the data that is contained by such a file (class diagram)
  • a class that acts as proxy for a certain category of files and that can manage such files (class diagram)
  • an object that instantiates an existing file as a file stream class (e.g. lifeline on a sequence diagram)

If the file is part of the system configuration and needs to be deployed to make the system usable, then you can represent it as an artifact in a deployment diagram

Christophe
  • 68,716
  • 7
  • 72
  • 138