Opened 15 years ago
Closed 4 years ago
#320 closed task (duplicate)
factory for std::vector
| Reported by: | 12345678 | Owned by: | |
|---|---|---|---|
| Priority: | major | Milestone: | GEOS Fund Me |
| Component: | Default | Version: | 3.2.0 |
| Severity: | Unassigned | Keywords: | |
| Cc: |
Description
I am using in geos DLL. create collections, for example: createMultiPolygon, demand a std::vector<Geometry*> but there is no creator factory for create the std::vector !
Change History (5)
comment:1 by , 15 years ago
| Version: | 3.0.3 → 3.2.0 |
|---|
comment:2 by , 14 years ago
comment:3 by , 13 years ago
| Milestone: | → GEOS Future |
|---|
Note:
See TracTickets
for help on using tickets.

I confirm this is potentially an issue in cases where a factory functions take ownership of passed collection. For example:
class GEOS_DLL GeometryFactory { public: MultiLineString* createMultiLineString(std::vector<Geometry *> *newLines) const; };If client will allocate the newLines in EXE/DLL module and pass it to GEOS DLL module which later will deallocate it, then memory is allocated/deallocated across module boundaries what may lead to problems.
A factory for those containers would be useful indeed.