Open Core Interface - MLPI
MLPI-MotionLogicProgrammingInterface(mlpi4Java)  1.26.2
com.boschrexroth.mlpi.Container Class Reference

Inherits com.boschrexroth.mlpi.MlpiComponent.

Collaboration diagram for com.boschrexroth.mlpi.Container:
Collaboration graph

Classes

class  ContainerHandle
 
class  ContainerInformation
 
class  ContainerItemInformation
 

Public Member Functions

native int create (String tagList, ContainerAccess accessFlag, ContainerHandle containerHandle)
 
native byte[] update (ContainerHandle containerHandle, byte[] buffer)
 
native void destroy (ContainerHandle containerHandle)
 
native void setName (ContainerHandle containerHandle, String name)
 
native String getName (ContainerHandle containerHandle)
 
native ContainerInformation getInformation (ContainerHandle containerHandle)
 
native String[] getTagList (ContainerHandle containerHandle)
 
native ContainerItemInformation[] getItemInformation (ContainerHandle containerHandle)
 

Detailed Description

Class definition of the mlpiContainerLib.

Definition at line 72 of file Container.java.

Member Function Documentation

native int com.boschrexroth.mlpi.Container.create ( String  tagList,
ContainerAccess  accessFlag,
ContainerHandle  containerHandle 
)

This function creates a new container. It has to be specified if the container is a read or write container. It is not possible to read and write using the same container. To specify which data to read or write, you have to give a tag list to the function. The tag list is a formatted string of one or multiple tags which are separated by a semicolon (;). Each tag is built of multiple arguments which are again separated by comma (,).

Attention
The addresses of the variables of the container content might change on every download or online change of the PLC application, so you have to stop and destroy your container before you load the PLC application!
Parameters
[in]tagListConfiguration description of container. This is a string with multiple tags as described above. Tags are delimited by semicolons.
[in]accessFlagConfiguration of container regarding read or write access.
[out]containerHandleHandle for use of container.
Returns
Return value indicating success (>=0) or error (<0).
Note:
This method maps to the mlpiCore function mlpiContainerCreate, where you can find further documentation.
native byte [] com.boschrexroth.mlpi.Container.update ( ContainerHandle  containerHandle,
byte[]  buffer 
)

This function updates a container. If you pass a handle to a write container, then you also need to pass the data and correct data size to the data argument of the function. If you pass a handle to a read container, then you will receive the data that gets read by the function in the buffer given to the data argument.

Parameters
[in]containerHandleHandle that specifies the container to update. Use create to create a container.
[in]bufferData to be written in case of write-container. Data buffer to read data to in case of read-container.
Returns
byte[] Data buffer
Note:
This method maps to the mlpiCore function mlpiContainerUpdate, where you can find further documentation.

Referenced by com.boschrexroth.mlpi.ContainerStructure.update().

Here is the caller graph for this function:

native void com.boschrexroth.mlpi.Container.destroy ( ContainerHandle  containerHandle)

This function destroys a container which has been created using create. Containers consume memory resources of the server. You should therefore destroy any containers your application no longer needs!

Attention
Please ensure you don't destroy a container when accessing it (update, read information e.g.)!
Parameters
[in]containerHandleHandle of the container to destroy. Use create to create a container.
Note:
This method maps to the mlpiCore function mlpiContainerDestroy, where you can find further documentation.

Referenced by com.boschrexroth.mlpi.ContainerStructure.destroy().

Here is the caller graph for this function:

native void com.boschrexroth.mlpi.Container.setName ( ContainerHandle  containerHandle,
String  name 
)

Using this function, you can assign a descriptive name to your container. The name can be any string. Duplicates are allowed. It is not necessary to give your container a name, but the name is used on diagnosis messages and might be useful for debugging and maintaining your application.

Parameters
[in]containerHandleHandle of the container. Use create to create a container.
[in]nameString containing a name for the container.
Note:
This method maps to the mlpiCore function mlpiContainerSetName, where you can find further documentation.
native String com.boschrexroth.mlpi.Container.getName ( ContainerHandle  containerHandle)

Using this function, you can read out the name of your container. Use the function setName to set the name.

Parameters
[in]containerHandleHandle of the container. Use create to create a container.
Returns
String name of your container
Note:
This method maps to the mlpiCore function mlpiContainerGetName, where you can find further documentation.
native ContainerInformation com.boschrexroth.mlpi.Container.getInformation ( ContainerHandle  containerHandle)

Use this function to read various pieces of information about your container. This includes time of creation, size, number of items, and type (read/write). You have to pass the container handle.

Parameters
[in]containerHandleHandle of the container. Use create to create a container.
Returns
ContainerInformation information about your container
Note:
This method maps to the mlpiCore function mlpiContainerGetInformation, where you can find further documentation.
native String [] com.boschrexroth.mlpi.Container.getTagList ( ContainerHandle  containerHandle)

This function returns the tag list of a container. This is the same tagList that was used to create the container with the function create.

Parameters
[in]containerHandleHandle of the container. Use create to create a container.
Returns
String[] the tag list of a container
Note:
This method maps to the mlpiCore function mlpiContainerGetTagList, where you can find further documentation.
native ContainerItemInformation [] com.boschrexroth.mlpi.Container.getItemInformation ( ContainerHandle  containerHandle)

This function returns the item information of a container as an array of class. Each element in the array contains information about a single item within the container. This includes information about type, size and offset of the item within the container data stream. You can use this function to read out information about the memory layout of the container data stream that gets returned by update.

Parameters
[in]containerHandleHandle of the container. Use create to create a container.
Returns
the item information of a container as an array of class
Note:
This method maps to the mlpiCore function mlpiContainerGetItemInformation, where you can find further documentation.

The documentation for this class was generated from the following file: