L_DicomCreateNet

#include "ltdic.h"

L_LTDIC_API HDICOMNET L_DicomCreateNet(pszPath, nMode)

Allocates memory for the network structure and sets the site of the temporary files.

Parameters

L_TCHAR * pszPath

Character string containing the location of the temporary files. DICOM uses temporary files during the course of creating a file. If this parameter is NULL, the DICOM temporary files are kept in the directory Windows places its own temporary files. If this parameter is not NULL, the temporary files are placed in the specified directory.

L_INT32 nMode

Flag that indicates the security mode to use when initializing the network structure. Possible values are:

Value Meaning
DICOM_SECURE_NONE No security mode.
DICOM_SECURE_ISCL Integrated Secure Communication Layer protocol security.
DICOM_SECURE_TLS Transport Layer Secure protocol security.

Returns

A DICOM Network handle.

Comments

The allocated memory is freed by calling L_DicomFreeNet.

The LEADTOOLS DICOM DLL should be initialized before calling any DICOM Communication operations function. To initialize the DLL call L_DicomStartUp.

Required DLLs and Libraries

Platforms

Win32, x64, Linux.

See Also

Functions

Topics

Example

L_INT DicomCreateNetExample(L_VOID) 
{ 
   /* This example constructs and destroys a Network class     */ 
   /* This example initializes and shutdown the network system */ 
   L_INT nRet; 
   HDICOMNET hNet=NULL; 
    
   /* start the network */ 
   nRet = L_DicomStartUp(); 
   if (nRet != DICOM_SUCCESS) 
      return nRet; 
 
   /* set the temporary file path */ 
   hNet = L_DicomCreateNet(MAKE_IMAGE_PATH(TEXT("")), DICOM_SECURE_ISCL); 
 
   if(nRet == DICOM_SUCCESS) 
      MessageBox(NULL, TEXT("StartUp() Successful"), TEXT("Test"), MB_OK); 
   else 
      MessageBox(NULL, TEXT("StartUp() Failed"), TEXT("Test"), MB_OK); 
 
   /* Initialization of other secure parameters, if necessary */ 
 
   /* 
      do some network communication here 
   */ 
   /* ... */ 
    
   /* Free the object */ 
   L_DicomFreeNet(hNet); 
 
   /* shut down the network */ 
   L_DicomShutDown(); 
 
   return DICOM_SUCCESS; 
} 
Help Version 21.0.2021.7.2
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.

LEADTOOLS DICOM C API Help
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.