Interface to a file?



This is a UML modeling question. Consider a component that accesses an
external file for some configuration data. Suppose it's simply an ASCII text
file with the data in some sort of format. So the component will open the
file and read the configuration data.

The question is how to model this situation.

What is actually that file? It doesn't seem to be an "object." It doesn't
have an interface of its own -- it just gets read.

Some colleagues are saying "the file's interface is its format." I see what
they're getting at - it's a bit like the schema for a database. But it still
doesn't seem right at all. On the other hand, the format of the file is
clearly a factor. Change the format and the calling component has to be
changed, so there's some kind of dependency there.

At deployment time, the file surely is an artifact. But at design time, what
is it? Since the component accesses it, one would tend to think there's an
association between component and file. But I tend to associate an
association with the ability to call an operation - but as I said, this
plain old ASCII file doesn't have operations, it just sits there and gets
read.

Any insights on how this is normally modeled?

Thanks,

John




.