Click or drag to resize

ApiSession Methods

The ApiSession type exposes the following members.

Methods
  NameDescription
Public methodBringObjectIntoView
Brings the given object into view
Public methodChangeAsset
Schedules an re-import of an asset from a new filename (Change asset source). The methods returns immediately. It just enqueues an job that is processing in the background. Use WaitForAssetProcessing(WaitForAssetProcessingArgs) when you need the job(s) to be completed before proceeding
Public methodClaimPartition(Guid)
Before making any changes to articy objects, your program needs to claim the partition the object in question resides in.
Public methodClaimPartition(SimplePartitionActionArgs)
Before making any changes to articy objects, the external program needs to claim the partition the object in question resides in.
Public methodClaimPartitions(IEnumerableObjectProxy)
Claims all distinct partitions required for the given list of objects.
Public methodClaimPartitions(IEnumerableObjectProxy, String)
Claims all distinct partitions required for the given list of objects.
Public methodClaimPartitions(IEnumerableObjectProxy, String, ListGuid, DictionaryGuid, Exception)
Claims all distinct partitions required for the given list of objects.
Public methodCloneChildren
Like CloneObject, but clones all children of aObject instead of just aObject. aObject itself is not cloned. Connections from a child to aObject are not cloned as they cannot necessarily be connected to aParent.
Public methodCloneObject
Creates a deep copy of the given object, i.e. all children of that object will be copied, too.
Public methodCloseProject
Closes the currently opened project.
Public methodConnectPins
Creates a connection between two pins. This function will throw an exception if the connection cannot be created, e.g. when the pins are on different hierarchy levels.
Public methodConnectToServer
Connects to an articy:server
Public methodConvertBitmapToBrush
Converts a drawing bitmap (e.g. resource) to a WPF brush. The given bitmap is disposed by this call
Public methodCreateBrushFromArray
Create a brush from an image stored in a byte array (PNG/JPG)
Public methodCreateBrushFromBitmap
Creates a WPF brush from a drawing bitmap (e.g. resource)
Public methodCreateBrushFromFile
Create a brush from an image file
Public methodCreateBrushFromStream
Create a brush from an image that can be access from a stream object
Public methodCreateComment
Creates a new comment/annotation object in the flow area.
Public methodCreateCondition(UInt64, String)
Creates a new condition node in the flow area.
Public methodCreateCondition(ObjectProxy, String)
Creates a new condition node in the flow area.
Public methodCreateCondition(UInt64, String, String)
Creates a new condition node in the flow area.
Public methodCreateCondition(ObjectProxy, String, String)
Creates a new condition node in the flow area.
Public methodCreateDialogue(UInt64, String)
Creates a new dialogue in the flow area.
Public methodCreateDialogue(ObjectProxy, String)
Creates a new dialogue in the flow area.
Public methodCreateDialogue(UInt64, String, String)
Creates a new dialogue in the flow area.
Public methodCreateDialogue(ObjectProxy, String, String)
Creates a new dialogue in the flow area.
Public methodCreateDialogueFragment(UInt64, String)
Creates a new dialogue fragment inside a dialog.
Public methodCreateDialogueFragment(ObjectProxy, String)
Creates a new dialogue fragment inside a dialog.
Public methodCreateDialogueFragment(UInt64, String, String)
Creates a new dialogue fragment inside a dialog.
Public methodCreateDialogueFragment(ObjectProxy, String, String)
Creates a new dialogue fragment inside a dialog.
Public methodCreateDocument(UInt64, String, String)
Creates a new Document object as child of the given parent
Public methodCreateDocument(ObjectProxy, String, String)
Creates a new Document object as child of the given parent
Public methodCreateDocumentDialogue(UInt64, HierarchyAdjustment, String, String, String)
Adds a new dialogue section to a document
Public methodCreateDocumentDialogue(ObjectProxy, HierarchyAdjustment, String, String, String)
Adds a new dialogue section to a document
Public methodCreateDocumentImage(UInt64, HierarchyAdjustment, UInt64, String, String)
Adds a new image section to a document
Public methodCreateDocumentImage(ObjectProxy, HierarchyAdjustment, ObjectProxy, String, String)
Adds a new image section to a document
Public methodCreateDocumentText(UInt64, HierarchyAdjustment, String, String, String)
Adds a new Text section to a document
Public methodCreateDocumentText(ObjectProxy, HierarchyAdjustment, String, String, String)
Adds a new Text section to a document
Public methodCreateEntity(UInt64, String)
Creates a new entity object in the articy project tree.
Public methodCreateEntity(ObjectProxy, String)
Creates a new entity object in the articy project tree.
Public methodCreateEntity(UInt64, String, String)
Creates a new entity object in the articy project tree.
Public methodCreateEntity(ObjectProxy, String, String)
Creates a new entity object in the articy project tree.
Public methodCreateFlowFragment(UInt64, String)
Creates a new flow fragment in the flow area.
Public methodCreateFlowFragment(ObjectProxy, String)
Creates a new flow fragment in the flow area.
Public methodCreateFlowFragment(UInt64, String, String)
Creates a new flow fragment in the flow area.
Public methodCreateFlowFragment(ObjectProxy, String, String)
Creates a new flow fragment in the flow area.
Public methodCreateFolder(UInt64, String)
Creates a new user folder within the articy project tree.
Public methodCreateFolder(ObjectProxy, String)
Creates a new user folder within the articy project tree.
Public methodCreateGlobalVariable(String, Boolean, String)
Creates a new boolean variable via a full qualified name. If the supplied namespace doesn't exist, it will be created.
Public methodCreateGlobalVariable(String, Int32, String)
Creates a new integer variable via a full qualified name. If the supplied namespace doesn't exist, it will be created.
Public methodCreateGlobalVariable(String, String, String)
Creates a new string variable via a full qualified name. If the supplied namespace doesn't exist, it will be created.
Public methodCreateGlobalVariable(String, Boolean, ObjectProxy, String)
Creates a new boolean variable via a full qualified name. If the supplied namespace doesn't exist, it will be created.
Public methodCreateGlobalVariable(String, Int32, ObjectProxy, String)
Creates a new integer variable via a full qualified name. If the supplied namespace doesn't exist, it will be created.
Public methodCreateGlobalVariable(String, String, ObjectProxy, String)
Creates a new string variable via a full qualified name. If the supplied namespace doesn't exist, it will be created.
Public methodCreateGlobalVariable(String, String, VariableType, String)
Creates a new variable in the given variable set with the given type.
Public methodCreateGlobalVariable(ObjectProxy, String, VariableType, String)
Creates a new variable in the given variable set with the given type.
Public methodCreateGlobalVariable(ObjectProxy, String, Boolean, String)
Creates a new boolean variable in the given namespace with the given type.
Public methodCreateGlobalVariable(ObjectProxy, String, Int32, String)
Creates a new integer variable in the given namespace with the given type.
Public methodCreateGlobalVariable(ObjectProxy, String, String, String)
Creates a new string variable in the given namespace with the given type.
Public methodCreateHub(UInt64, String)
Creates a new hub in the flow area.
Public methodCreateHub(ObjectProxy, String)
Creates a new hub in the flow area.
Public methodCreateHub(UInt64, String, String)
Creates a new hub in the flow area.
Public methodCreateHub(ObjectProxy, String, String)
Creates a new hub in the flow area.
Public methodCreateInstruction(UInt64, String)
Creates a new instruction node in the flow area.
Public methodCreateInstruction(ObjectProxy, String)
Creates a new instruction in the flow area.
Public methodCreateInstruction(UInt64, String, String)
Creates a new instruction in the flow area.
Public methodCreateInstruction(ObjectProxy, String, String)
Creates a new instruction in the flow area.
Public methodCreateJump(UInt64, String)
Creates a new jump in the flow area.
Public methodCreateJump(ObjectProxy, String)
Creates a new jump in the flow area.
Public methodCreateJump(UInt64, String, String)
Creates a new jump in the flow area.
Public methodCreateJump(ObjectProxy, String, String)
Creates a new jump in the flow area.
Public methodCreateLink(UInt64, Point)
Creates a new link inside a location.
Public methodCreateLink(ObjectProxy, Point)
Creates a new link inside a location.
Public methodCreateLink(UInt64, String, Point)
Creates a new link inside a location.
Public methodCreateLink(ObjectProxy, String, Point)
Creates a new link inside a location.
Public methodCreateLink(UInt64, String, Point, ObjectProxy)
Creates a new link inside a location.
Public methodCreateLink(UInt64, String, Point, UInt64)
Creates a new link inside a location.
Public methodCreateLink(ObjectProxy, String, Point, ObjectProxy)
Creates a new link inside a location.
Public methodCreateLink(ObjectProxy, String, Point, UInt64)
Creates a new link inside a location.
Public methodCreateLocation(UInt64, String)
Creates a new location object in the articy project tree.
Public methodCreateLocation(ObjectProxy, String)
Creates a new location object in the articy project tree.
Public methodCreateLocation(UInt64, String, String)
Creates a new location object in the articy project tree.
Public methodCreateLocation(ObjectProxy, String, String)
Creates a new location object in the articy project tree.
Public methodCreateLocationGroup
Creates a new location group within in an existing location or location group.
Public methodCreateLocationImage(UInt64, String, Point, UInt64)
Creates a new image inside a location.
Public methodCreateLocationImage(ObjectProxy, String, Point, ObjectProxy)
Creates a new image inside a location.
Public methodCreateLocationImage(UInt64, String, Point, UInt64, String)
Creates a new image inside a location.
Public methodCreateLocationImage(ObjectProxy, String, Point, ObjectProxy, String)
Creates a new image inside a location.
Public methodCreateLocationLayerFolder
Creates a new location layer folder within in an existing location or location layer folder.
Public methodCreateLocationText(UInt64, Point, String, Double, Double)
Creates a new text inside a location.
Public methodCreateLocationText(ObjectProxy, Point, String, Double, Double)
Creates a new text inside a location.
Public methodCreateLocationText(UInt64, Point, String, Double, Double, String)
Creates a new text inside a location.
Public methodCreateLocationText(ObjectProxy, Point, String, Double, Double, String)
Creates a new text inside a location.
Public methodCreatePath(UInt64, String, Point)
Creates a new path inside a location.
Public methodCreatePath(ObjectProxy, String, Point)
Creates a new path inside a location.
Public methodCreatePath(UInt64, String, String, Point)
Creates a new path inside a location.
Public methodCreatePath(ObjectProxy, String, String, Point)
Creates a new path inside a location.
Public methodCreateSpot(UInt64, String, Point)
Creates a new spot inside a location.
Public methodCreateSpot(ObjectProxy, String, Point)
Creates a new spot inside a location.
Public methodCreateSpot(UInt64, String, String, Point)
Creates a new spot inside a location.
Public methodCreateSpot(ObjectProxy, String, String, Point)
Creates a new spot inside a location.
Public methodCreateVariableSet
Creates a new variable set in the "Global Variables" system folder.
Public methodCreateZoneCircle(UInt64, String, Point, Double)
Creates a new spherical zone inside a location.
Public methodCreateZoneCircle(ObjectProxy, String, Point, Double)
Creates a new spherical zone inside a location.
Public methodCreateZoneCircle(UInt64, String, String, Point, Double)
Creates a new spherical zone inside a location.
Public methodCreateZoneCircle(ObjectProxy, String, String, Point, Double)
Creates a new spherical zone inside a location.
Public methodCreateZonePolygon(UInt64, String, Point)
Creates a new custom-shaped zone inside a location.
Public methodCreateZonePolygon(ObjectProxy, String, Point)
Creates a new custom-shaped zone inside a location.
Public methodCreateZonePolygon(UInt64, String, String, Point)
Creates a new custom-shaped zone inside a location.
Public methodCreateZonePolygon(ObjectProxy, String, String, Point)
Creates a new custom-shaped zone inside a location.
Public methodCreateZoneRect(UInt64, String, Rect)
Creates a new rectangular zone inside a location.
Public methodCreateZoneRect(ObjectProxy, String, Rect)
Creates a new rectangular zone inside a location.
Public methodCreateZoneRect(UInt64, String, String, Rect)
Creates a new rectangular zone inside a location.
Public methodCreateZoneRect(ObjectProxy, String, String, Rect)
Creates a new rectangular zone inside a location.
Public methodDeleteObject
Deletes the given object and all its dependencies. E.g. when you delete a folder, all elements within will also be deleted; when you delete a FlowFragment, all inner elements will be deleted, all connected pins and connections to this flow fragment get also deleted
Public methodDiscardChangesToPartition(Guid)
Discard changes in a single partition which is given by its Guid.
Public methodDiscardChangesToPartition(SimplePartitionActionArgs)
Discard changes in a single partition which is given by its Guid.
Public methodDisconnectServer
Disconnects your application from the currently connected articy:server.
Public methodDispose
Dispose the session object.
Public methodExecuteQueryInSearchNavigator
Executes a search in the current navigator search tab
Public methodExecuteTaskWithProgressDialog
Executes the given task as background process while the foreground process shows a progress dialog. Use this method for long running tasks to prevent "application not responding" conditions
Public methodExportData(ExportDataArgs)
Starts an export using the information given in the specialized ExportDataArgs descriptor
Public methodExportData(GenericExportDataArgs)
This method starts an export with a generic XML based parameter descriptor.
Public methodExportDocument(ObjectProxy, ExportDocumentToDocxArgs)
Exports a document objects using the specific document export
Public methodExportDocument(ObjectProxy, String)
Exports a document objects using the specific document export. Uses all the defaults from the ExportDocumentToDocxArgs A valid output filename must be given
Public methodFeaturePresent
Checks if the given feature exists
Public methodFindFlowPosition
Helper method to find the transformed position in the flow. If snap-to-grid option is enabled the coordinate is also snapped to coordinates on the active grid.
Public methodForcefullyUnclaimPartition(Guid)
Forcefully unclaims a partition that was claimed by another user.
Public methodForcefullyUnclaimPartition(SimplePartitionActionArgs)
Forcefully unclaims a partition that was claimed by another user.
Public methodFormatException
Formats the given exception to a string
Public methodGetAllowedObjectsForContext
Returns a HashSet containing all ObjectTypes that can appear as children object in the given context
Public methodGetClaimingStateInfo
Requests a statistics object about the partitions that
Public methodGetClassPropertyInfo
Requests the PropertyInfo object for a object class property.
Public methodGetCurrentUser
Gets the currently logged in user
Public methodGetExportSettings
Gets the XML version of the export settings
Public methodGetFeaturePropertyInfo
Requests the PropertyInfo object for a feature property
Public methodGetFeaturePropertyNames
Requests a list of all properties of a given feature
Public methodGetGlobalVariable(String)
Gets a global variable whose full qualified name, namespace & variable name, is known. For example "game.IsRunning"
Public methodGetGlobalVariable(ObjectProxy, String)
Fetches a variable from a given VariableSet
Public methodGetLocationToolsFor
Create an ApiLocationTool object
Public methodGetObjectById
Gets an an object whose ID is known.
Public methodGetObjectByTechName
Gets an object whose technical name is known.
Public methodGetObjectTypeDisplayName
Requests the display name of the given type
Public methodGetPartitionInfo
Request the information object for a single partition.
Public methodGetPartitionInfos
Requests a list of the opened project's partitions and their current states.
Public methodGetProjectFolderPath
Returns the current path to the project data
Public methodGetProjectList
Once logged into an articy:server successfully, a list of available projects can be queried using this method.
Public methodGetProjectRoot
Gets the projects root object.
Public methodGetRuleSetByName
Convenience method to get a ruleset by Displayname. (since MDK 1.5)
Public methodGetSystemFolder
Gets the given "system folder" object
Public methodGetSystemFolderId
Gets the ID of a system folder
Public methodGetTemplate
Gets the template with the given name
Public methodGetUser
Get a record of a specific user within the project from the server This list this record is fetched from is cached in the session for about 5 minutes, but may be forced to be re-request
Public methodGetUsers
Requests the list of all users within the current project from the server. This list is cached in the session for about 5 minutes, but may be forced to be re-read
Public methodGetVariableSetByName
Gets a variable set with the given name.
Public methodImportAsset(UInt64, String, String)
Imports the specified file and creates a new asset object.
Public methodImportAsset(ObjectProxy, String, String)
Imports the specified file and creates a new asset object.
Public methodImportAsset(UInt64, String, String, String)
Imports the specified file and creates a new asset object.
Public methodImportAsset(ObjectProxy, String, String, String)
Imports the specified file and creates a new asset object.
Public methodIsConnected
returns true if an active connection to the articy:server exists
Public methodIsLoggedIn
returns true if a user is logged in to the current articy:server
Public methodLinearizeFlowSegment
Create a linear list of a possible branching flow subtree. Tries to keep connected parts together and in linear order. Provides
Public methodLoadExportPreset
Loads a export preset and constructs a ExportArgs class that can be used with ExportData. You should add the selected objects, set up the Log source an may override the filename paramter.
Public methodLocalizeString
looks up a localized string with the given Loca-Id and formats the resulting text with the given parameters using the normal string.Format patterns
Public methodLocalizeStringNoFormat
looks up a localized string with the given Loca-Id
Public methodLogin
Logs a user in to the connected articy:server
Public methodLogout
Before logging into as another user, use this method to logout from the articy:server.
Public methodMoveObject
Moves the given object into the given target/parent container. The new parent must already be claimed and must allow the given object. Cross partition moves will also fail
Public methodMoveObjects
Moves the given objects into the given target/parent container The new parent must already be claimed and must allow the given objects. Cross partition moves will also fail
Public methodOpenProject
Once logged into an articy:server successfully, open a project using this method.
Public methodPublishProject
Saves the project and publishes all partitions that are claimed and contain changes. The partitions will stay claimed.
Public methodPublishProjectPartitions
Saves the project and publishes or unclaims all partitions that are claimed and contain changes.
Public methodRefactorVariableReferences
Searches expression fields for variable that are named like a certain variable but not actually linked to it. A so called stray variable reference is created when a variable is deleted while still in use by an expression field. When creating a new variable by the same name, that old reference is weak-linked to the new variable by its name. Stray references will not react on renaming or moving unless they are linked to the actual variable by using this function. Expression fields containing such stray variables will be modified and are claimed during the course of this function. Objects in partitions that are claimed by other users will be ignored. The affected partitions will not be unclaimed automatically.
Public methodReimportAsset
Schedules an re-import of an asset from its "OriginalSource" filename. The methods returns immediately. It just enqueues an job that is processing in the background. Use WaitForAssetProcessing(WaitForAssetProcessingArgs) when you need the job(s) to be completed before proceeding
Public methodRepartition
Changes the partition configuration of a project. The changes will be published and the project will be saved during this function. Only certain objects can be passed to this function. Invalid objects will cause an exception. See ObjectProxy.CanBePartitioned.
Public methodRunQuery(String)
Searches the opened project for articy objects.
Public methodRunQuery(String, ObjectProxy)
Searches the opened project for articy objects.
Public methodSaveProject
Once retrieved objects have been changed via this API, calling this method causes the changes to be written to the local project folder. Most partition handling methods of this API call this method implicitly upfront. However, if you may want to save changes on your own use this method.
Public methodSelectObject
Opens an object picker where the user can select a given object
Public methodShowDialog
Shows a window and sets the main application window as owner of the given window
Public methodShowMessageBox
Shows a message box with the given parameters
Public methodShowQueryBox
Shows a query box to enter a single value.
Public methodSimpleFindConflicts
Searches the project for object that have conflicts.
Public methodSimpleFindObjects(String)
The simplest form of the search. Searches if any text contains the given string. (not case-sensitive) Search is started at the project root node.
Public methodSimpleFindObjects(UInt64, String)
Searches if any text contains the given string starting at a given node. (not case-sensitive)
Public methodSimpleFindObjects(UInt64, String, TextFilterRelation, SearchTextIn, Boolean)
Searches if a text matches under the given compare operator.
Public methodStartJourneyOn
Public methodTemplatePresent
Checks if the given template exists
Public methodUnclaimAllMyPartitions
Unclaims all partitions the currently logged-in user has claimed.
Public methodUnclaimAllMyPartitions(UnclaimPartitionArgs)
Unclaims all partitions the currently logged in user has claimed
Public methodUnclaimPartition(Guid)
Unclaims a single partition which is given by its Guid.
Public methodUnclaimPartition(UnclaimPartitionArgs)
Unclaims a single partition which is given by its Guid.
Public methodUnclaimPartitions(ListGuid)
Unclaims all partitions in the list of partition guids in one single transaction
Public methodUnclaimPartitions(ListGuid, UnclaimPartitionArgs)
Unclaims all partitions in the list of partition guids in one single transaction
Public methodUnclaimProject
Saves the project and unclaims all partitions that are claimed and contain changes. The partitions will be unclaimed.
Public methodUpdatePartition(Guid)
Updates the given partition.
Public methodUpdatePartition(SimplePartitionActionArgs)
Updates the given partition. Using this overload you can add the output to a log
Public methodUpdatePartitions(ListGuid)
Updates all partitions in the given list. Is just a convenience method that calls the UpdatePartition(Guid) method for each guid
Public methodUpdatePartitions(ListGuid, String)
Updates all partitions in the given list. Is just a convenience method that calls the UpdatePartition(Guid) method for each guid
Public methodWaitForAssetProcessing(WaitForAssetProcessingArgs)
Blocking call that waits until the asset system has processed all assets. This has to be completed before partitions can be published or the exclusive mode can be left. After claiming a partition, opening a project in exclusive mode and importing assets, the asset system starts checking the status of each corresponding asset.
Public methodWaitForAssetProcessing(WaitForAssetProcessingArgs, IListString)
Blocking call that waits until the asset system has processed all assets. This has to be completed before partitions can be published or the exclusive mode can be left. After claiming a partition, opening a project in exclusive mode and importing assets, the asset system starts checking the status of each corresponding asset.
Top
See Also