<HTML><HEAD><link type="text/css" href="../css/main_styles.css" rel="stylesheet"></HEAD>
<BODY><TITLE>%mqc_check_single_required_ref</TITLE><H1>%mqc_check_single_required_ref </H1><P CLASS="Paragraph">Classname: <B>%mqc_check_single_required_ref </B></P><P CLASS="Paragraph">Inherits from: <B><A href=..\checkmate\xug_base_checker.html>%ug_base_checker </A></B></P><PRE STYLE=\"text-align : left;\" CLASS=\"Code\"> </PRE><PRE STYLE=\"text-align : left;\" CLASS=\"Code\">
<B>Description:</B>
    Validate the existence of the required reference set.
Parameters:
    (String) opt_required_reference_set
                          -  a required reference set name.
                             This is a mandatory parameter for the checker.
    (Integer) log_type    -  Indicate which logging type to use to report the violation
                                               1 - log error
                                               2 - log warning
                                               3 - log information
                                               The default value is 1 which is to log error.
    (String)  log_msg     -  User defined message to be added when the system
                                               reports the violation.
                                               The default is no additional message.
    (Boolean)  disabled?  -  If it is true, the checker is disabled.
                             Default is False.
    (Boolean)  save_log_in_part -  The flag indicates whether the checking results can
                                   be saved to the part file
                                   Default is True.
Results:
   PASS    -- If the required reference set exists.
   FAILED  -- If the required reference set does not exist.

<B>See Also:</B>
   %mqc_check_multi_required_ref
=============================================================================================
 Create a new checker from this template by specifying the values of the mandatory parameters:
   1. (Must)     change the class name, and the category name
   2. (Optional) change the display name. (optional)
   3. (Must)     specify the required reference set name string.
        (String)  opt_required_reference_set: "REQUIRED_REFERENCE_SET_NAME";
   4. (Optinal) change the default log type
        (integer) log_type:  1;
=============================================================================================
</PRE><PRE><FONT COLOR= blue>DefClass: %mqc_check_single_required_ref( %ug_base_checker );
</FONT></PRE><DIV><PRE STYLE=\"text-align : left;\" CLASS=\"Code\"><FONT COLOR=blue>    ( String )                      %test_category: "Template.File Structure";
    ( String )                      %displayed_name: "Check Single Required Reference Set";
    
</SPAN></FONT></PRE></DIV><DIV><PRE STYLE=\"text-align : left;\" CLASS=\"Code\"><FONT COLOR=blue>    ( Boolean Parameter )           disabled?: false;
    ( Boolean Parameter )           save_log_in_part: true;
</SPAN></FONT></PRE></DIV><PRE STYLE=\"text-align : left;\" CLASS=\"Code\">  Checker specific parameters and attributes</PRE><DIV><PRE STYLE=\"text-align : left;\" CLASS=\"Code\"><FONT COLOR=blue>    ( String Parameter )          opt_required_reference_set: "";
</SPAN></FONT></PRE></DIV><PRE STYLE=\"text-align : left;\" CLASS=\"Code\">  parameter for log_option                                       </PRE><DIV><PRE STYLE=\"text-align : left;\" CLASS=\"Code\"><FONT COLOR=blue>    ( String )                    opt_required_reference_set_label: "Required Reference Set";
    
</SPAN></FONT></PRE></DIV><DIV><PRE STYLE=\"text-align : left;\" CLASS=\"Code\"><FONT COLOR=blue>   ( Integer Parameter )          log_type: 1;
</SPAN></FONT></PRE></DIV><PRE STYLE=\"text-align : left;\" CLASS=\"Code\">  parameter for log_message     </PRE><DIV><PRE STYLE=\"text-align : left;\" CLASS=\"Code\"><FONT COLOR=blue>   ( list )                       log_type_option: { LOG_ERROR, LOG_WARNING, LOG_INFO };
   ( string )                     log_type_label: "Log Option";
</SPAN></FONT></PRE></DIV><DIV><PRE STYLE=\"text-align : left;\" CLASS=\"Code\"><FONT COLOR=blue>   ( string Parameter )           log_msg: "";
</SPAN></FONT></PRE></DIV><PRE STYLE=\"text-align : left;\" CLASS=\"Code\"> checking ...</PRE><DIV><PRE STYLE=\"text-align : left;\" CLASS=\"Code\"><FONT COLOR=blue>   ( string )                     log_msg_label: "Log Message";
    
    
    ( List ) rules_to_check:

             If  -( opt_required_reference_set: = " " ) & -( opt_required_reference_set: = noValue )

             Then
                  Splitstring( opt_required_reference_set: , "," )

             Else
                 {};


</SPAN></FONT></PRE></DIV><DIV><PRE STYLE=\"text-align : left;\" CLASS=\"Code\"><FONT COLOR=blue>    ( Any Uncached ) do_check:

             If  Empty?( rules_to_check: )

             Then
                 ug_mqc_empty_param_warning()

             Else
                 ug_mqc_checkRequiredRefSets( rules_to_check:, 
                                              nth( log_type:, log_type_option: ), 
                                              log_msg: );

</SPAN></FONT></PRE></DIV></TABLE><p class=EndLine>&nbsp;</p><p class=blank>&nbsp;</p></BODY></HTML>