cxErrorCode cxConnEleGet(cxConnection *src, long index, long *numConnections, long **connections)
integer function cxConnEleGet(src, index, numconnections, pconnections) integer src integer index integer numconnections integer pconnections pointer (pconnections, connections) integer connections(numconnections)
- Input connection list data structure.
- Input number of the element whose connections are to be returned.
- Output length of the connections array.
- Output pointer to the array of all connections (represented by the index number of the connection's destination) for the lattice element indicated by index.
The user is responsible for freeing the connections array after use. The connections array is allocated using malloc, rather than the shared memory allocation routines.
If cxConnEleGet is to be called many times to extract all the connection information from a connection list, it is usually many times faster to make a single call to cxConnPtrGet, which returns pointers to the actual connection list arrays.
The Fortran user can access the connections array by using the Fortran Pointer construction to equivalence the returned integer memory address and the start of the desired array, as indicated in the Fortran specification above.
A return value of cx_err_none indicates success, while another value indicates a malformed input connection list, an invalid index, or a memory allocation error.
The user can tell the function not to get information on a particular field by passing a NULL pointer value. You need not create dummy variables in the calling routine which calls cxConnEleGet, because the request is simply ignored when the pointer comes in NULL.cxConnNew(3E), cxConnPtrGet(3E), cxConnEleSet(3E), malloc(3E)
Last modified: Mon Nov 6 16:32:58 GMT 2000
[ Documentation Home ] © The Numerical Algorithms Group Ltd, Oxford UK. 1996