Content Profile Rules Using Profiles to Customize Content Screens

3-14 Application Administrators Guide for Content Server evaluated for specific profiles. For ease of use, you can use rules to group metadata fields under an optional header. For example, a profile’s rules can determine the user type and, depending on the document type being checked in, ensure that only specific metadata fields are displayed. All other fields can be hidden.

3.2.1.1.2 Triggers A trigger field is a metadata field that is defined on the

Configuration Manager: Profiles Tab . If a document matches a trigger value for a profile, then that profile is evaluated for the document. There can be an unlimited number of profiles, but only one trigger value per profile.

3.2.1.2 Profile Links

When a profile is enabled on the Edit Content Profile Links page, the profile is available from the Search and New Check In menus on the toolbar. If no profiles are enabled for display, the Search and New Check In menus become direct links to the Advanced Search page and standard Content Check In Form, respectively. After a profile has been created, it appears in the Search and New Check In menus on the toolbar when you refresh your browser session. By default, all profiles are listed as options under both menus. However, not every user will be authorized to use all of the listed profiles. On the Edit Content Profile Links page, users can decide which profiles to display by selecting or clearing applicable check boxes. For example, a marketing employee may not have the necessary privileges to use an accounting profile. In this case, the user can clear the check boxes for the accounting profile and it does not display under Search and New Check In menus. For more information about the user interface in general and the content profile links in particular, see the Oracle Fusion Middleware Users Guide for Content Server.

3.2.2 Content Profile Rules

This section covers these topics: ■ Profile Rules on page 3-14 ■ Global Rules on page 3-15 ■ Metadata Fields and Attributes in Rules on page 3-15 ■ Activation Conditions in Rules on page 3-16 ■ Restricted Lists to Modify Defined Option Lists on page 3-17

3.2.2.1 Profile Rules

A profile consists of one or more rules and a trigger value see Content Profile Elements on page 3-13. The rules determine how metadata fields are displayed on the Check In, Update, Content Information, and Search pages and if a rule will be used depending on how it is evaluated. Each rule consists of the following: Note: Rules must be established before a profile is created. See Profile Rules on page 3-14 for details. Note: Although you create rules before you create triggers and profiles, it is necessary to know what your trigger will be prior to creating rules. Managing Metadata 3-15 ■ A set of metadata fields. See Metadata Fields and Attributes in Rules on page 3-15. ■ An optional activation condition. See Activation Conditions in Rules on page 3-16. ■ An option that indicates if it is a global rule and has a specified priority. ■ An option that indicates if the metadata fields in the rule can be relocated by grouping and if an optional header is used.

3.2.2.2 Global Rules

Global rules are always ’on’ always evaluated. A global rule automatically affects the metadata fields displayed on the Check In, Update, Content Information, and Search pages even if it is not included in a profile or even if no profiles have been created. It is not necessary for a profile to exist in the system for any defined global rules to take effect and be applied to events, actions, or workflow states. However, you cannot preview the effects of a global rule unless it is associated with a profile. Global rules are evaluated first and can be superseded by specific profile rules. You can set the priority for the global rule, though, and increase its precedence. It may then have a higher priority than specific rules and produce different profile results. You can view those results by previewing the profile and seeing the consequence of rule selection. See Preview Profile Screen on page A-65 for more details about previewing profiles and viewing how rules affect the profile. A global rule obeys the following guidelines: ■ It is always on, is independent of a profile, and is always evaluated. ■ For documents and searches with profiles, the global rule is evaluated first. The specific profile rules are evaluated after the global rule. This means that global rules have a lower priority with respect to profile rules. ■ Global rules have a priority number, see AddEdit Rule Screens on page A-68. The priority determines the order in which the rule is evaluated. Lower priority rules are executed earlier and rules with higher priority can override changes made by rules with lower priority.

3.2.2.3 Metadata Fields and Attributes in Rules

Each metadata field in a rule has the following attributes: ■ Field position required: This attribute offers three general placement choices: top, middle, and bottom. The selected option adjusts the general placement order of the metadata field. This attribute is assigned using the Add Rule Field Screen . ■ Display type required: The value of this attribute can be edit, Info Only, hidden, excluded, or required. The selected option determines how the metadata field is displayed on the Check In and Search pages. This attribute is assigned using the AddEdit Rule Field ’name’ Screen . ■ Required message optional unless the display type is required: Note: Although you create rules before you create triggers and profiles, it is necessary to know what your trigger will be prior to creating rules. 3-16 Application Administrators Guide for Content Server If the metadata field is designated as required, a required message must be specified. This attribute is specified using the AddEdit Rule Field ’name’ Screen . ■ Default value optional: This attribute displays a default value for the metadata field. It is activated using the AddEdit Rule Field ’name’ Screen and defined using the Edit Default Value screen tabs see information Edit Default Value: Conditions Tab on page A-82 through Edit Default Value: Custom Tab on page A-85. ■ Derived value optional: This attribute enables the metadata field to be set to a specified value on update or check in. It is activated using the AddEdit Rule Field ’name’ Screen and defined using the Edit Derived Value screen tabs see information Edit Derived Value: Conditions Tab on page A-85 through Edit Derived Value: Custom Tab on page A-86. ■ Restricted list optional: On presentation, this attribute allows the option list metadata field to be restricted to either a specific list of values or to a filtered list of values. It is activated using the AddEdit Rule Field ’name’ Screen and defined using the Edit Restricted List Screen . See Restricted Lists to Modify Defined Option Lists on page 3-17 for details.

3.2.2.4 Activation Conditions in Rules

An activation condition allows you to change the profile behavior based on various different inputs. For example, a rule may not be active for the search page. For a contributor, certain fields may be hidden or overridden on check in. Also, because profiles are activated during any check in process, distinctions are made between a browser check in and a batch load check in. Profiles can be previewed to assess the validity of the activation conditions that may be included in the profile rules. The previewing screen allows you to check the existing profile as well as perform what-if scenarios by changing activation condition choices and evaluating the results. See Preview Profile Screen on page A-65 for details. The documentation for the Edit Activation Condition screen provides more detailed information about activation condition choices and how they are created and defined see Edit Activation Condition Screen Tabs on page A-72. An activation condition for a rule can be based on: ■ System event System event-based activation condition choices include on request events, on submit events, and on import events. ■ User action User action-based activation condition choices include check in new, check in selected, content information, content update, and search. ■ Workflow state State-based activation conditions are contingent on whether the content item is in workflow or not. ■ Document type Activation condition clauses can use components based on document metadata fields. Managing Metadata 3-17 ■ User type Activation condition clauses can use components based on user metadata fields.

3.2.2.5 Restricted Lists to Modify Defined Option Lists

The restricted list is an optional attribute that can be defined for a metadata field in a rule. Two methods can be used to modify the user interface list for metadata fields defined as option lists. ■ Specifying a fixed list: Using a restricted list allows you to specify an explicit set of values that override the actual master list for the metadata field that was defined as an option list. Only those items already in the master option list are displayed in the user interface list. ■ Using regular expression evaluation: You can also choose to use regular expressions to evaluate the option list. The list can include wild cards and other special characters for string pattern matching and evaluation processes. The items displayed in the user interface list are those values that satisfy the regular expression. This section covers the following topics: ■ Regular Expressions on page 3-17 ■ Commonly Used Elements of Java Regular Expressions on page 3-18 ■ Examples of Defining Restricted Lists on page 3-18

3.2.2.5.1 Regular Expressions Regular expressions are ideal for text manipulation and

describe the format of strings. In its simplest form, a regular expression is the text to match. For example, the regular expression ’ABC’ matches the string ABC but not the string DEF. Wild card characters, such as the asterisk , can be used to match more strings. For example, the regular expression ’AB’ will match the strings B, AB, AAB, AAAB, etc. The asterisk is a quantifier on the preceding character. Caution: Be very careful when using activation conditions that include one or more combinations of condition choices. Not all combinations of activation condition choices are valid and some may be mutually exclusive. For example, if an activation condition requires the event to be an import and the action to be a document information page request, the activation will never be true and the rule will never be active. Note: This section provides only a brief overview of using regular expression evaluation to generate modified user interface drop-downs for option list metadata fields. Regular expressions are currently supported with restricted lists. Because of the complexity of regular expressions, system administrators should be familiar with regular expressions, building patterns, and implementing regular expression methods. If not, use Oracle consulting services to assist you in defining restricted lists. 3-18 Application Administrators Guide for Content Server

3.2.2.5.2 Commonly Used Elements of Java Regular Expressions The following table lists

the most commonly used modifiers, metacharacters, and special characters used in building patterns for regular expression evaluation. Modifiers: Metacharacters: Special Characters:

3.2.2.5.3 Examples of Defining Restricted Lists The examples included in this section

illustrate the results displayed in the user interface lists depending on how the Edit Restricted List Screen is completed. The restricted lists being defined use a metadata field defined to be an option list. Its master list values are the U.S. states in alphabetical order. The two dependencies include: ■ The items or expression entered into the text pane. Element Definition g Global pattern matching. i Case-insensitive pattern matching. m Allows the special characters and to match multiple times within a string. s Allows the special character . to match newlines. x Ignores whitespace within a pattern. Element Definition \s Matches whitespace including tabs and newlines. \S Matches anything that is not whitespace. \b Matches only a word boundary. \B Matches only nonword boundaries. \d Matches digits 0 through 9. \D Matches only nonnumeric characters. \w Matches only letters, numbers, or underscores. \W Matches only characters that are not letters, numbers, or underscores. \A Matches the beginning of a string only. \Z Matches the end of a string only. Element Definition Matches zero or more occurrences of the preceding character. + Matches one or more occurrences of the preceding character. ? Matches zero or one occurrence of any character. . Matches any one character, except newlines. Matches the beginning of a string, like the \A metacharacter. Matches the end of a string, like the \Z metacharacter. | Imposes either, or. Managing Metadata 3-19 ■ The Allow Java Regular Expressions check box selected or unselected. Example 1: In this example, text values are entered into the text pane and the Allow Java Regular Expressions check box is not selected. In this case, the options ’NoState’ and ’Carolina’ are not included in the resulting list because they are not full names of states. Also notice that the order is maintained as typed into the text area. If the following values are entered into the text pane: ■ Alabama ■ Minnesota ■ NoState ■ Utah ■ Carolina The results displayed in the user interface list are: ■ Alabama ■ Minnesota ■ Utah Example 2: In this example, the same text values are entered into the text pane as in Example 1. However, the Allow Java Regular Expressions check box is selected. If the following values are entered into the text pane: ■ Alabama ■ Minnesota ■ NoState ■ Utah ■ Carolina The results displayed in the user interface list are: ■ Alabama ■ Minnesota ■ Utah ■ North Carolina ■ South Carolina In this case, both ’North Carolina’ and ’South Carolina’ are included in the resulting list because they match the regular expression ’Carolina’. Example 3: In this example, the Allow Java Regular Expressions check box is selected and instead of entering similar text values as in the previous examples the special character is used with alphabet characters. In this case, there are two regular expressions. The first expression specifies choosing everything in the master list beginning with C and the second expression specifies 3-20 Application Administrators Guide for Content Server choosing everything beginning with Al. Notice that the results order is dictated by how the list was entered in the text pane. If the following values are entered into the text pane: ■ C ■ Al Then the results displayed in the user interface list are: ■ California ■ Colorado ■ Connecticut ■ Alabama ■ Alaska Example 4: In this example, the same values are entered into the text pane as in Example 3. However, both values are entered on the same line and separated with the pipe | special character which is evaluated as ’or’. In this case, the expression retains the values in order because the list is filtered exactly once for values that begin with either Al or C. If the following values are entered into the text pane: ■ C | Al The following results are displayed in the user interface list: ■ Alabama ■ Alaska ■ California ■ Colorado ■ Connecticut

3.2.3 Content Profiles and Metadata Organization