{
  "synLogic": "int $ret \u003d $api($1, $2, $3);",
  "help": "The ns_chk_strcpy copies a string or a buffer  to a destination buffer. The source buffer can be constant or C variable while destination buffer is always a C variable.",
  "notes": "",
  "returns": "int",
  "arguments": "",
  "parameterization": "You cannot use standard parameterization for any arguments in this function.",
  "name": "ns_chk_strcpy",
  "syntax": "int ns_chk_strcpy(char *dest, char *src, int dest_len);",
  "javaSyntax": "",
  "cEx": "flow()\n{\n  char src[128 + 1] \u003d \"String to copy\";\n  int ret;\n  // Case 1 - String will be copied without truncation\n  \n  ret \u003d ns_chk_strcpy(dest1, src, 32);\n  //Here \u0027String to copy\u0027 gets saved in dest1 buffer\n  \n  // Case 2 - String will be copied with truncation\n  \n  ret \u003d ns_chk_strcpy(dest2, src, 20);\n  //Here \u0027Source String to co\u0027 gets saved in dest2 buffer as size of dest2 buffer is 20 bytes\n}",
  "javaEx": "",
  "insertStrC": "ns_chk_strcpy(char *dest, char *src, int dest_len);",
  "insertStrJava": "",
  "description": "Copies string from source buffer to destination buffer.",
  "component":[
	  {
            "id": "$1",
            "type": "TextField",
            "label": "Destination",
        "labelVarCheckbox":"",
            "value": "",
            "css": "p-grid p-align-center w-100-p",
            "title": "Enter the Destination",
            "placeHolder": "",
            "style": "",
            "isDisabled": "",
            "validate": {
              "inputType": "Text",
          "required":true,
	  "method":"isValidVar(arg)"
              }
           },
	   {
            "id": "$2",
            "type": "TEXT_VAR",
            "label": "Source",
        "labelVarCheckbox":"If Source name is a program variable.",
            "value": "",
            "css": "p-grid p-align-center w-100-p",
            "title": "Enter the Source",
            "placeHolder": "",
            "style": "",
            "isDisabled": "",
            "validate": {
              "inputType": "Text",
	      "required": true
             }
           },
	   {
            "id": "$3",
            "type": "TextField",
            "label": "Length",
        "labelVarCheckbox":"",
            "value": "",
            "css": "p-grid p-align-center w-100-p",
            "title": "Enter String Length",
            "placeHolder": "",
            "style": "",
            "isDisabled": "",
            "validate": {
              "inputType": "Number",
               "required":true,
	  	"min":"0",
		"max":"2147483647"
             }
           },
           {
            "id": "$ret",
            "type": "TextField",
            "label": "Return Variable",
        "labelVarCheckbox":"",
            "value": "",
            "css": "p-grid p-align-center w-100-p",
            "title": "Enter return variable",
            "placeHolder": "",
            "style": "",
            "isDisabled": "",
            "validate": {
              "inputType": "Text",
          "required":false,
	  "method":"isValidVar(arg)"
            }
          }
  ]
}
