/*==============================================================================
                Copyright (c) 2003-2005 UGS Corporation
                   Unpublished - All Rights Reserved
 ==============================================================================*/

/**
    @file

    This file contains the published identifiers of error codes that can be
    generated by this module. Obtaining and using the numeric values of these
    manifest constants is not supported. We reserve the right to change the
    actual values as necessary.
*/

/*  */

#ifndef NR_ERRORS_H
#define NR_ERRORS_H

#ifndef EMH_CONST_H
    #include <common/emh_const.h>
#endif

#include <property/libproperty_exports.h>

/**
    @defgroup NR_ERRORS Errors
    @ingroup NR
    @{
*/

#define NR_ERROR_BASE                          EMH_NR_error_base

/** The initialization of Naming Rule class fields has failed. Please report this error to your system administrator and check the syslog for details. */
#define NR_initialize_failed                   (NR_ERROR_BASE + 1)

/** The Naming Rule attachment case value is invalid. Valid values are mixed, lower and upper. */
#define NR_invalid_case                        (NR_ERROR_BASE + 2)

/** A Naming Rule or a Revision Naming Rule already exists with the name "%1$". */
#define NR_duplicate_rule                      (NR_ERROR_BASE + 3)

/** This property already has a Name Rule attached. */
#define NR_duplicate_attach                    (NR_ERROR_BASE + 4)

/** No Naming Rule could be found with the name "%1$". */
#define NR_missing_rule                        (NR_ERROR_BASE + 5)

/** The valid Naming Rule pattern is "%1$". */
#define NR_not_matched                         (NR_ERROR_BASE + 6)

/** The value "%2$" for the property "%1$" of the type "%3$" is invalid, because no matching Naming Rule pattern could be found. */
#define NR_never_matched                       (NR_ERROR_BASE + 7)

/** The Naming Rule pattern "%1$" contains an invalid system variable. */
#define NR_invalid_sysvar                      (NR_ERROR_BASE + 9)

/** The Naming Rule pattern "%1$" contains an incorrect escape character sequence. */
#define NR_invalid_esc                         (NR_ERROR_BASE + 10)

/** The Naming Rule pattern "%1$" does not contain the delimiter character. */
#define NR_missing_delimiter                   (NR_ERROR_BASE + 11)

/** The Naming Rule uses the variable pattern of the format "{VariableType:VariableName}", but no variable of type "%1$" can be found with the name "%2$". */
#define NR_missing_variable                    (NR_ERROR_BASE + 12)

/** This pattern must only contain a string, but the variable "%2$" is of type "%1$". */ 
#define NR_not_string_var                      (NR_ERROR_BASE + 13)

/** An invalid variable type "%1$" is provided in the Naming Rule pattern "%2$". Valid variable type is either RULE or LOV for this pattern. */
#define NR_invalid_vartype                     (NR_ERROR_BASE + 14)

/** The Naming Rule pattern "%1$" contains an invalid character. Please check the "Naming Rule" section in the Technical Documentation to understand all valid characters. */
#define NR_invalid_pattern                     (NR_ERROR_BASE + 15)

/** The counter value has reached its maximum for the given pattern. Please contact the system administrator to reset the counters. */
#define NR_max_counter_value                   (NR_ERROR_BASE + 16)

/** No counter could be found. Please contact the system administrator to correctly configure the Naming Rule pattern. */
#define NR_no_counters_found                   (NR_ERROR_BASE + 17)

/** The Naming Rule is not configured correctly, because the autogeneration is not set to create counters. Please contact the system administrator. */
#define NR_autogen_not_set                     (NR_ERROR_BASE + 18)

/** The Naming Rule already exists. Duplicate patterns are not allowed. */
#define NR_duplicate_pattern                   (NR_ERROR_BASE + 19)

/** The system contains invalid Naming Rule configuration. Autogen can not be set. Only one pattern should be present for autogen. */
#define NR_cannot_set_autogen                  (NR_ERROR_BASE + 20)

/** Not a valid pattern for setting autogen. */
#define NR_not_valid_pattern_for_autogen       (NR_ERROR_BASE + 21)

/** The Naming Rule contains an invalid pattern "%1$", because it contains nested calls. Recursive rules are not allowed. */
#define NR_max_nesting                         (NR_ERROR_BASE + 22)

/** The Naming Rule cannot be deleted, because it is referenced by the property "%1$" on the type "%2$". */
#define NR_rule_name_referenced                (NR_ERROR_BASE + 23)

/** The initial or maximum value "%1$" for the Naming Rule pattern "%2$" is invalid. */
#define NR_invalid_init_or_max_value           (NR_ERROR_BASE + 24)

/** Key - Description of pattern characters outside of quotes,
@ - Any case Alphabetic, A - Upper case, a - Lower case,
& - Any case Alphanumeric,  X - Upper case, x - Lower case,
N - Numeric, n - Numeric, U - Upper case dynamic character,
u - Lower case dynamic character, D - Mixed case dynamic character, 
? - Any character */
#define NR_key_info                            (NR_ERROR_BASE + 25)

/** The value is not in the range set by the initial and the maximum values for the Naming Rule. The value must be between "%1$" and "%2$". */
#define NR_out_of_range                        (NR_ERROR_BASE + 26)

/** The initial, secondary and supplemental revisions IDs are exhausted. Please contact your system administrator for assistance. */
#define NR_rev_exausted                        (NR_ERROR_BASE + 27)

/** The Revision ID cannot contain the following letters: "%1$". */
#define NR_excluded_letters                    (NR_ERROR_BASE + 28)

/** The auto-assignment cannot generate an ID. A Naming Rule without a counter has been configured on the property "%1$". Please contact your system administrator. */
#define NR_no_autogen                          (NR_ERROR_BASE + 29)

/** The value "%1$" is not a valid rule suffix. It must be "PDR". */
#define NR_invalid_rule_suffix                 (NR_ERROR_BASE + 30)    

/** The Revision Naming Rule information cannot be obtained for
    the property "%1$". Revision Naming Rules can only be
    configured on the "item_revision_id" property. */
#define NR_invalid_prop_for_rev_nr             (NR_ERROR_BASE + 31)    

/** The ID is not generated, because the provided Operation Input is not valid. */
#define NR_invalid_operation_input             (NR_ERROR_BASE + 32)

/** No ID Generation Rule is attached to the type "%1$". Please contact your system administrator. */
#define NR_no_id_generation_rule               (NR_ERROR_BASE + 33)

/** The ID Generator Object cannot be accessed for the type "%1$". Please provide a value to the type constant Fnd0IdGenerator. */
#define NR_cannot_resolve_id_generator_object  (NR_ERROR_BASE + 34)

/** The ID is not generated, because the provided property name "%1$" is not valid. */
#define NR_invalid_property_name               (NR_ERROR_BASE + 35)

/** The ID is not generated, because one of the provided parameters (%1$) is not valid. */
#define NR_invalid_input_arguments             (NR_ERROR_BASE + 36)

/** The ID is not generated, because the provided quantity is not valid. */
#define NR_invalid_qunatity_value              (NR_ERROR_BASE + 37)

/** The provided context name "%1$" is invalid, because its case must match the one of the dynamic characters(U/u/D) in the pattern "%2$". */
#define NR_invalid_context_pattern_char        (NR_ERROR_BASE + 38) 

/** The provided context name "%1$" is invalid, because its length must match the dynamic string length in the pattern "%2$". */
#define NR_invalid_context_pattern_length      (NR_ERROR_BASE + 39) 

/** The context based ID could not be created. Please check the Teamcenter server syslog file and report this error to your system administrator. */
#define NR_context_id_generation_fail          (NR_ERROR_BASE + 40) 

/** The context based ID could not be generated, because the provided context name is invalid (empty or contains more than 256 characters). */
#define NR_invalid_context_name                (NR_ERROR_BASE + 41) 

/** The context-based ID generation has failed because the provided number of IDs is invalid (0 or negative). */
#define NR_invalid_number_of_id                (NR_ERROR_BASE + 42) 

/** The context-based ID generation has failed because the provided number of contexts is invalid (0 or negative). */
#define NR_invalid_number_of_context           (NR_ERROR_BASE + 43)

/** The context-based ID could not be reset, because the provided context name is invalid (empty or non-existing). */
#define NR_invalid_context_name_reset          (NR_ERROR_BASE + 44) 

/** Converting an integer sequence value requires only alphanumeric values in the pattern. */
#define NR_conversion_requires_alphanumeric    (NR_ERROR_BASE + 45)

/** Converting an integer sequence value requires positive values on input. */
#define NR_conversion_negative_sequence        (NR_ERROR_BASE + 46)

/** The Naming Rule Pattern for the current Naming Rule has an invalid Sequence object. 
Please check the Teamcenter server syslog file and report this error to your system administrator.  */
#define NR_invalid_sequence                    (NR_ERROR_BASE + 47 )

/** The string length of Naming Rule Patterns must match the string lengths of the minimum and maximum values defined for the counter "%1$". */
#define NR_pattern_incompatible_with_values    (NR_ERROR_BASE + 48)

/** A character in the input string was not found in the available set for the format specifier in the counter "%1$". */
#define NR_conversion_incompatible_value       (NR_ERROR_BASE + 49)

/** An internal error has occurred in the Naming Rule module. Please report this error to your system administrator. */
#define NR_conversion_internal                 (NR_ERROR_BASE + 50)

/** The input character given for conversion to integer is not alphanumeric. */
#define NR_conversion_not_alphanumeric         (NR_ERROR_BASE + 51)

/** The input character given for conversion to integer was not found in the character set specified by the pattern. */
#define NR_conversion_mapping_not_found        (NR_ERROR_BASE + 52)

/** The numeric input for conversion to character cannot be negative. */
#define NR_conversion_negative_input           (NR_ERROR_BASE + 53)

/** The input character for conversion was expected to be numeric, but it was non-numeric. */
#define NR_conversion_not_numeric              (NR_ERROR_BASE + 54)

/** The input character for conversion was expected to be alphabetic, but it was non-alphabetic. */
#define NR_conversion_not_alphabetic           (NR_ERROR_BASE + 55)

/** An internal error has occurred: the input counter value has become negative during the conversion to "long long integer". Please report it to your Teamcenter administrator. */
#define NR_conversion_internal_counter_neg     (NR_ERROR_BASE + 56)

/** An internal error has occurred: the input "long long integer" value has become negative during conversion to a counter value place. Please report it to your Teamcenter administrator. */
#define NR_conversion_internal_value_neg       (NR_ERROR_BASE + 57)

/** An internal error has occurred: the input "long long integer" value has a negative remainder during conversion to a counter value place. Please report it to your Teamcenter administrator. */
#define NR_conversion_internal_remainder_neg   (NR_ERROR_BASE + 58)

/** An internal error has occurred: a zero divisor was encountered during conversion of a "long long value" to a counter place. Please report it to your Teamcenter administrator. */
#define NR_conversion_internal_zero_divisor    (NR_ERROR_BASE + 59)

/** The input integer value is out of range for the provided name rule pattern. */
#define NR_conversion_out_of_range             (NR_ERROR_BASE + 60)

/** The value "%1$" is invalid, because it does not match with the regular expression Naming Rule pattern "%2$". Please report it to your Teamcenter administrator.*/
#define NR_regex_never_matched                 (NR_ERROR_BASE + 61)

/** The value "%1$" is invalid, because it does not match with attached LOV Naming Rule pattern "%2$". Please report it to your Teamcenter administrator.*/
#define NR_LOV_never_matched                   (NR_ERROR_BASE + 62)

/** The operation has failed because the Alternate ID could not be generated as the counter has reached the maximum value for the pattern of the naming rule. Please contact your system administrator to reset the counters.*/
#define NR_operation_failed_due_to_counter     (NR_ERROR_BASE + 63)

/** @} */

#include <property/libproperty_undef.h>
#endif

