mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
* General PdmObjectMethods for scripting.
This commit is contained in:
@@ -19,9 +19,9 @@
|
||||
#include "RifcCommandFileReader.h"
|
||||
|
||||
#include "RicfCommandObject.h"
|
||||
#include "RicfObjectCapability.h"
|
||||
|
||||
#include "cafPdmObjectFactory.h"
|
||||
#include "cafPdmObjectScriptability.h"
|
||||
#include "cafPdmScriptIOMessages.h"
|
||||
|
||||
#include <QTextStream>
|
||||
@@ -127,7 +127,7 @@ std::vector<RicfCommandObject*> RicfCommandFileReader::readCommands( QTextStream
|
||||
else
|
||||
{
|
||||
readCommands.push_back( cObj );
|
||||
auto rcfCap = cObj->capability<RicfObjectCapability>();
|
||||
auto rcfCap = cObj->capability<caf::PdmObjectScriptability>();
|
||||
errorMessageContainer->currentCommand = commandName;
|
||||
rcfCap->readFields( inputStream, objectFactory, errorMessageContainer );
|
||||
errorMessageContainer->currentCommand = "";
|
||||
@@ -144,7 +144,7 @@ void RicfCommandFileReader::writeCommands( QTextStream& outputStream, const std:
|
||||
{
|
||||
for ( const auto& cmdObj : commandsToWrite )
|
||||
{
|
||||
auto rcfCap = cmdObj->capability<RicfObjectCapability>();
|
||||
auto rcfCap = cmdObj->capability<caf::PdmObjectScriptability>();
|
||||
if ( !rcfCap ) continue;
|
||||
|
||||
outputStream << cmdObj->classKeyword();
|
||||
|
||||
Reference in New Issue
Block a user