DEC Text Processing Utility Data Types

3.7 Pattern Data Type

pat1 := "abc" + (arb(2) @ var1) + remain;

SEARCH or SEARCH_QUIETLY also assigns to var1 a range that contains the text de.

If you assign to a variable a partial pattern that matches a position, rather than a character, the partial pattern variable is a range that contains the character or line-end at the point in the file where the partial pattern was matched. For example, in any of the following patterns that contain partial pattern assignments, the variable partial_pattern_variable contains the character or line-end at the point in the file where the partial pattern was matched:

"" @ partial_pattern_variable

ANCHOR @ partial_pattern_variable

UNANCHOR @ partial_pattern_variable

LINE_BEGIN @ partial_pattern_variable

BUFFER_BEGIN @ partial_pattern_variable

If you use one of the preceding patterns when the cursor is free (that is, in an area that does not contain text, such as the area after the end of a line), the variable partial_pattern_variable contains the line-end or character nearest to the cursor.

SEARCH or SEARCH_QUIETLY does partial pattern assignment only if the complete pattern matches. If the complete pattern matches, it makes assignments only to those variables paired with pattern elements that are used in the complete match. If a partial pattern assignment variable appears more than once in a pattern in places where it is legal for a partial pattern assignment to occur, the last occurrence in the pattern determines what range SEARCH assigns to the variable. For example, with the search text abcdefg and the following pattern, SEARCH or SEARCH_QUIETLY returns a range that contains the text abcde and assigns a range that contains the text d to the variable var1:

pat1 := "a" + ("b" @ var1) + "c" + ("d" @ var1)

+("e" ("x" @ var1));

3.7.3.5Relational Operators

You can use the two relational operators, equal ( = ) and not equal (<>), to compare patterns. Two patterns are equal if they are the same pattern, as pat1 and pat2 are in the following example:

pat1 := notany("abc", 2) + span("123"); pat2 := pat1;

Two patterns are also equal if they have the same internal representation. Patterns have the same internal representation only if they are built in exactly the same way. The order of the characters in the arguments to ANY, NOTANY, SCAN, SCANL, SPAN, and SPANL does not matter when you are comparing patterns returned by any of these built-ins. Other than this, almost any difference in the building of two patterns makes those patterns unequal. For example, suppose you defined the variable this_pat as follows:

this_pat := ANY ("abc");

DEC Text Processing Utility Data Types 3–15

Page 55
Image 55
Compaq AA-PWCBD-TE manual Relational Operators

AA-PWCBD-TE specifications

The Compaq AA-PWCBD-TE is a highly regarded laptop battery designed to provide reliable power to a range of Compaq laptop models. As technology continues to evolve, the necessity for efficient and long-lasting batteries becomes increasingly important, especially for students, professionals, and anyone reliant on portable computing.

One of the standout features of the AA-PWCBD-TE is its impressive capacity, designed to enhance the performance of your device. With a power capacity of around 5200 mAh, this battery is engineered to provide extended usage times, allowing users to work on the go without frequent interruptions for recharging. The battery supports efficient energy management, contributing to the overall longevity of the device.

Additionally, the AA-PWCBD-TE integrates advanced lithium-ion technology, which is favored for its reliability and minimal memory effect. Lithium-ion batteries typically offer a higher energy density compared to older technologies, meaning they can store more energy in a smaller size. This technology also supports faster charging times, making it a convenient solution for busy users.

Safety is another vital characteristic of the AA-PWCBD-TE. It features built-in protection against overcharging, overheating, and short-circuit conditions, which helps ensure the safety of both the battery and the device itself. This level of protection is crucial, especially in professional environments where equipment failure can lead to productivity losses.

Compatibility is also a key aspect of the AA-PWCBD-TE, as it is designed to fit a variety of Compaq laptop models. Users can easily determine whether this battery is suitable for their specific model, simplifying the buying process and ensuring optimal performance.

In terms of weight and dimensions, the AA-PWCBD-TE is designed to be lightweight and compact, adding minimal bulk to the laptop while still delivering powerful performance. Users can enjoy the balance of efficiency and portability, making it an ideal choice for those who travel frequently or require a battery that doesn't compromise on power.

Overall, the Compaq AA-PWCBD-TE stands out as a dependable and efficient laptop battery that enhances the user experience. With its impressive capacity, cutting-edge technology, and safety features, it is a valuable accessory for anyone looking to improve their mobile computing capabilities.