Migrating FAQ


Frequently asked questions about - migrating code to MicroStation CONNECT.

 

Migrating Code

The following information (paths) are provided to help navigate essential migration resources available and help ensure migrating your custom applications/code to the latest software versions and platforms can be most productive. It is recommended to take the time to follow the information provided in the order presented for topics most relevant to your individual needs and ensure best results.

Users and Admins having Custom MDL Applications and No Programmers

New to the MicroStation SDK and Programmer Resources

Developers and Programming:

Previous Custom MDL Application Developers Migrating to CONNECT (Choosing a Migration Strategy)

Creating New Code Projects?

Migrating MDL Code directly as a "1:1" Migration Project?

  • Migrating to CONNECT (Migration Overview providing additional/subsequent migration steps that may be necessary)

  • MicroStation CONNECT Migration Workshop Materials (Provided in the SDK, or [[Download]])
    • Suggested materials to review under; ..\Documentation\Migration

      • Readme.txt (Resources to understand: existing application impacts, new product and API changes)

    • Suggested materials to review under; Workshop\Docs

      • MicroStationCONNECT_MigrationWorkshop.pptx (Architectural and Migration Topics Overview)
      • MigrationProcessOverview.pdf (Migration process, code evaluation and prioritization)
      • Resources to get up and running with Bentley Communities.pdf (Programming Resources) 

    • Suggested materials to review under; Using MicroStation x64 Beta 1 MDL SDK:

      • Using MicroStation x64 Beta 1 MDL SDK-v2.pdf (Migration of MyApp example)
Raster

General Recommendations

Code that relied on the prior (index-based handles) MDL C Container API (mdlCntr); wrt: List, Map and Multimaps; where appropriate can upgrade code to use native C++ std library list and map functionality.
Code specific to the mdlRaster API use of mdlCntr should consider:

  1. Upgrade code to use Raster C++ API classes and interfaces: DgnRaster*, Raster*, IRaster*
  2. Update your code ensuring:
    • Include: ..\include\RasterCore\RasterCoreAPI.h (includes: both DgnRaster.h and RasterCollection.h)
    • Add the namespace macro USING_NAMESPACE_RASTER (or using namespace Bentley::DgnPlatform::Raster;) to your .cpp files
    • Link ..\library\RasterCore.lib in your .mke files
  3. Upgrade mdlRaster API signatures accordingly to use:
    • mdlRaster_systemAllRasterContainerByModelGet  use DgnRasterVectorR
    • mdlRaster_fileFormat* use: RasterBlockTypeCollectionR, RasterColorModeCollectionR, RasterCompressionTypeCollectionR and RasterFileFormatCollectionR

Removed and Deprecated

Item Recommendation
mdlRaster_systemRasterContainerGet

Removed:
StatusInt mdlRaster_systemRasterContainerGet (DgnRasterVectorR collection);
Replacement:

ModelRefIterator modelItr (pRootModel, iteratorType, depth);

for (DgnModelRefP modelRefP = modelItr.GetFirst (); modelRefP; modelRefP = modelItr.GetNext ())
    {
    for each (DgnRasterP rasterP in DgnRasterCollection::GetRasters(modelRefP))
        {
        if (NULL != rasterP)
            //Do something;
        }
    }