Skip to content

Should ViewSet::getViews() return ModelView instead of View? #207

@chrikoch

Description

@chrikoch

Question

I wonder why getViews() in https://github.com/structurizr/java/blob/master/structurizr-core/src/com/structurizr/view/ViewSet.java#L527 returns a collection of "View" instead of "ModelView".

I have a kotlin script run via structrizr-cli and want to get all elements included in a view. But getElements() is only defined on ModelView, not on View. So I can't get the elements of a view :-(

As far as I understand the code, all Elements returned by getViews() are ModelViews, so I suggest to return Collection

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions