|
|
/*===================================================================================================
|
|
|
Copyright(c) 2011 Siemens PLM Software Corp. All rights reserved.
|
|
|
Unpublished - All rights reserved
|
|
|
====================================================================================================
|
|
|
File description:
|
|
|
|
|
|
Filename : epm_register_handler.c
|
|
|
|
|
|
This file registers functions which are called when Teamcenter is being initialized
|
|
|
|
|
|
====================================================================================================
|
|
|
Date Name Description of Change
|
|
|
2011-8-21 Ray wei creation
|
|
|
|
|
|
$HISTORY$
|
|
|
==================================================================================================*/
|
|
|
|
|
|
#pragma warning (disable: 4819)
|
|
|
|
|
|
/**
|
|
|
* @headerfile tcua ͷ<>ļ<EFBFBD>
|
|
|
*/
|
|
|
#include <server_exits/user_server_exits.h>
|
|
|
#include <tccore/custom.h>
|
|
|
#include <epm/epm.h>
|
|
|
|
|
|
/**
|
|
|
* @headerfile standard c & cpp header files
|
|
|
*/
|
|
|
#include <stdio.h>
|
|
|
#include <stdlib.h>
|
|
|
#include <ctype.h>
|
|
|
#include <string.h>
|
|
|
#include <time.h>
|
|
|
|
|
|
|
|
|
/**
|
|
|
* @headerfile user's header files
|
|
|
*/
|
|
|
#include "epm_register_handler.h"
|
|
|
#include "epm_handler_common.h"
|
|
|
|
|
|
#include "util.h"
|
|
|
|
|
|
// Method and Workflow Handler
|
|
|
extern DLLAPI int CUST_init_module(int *decision, va_list args) {
|
|
|
int ifail = ITK_ok, n = 0;
|
|
|
char date_buf[80], *expire_date;
|
|
|
time_t now;
|
|
|
struct tm *p;
|
|
|
|
|
|
*decision = ALL_CUSTOMIZATIONS;
|
|
|
|
|
|
printf("==》register start\n");
|
|
|
|
|
|
ifail = EPM_register_rule_handler("jd_check_wlms_length", "jd_check_wlms_length",
|
|
|
(EPM_rule_handler_t)jd_check_wlms_length);
|
|
|
if (ifail != ITK_ok) {
|
|
|
printf("注册 jd_check_wlms_length 失败\n");
|
|
|
}
|
|
|
else {
|
|
|
printf("注册 jd_check_wlms_length 成功\n");
|
|
|
}
|
|
|
|
|
|
|
|
|
return ifail;
|
|
|
}
|
|
|
|