Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  Deletes a version of an edmModel identified by the model version name.
Header:
#include "sdai.h"
Prototype:
EdmiError

Code Block
languagecpp
themeConfluence
EdmiError edmiRemoteDeleteModelVersion(SdaiServerContext

...

 serverContextId,
                                         SdaiString        repositoryName, 
                                         SdaiString        modelName, 
                                         SdaiString        modelVersionName, 
                                         SdaiInvocationId  *edmiInvocationId); 

Deletes a version of an edmModel identified by the model version name.

Arguments

...

TypeNameComment
 SdaiServerContext

serverContextId

Context identification, from edmiDefineServerContext

 SdaiString

repositoryName

The name of the edmRepository that contains the edmModel for which a version is to be deleted in the remote _EDMdatabase{_}remote  EDMdatabase. Repository names are case sensitive.

 SdaiString

modelName

The name of the edmModel for which a version is to be deleted. Model names are case sensitive.

 SdaiString

modelVersionName

The name of the model version to delete. This is the name that was assigned to the model version when it was created.

 SdaiInvocationId

edmiInvocationId

Currently not used.

...

Return Value

...

Insert excerpt
US:_r_EDMInterface
US:_r_EDMInterface
nopaneltrue

 

Options

...

  

OptionComment
Option nameComment

 

Example

...

 

Code Block
languagecpp
 EdmiError rstat;
 SdaiInteger nWrn, nErr;
 SdaiModelVersion modelVersionId;
 SdaiInstance instId;
 SdaiServerContext myContext;
  
 /* Define Remote Server Context */
 rstat = edmiDefineServerContext("MyRemoteServerContext",

...


 "Johnny", "Supervisor", "cf37ftr",

...

 
 "TCP", "9090", "MyServerHost",

...

 
 NULL, NULL, NULL, NULL, NULL, &myContext);

...

 
  
 /* Compile schema */

...


 rstat = edmiRemoteDefineSchema(myContext, EXPRESS_SCHEMA_TYPE,

...


 "c:/data/MyFile.exp", "c:/tmp/MyFile.dia", "MySchema",

...

 
 DELETING_EXISTING_SCHEMAS | STORING_SOURCE,

...

 
 &nWrn, &nErr, NULL);

...

 
  
 /* Create Model */

...


 rstat = edmiRemoteCreateModel(myContext,

...


 "MyRepository", "MyModel", "MySchema",

...

  
 USE_DEFAULT_OPTIONS, NULL);

...

 
  
 /* Populate Model */

...


 rstat = edmiRemoteCreateInstanceAndPutAttrsBN(myContext,

...


 "MyRepository", "MyModel", "MyEntity", 1, &instId, NULL,

...

 
 "REAL_ATTR", sdaiREAL, 3.14);

...

 
  
 /* Create version 1 */

...


 rstat = edmiRemoteCreateModelVersion(myContext,

...


 "MyRepository", "MyModel", "V1", &modelVersionId, NULL);

...

 
  
 /* Change population */

...


 rstat = edmiRemotePutAttrsBN(myContext, instId, 1, NULL,

...


 "REAL_ATTR", sdaiINTEGER, 1);

...

 
  
 /* Create version 2. Named 'version2' by default. */

...


 rstat = edmiRemoteCreateModelVersion(myContext,

...


 "MyRepository", "MyModel", NULL, &modelVersionId, NULL);

...

 
  
 /* Roll back to version 1 */

...


 rstat = edmiRollbackModelBN("MyRepository", "MyModel", "V1",

...


 KEEP_ALL_MODEL_VERSIONS);

...

 
  
 /* Delete version 2 */

...


 rstat = edmiRemoteDeleteModelVersion(myContext,

...


 "MyRepository", "MyModel", "version2", NULL);

...

 
 . . .

 

See also

Filter by label (Content by label)
showLabelsfalse
showSpacefalse
cqllabel = "model" and parent = "6062220"