Skip to content

Implement "copy" methods for individual components #680

Open
@carldlaird

Description

@carldlaird

Pyomo should have functions that can create a copy of a component. There are many transformations that do this manually (create a new component and copy the necessary "flags" over). This is error prone where individual developers may forget to copy a particular flag (e.g., active, mutable), or lead to broken code if (when) we add a new attribute to a particular component. These methods should also work with component data objects (i.e., be able to create a scalar version of an element from an indexed component).

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions