PasteBpmElements

Syntax

PasteBpmElementsResult PasteBpmElements(BpmProcessId tBpmProcess, PasteBpmElementsArg tArg)

Parameters

tBpmProcess. Moniker of opened process.

tArg. Operation execution parameters.

Description

The PasteBpmElements operation pastes copied process elements.

Comments

To execute the operation, in the tBpmProcess field specify moniker of opened process and in the tArg.pasteAfterGuid field specify the element GUID, after which the copied elements are pasted. The moniker can be obtained after executing the OpenBpmProcess operation. Process elements are pasted from the special clipboard created on executing the CopyBpmElements operation.

The operation results in the information about pasted process elements.

Example

Below is the example of pasting the copied process stage. The request contains moniker of opened process and the stage GUID, after which the copied step is pasted. The response contains GUIDs of the new pasted stage and its steps.

SOAP request:

<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
<s:Body xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<PasteBpmElements xmlns="http://www.fsight.ru/PP.SOM.Som">
<tBpmProcess xmlns="">
  <id>KCHABFCBDFJFGOAELPKPBKMKIBIKDJHEFJONMMECLKLENNNJ!M!S!BPNGCBIPCBDFJFGOAELOCFACOLAGMIODCEKIOLGAPMGDNOCEBA</id>
  </tBpmProcess>
<tArg xmlns="">
  <pasteAfterGuid>{103D9D40-1C9F-4184-990E-7DB11E5C561A}</pasteAfterGuid>
  </tArg>
  </PasteBpmElements>
  </s:Body>
  </s:Envelope>

SOAP response:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<PasteBpmElementsResult xmlns="http://www.fsight.ru/PP.SOM.Som" xmlns:q1="http://www.fsight.ru/PP.SOM.Som" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<stages xmlns="">
<it>
  <guid>{3FED5D0F-5203-49A0-9FD0-1C52AC025D1D}</guid>
<stGroups>
<it>
  <guid>{EABD387D-2D96-4DB4-973D-4C6F4CCD3370}</guid>
<steps>
  <it>{12921D87-2242-428C-8AF8-5B865E806EF7}</it>
  <it>{F9814460-F8DF-4E59-8E31-AFD192A23449}</it>
  </steps>
  </it>
  </stGroups>
  </it>
  </stages>
  </PasteBpmElementsResult>
  </soapenv:Body>
  </soapenv:Envelope>

JSON request:

{
"PasteBpmElements" :
{
"tBpmProcess" :
{
"id" : "KCHABFCBDFJFGOAELPKPBKMKIBIKDJHEFJONMMECLKLENNNJ!M!S!BPNGCBIPCBDFJFGOAELOCFACOLAGMIODCEKIOLGAPMGDNOCEBA"
},
"tArg" :
{
"pasteAfterGuid" : "{103D9D40-1C9F-4184-990E-7DB11E5C561A}"
}
}
}

JSON response:

{
"PasteBpmElementsResult" :
{
"stages" :
{
"it" :
{
"guid" : "{3FED5D0F-5203-49A0-9FD0-1C52AC025D1D}",
"stGroups" :
{
"it" :
{
"guid" : "{EABD387D-2D96-4DB4-973D-4C6F4CCD3370}",
"steps" :
{
"it" :
[
"{12921D87-2242-428C-8AF8-5B865E806EF7}",
"{F9814460-F8DF-4E59-8E31-AFD192A23449}"
]
}
}
}
}
}
}
}
public static PasteBpmElementsResult PasteBpmElements(string moniker, string elGUIDDestination)
{
var somClient = new SomPortTypeClient(); // Proxy object for operation execution
// Operation execution parameters
var tPaste = new PasteBpmElements()
{
tArg = new PasteBpmElementsArg()
{
pasteAfterGuid = elGUIDDestination
},
// Create object moniker
tBpmProcess = new BpmProcessId() { id = moniker },
};
// Paste copied process element
var result = somClient.PasteBpmElements(tPaste);
return result;
}

See also:

Working with Processes