2.2.6.1.2.4 ContentRestriction Structure
The ContentRestriction structure is used to search for properties with values that match the value of a specified property.
The ContentRestriction structure has the following format.
|
|
|
|
|
|
|
|
|
|
1 |
|
|
|
|
|
|
|
|
|
2 |
|
|
|
|
|
|
|
|
|
3 |
|
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
RestrictionType |
|||||||||||||||||||||||||||||||
ulFuzzyLevel |
|||||||||||||||||||||||||||||||
PropertyType |
PropertyID |
||||||||||||||||||||||||||||||
Reserved |
|||||||||||||||||||||||||||||||
PropValueNum |
|||||||||||||||||||||||||||||||
PropValue (variable) |
RestrictionType (4 bytes): This field specifies the type of restriction and MUST be set to RES_CONTENT (0x00000003) for the ContentRestriction structure.
ulFuzzyLevel (4 bytes): This field specifies flags that control the behavior of the string comparisons that are used to evaluate the restriction. The lower 16 bits of the fuzzy level are mutually exclusive. All possible values for this field are listed in the following table.
Flag name |
Value |
Meaning |
---|---|---|
FL_FULLSTRING |
0x00000000 |
To match, the search string MUST be the same as the value of the property. |
FL_SUBSTRING |
0x00000001 |
To match, the search string MUST be contained anywhere within the property. |
FL_PREFIX |
0x00000002 |
To match, the search string MUST appear at the beginning of the property. The two strings MUST be compared only up to the length of the search. |
-
The upper 16 bits of the fuzzy level can be set to the following values and can be combined using the logical OR operation.
Flag name |
Value |
Meaning |
---|---|---|
FL_IGNORECASE |
0x00010000 |
The comparison MUST be made without considering the case. |
FL_IGNORENONSPACE |
0x00020000 |
The comparison MUST ignore Unicode-defined nonspacing characters. |
FL_LOOSE |
0x00040000 |
The comparison can result in a match whenever possible, ignoring case and nonspacing characters. The interpretation of this flag is left at the discretion of the algorithm that implements the restriction. |
PropertyType (2 bytes): This field specifies the type of the property. Valid types are specified in section 2.2.6.1.3.
PropertyID (2 bytes): This field specifies the property ID of the property.
Reserved (4 bytes): The application can fill this field with any value when writing the stream. The application MUST ignore the value of this field when reading the stream.
PropValueNum (4 bytes): This field MUST be set to 0x00000001.
PropValue (variable): A PropertyValue structure, as specified in section 2.2.6.1.4, that specifies the value to be matched.