classdef TgtConnCodeGen < hgsetget
% TGTCONNCODEGEN - See coder.internal.connectivity.TgtConnMgr
%

% Copyright 2014-2015 The MathWorks, Inc.
    
    methods(Access=protected)
        function obj = TgtConnCodeGen()
        end
    end
    
    %****************************
    %*
    %*        BUILD-TIME
    %*     Public Interface
    %* -------------------------
    %*
    %*  setupBeforeTLC(obj, mdl)
    %*  cleanupAfterTLC(obj, mdl)
    %*  getIncludesAndDefinesCode(obj)
    %*  getBackgroundTaskCode(obj)
    %*  getMdlInitCode(obj)
    %*  getMdlTermCode(obj)
    %*  getPreStepCode(obj)
    %*  getPostStepCode(obj)
    %*
    %****************************

    methods(Access=public, Abstract)
        %
        % Called before and after TLC code generation for each model in
        % the hierarchy, but not if model is up-to-date (i.e. no codegen
        % occurs).  No code generation occurs in these functions, they are
        % provided to do some initialization and cleanup which may be needed
        % for each model build (e.g. modifying BuildInfo).
        %
        setupBeforeTLC(obj, mdl);
        cleanupAfterTLC(obj, mdl);
        
        %
        % Declaration code written into <model>_tgtconn.c
        %
        codeStr = getIncludesAndDefinesCode(obj);

        %
        % Function generated into <model>_tgtconn.c:
        %
        % void TgtConnBackgroundTask() 
        % {
        %    <Code from services>
        % }
        %
        codeStr = getBackgroundTaskCode(obj);

        %
        % Function generated into <model>_tgtconn.c:
        %
        % const char *TgtConnInit(int_T argc, char_T *argv[])
        % {
        %    const char *result = NULL; /* assume success */
        %
        %    <Code from services>
        %
        %    return(result);
        % }
        %
        % Return NULL if OK, otherwise a string describing the problem.
        % NULL out any argv entries processed here.
        % 
        codeStr = getMdlInitCode(obj);
        
        %
        % Function generated into <model>_tgtconn.c:
        %
        % void TgtConnTerm() 
        % {
        %    <Code from services>
        % }
        %
        codeStr = getMdlTermCode(obj);
        
        %
        % Function generated into <model>_tgtconn.c:
        %
        % void TgtConnPreStep(int_T tid) 
        % {
        %    <Code from services>
        % }
        %
        codeStr = getPreStepCode(obj);

        %
        % Function generated into <model>_tgtconn.c:
        %
        % void TgtConnPostStep(int_T tid) 
        % {
        %    <Code from services>
        % }
        %
        codeStr = getPostStepCode(obj);
    end
end
