2.2.2.1.3 Query Changes

The Query Changes sub-request has the following format.


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

Query Changes Request

A

B

C

D

E

F

G

H

I

J

Query Changes Request Arguments

...

F

G

H

Cell ID (variable)

...

...

...

Query Changes Data Constraints

Maximum Data Elements (variable)

...

...

...

Query Changes Versioning

Major Version Number

...

Minor Version Number

...

Version Token (variable)

...

...

...

Query Changes Filters (variable)

...

...

...

Knowledge (variable)

...

...

...

Query Changes Request (4 bytes): A 32-bit Stream Object Header (section 2.2.1.5.2) that specifies the beginning of a Query Changes request.

A – Reserved (1 bit): A reserved bit that MUST be ignored.

B – Allow Fragments (1 bit): If set, a bit that specifies to allow fragments; otherwise, it does not allow fragments, unless the bit specified in E is set.

C – Exclude Object Data (1 bit): This attribute MAY be set. If set, this attribute will be ignored by the server.

D – Include Filtered Out Data Elements In Knowledge (1 bit): If set, a bit that specifies to include the Serial Numbers (section 2.2.1.9) of filtered out data elements in the response Knowledge (section 2.2.1.13); otherwise, the Serial Numbers of filtered out data elements are not included in the response Knowledge.<10>

E – Allow Fragments 2 (1 bit): If set, a bit that specifies to allow fragments; otherwise, it does not allow fragments, unless the bit specified in B is set.<11>

F – Round Knowledge to Whole Cell Changes (1 bit): If set, a bit that specifies that the knowledge specified in the request SHOULD be modified, prior to change enumeration, such that any changes under a cell node, as implied by the knowledge, cause the knowledge to be modified such that all changes in that cell are returned.<12>

G – Return File Hash (1 bit): This attribute MAY be set. If set, a bit that specifies that the server SHOULD return the file hash in the response.<13>

H – Check For File Exists (1 bit): This attribute MAY be set. If set, this attribute will be ignored by the server.

I – User Content Equivalent Version Ok (1 bit, optional): This attribute MAY be set. If set, a bit that specifies that if the version of the file cannot be found, it is acceptable to return a substitute version that is equivalent from a user authored content perspective, if such a version exists.<14>

J – Reserved (7 bits, optional): A 7-bit reserved field that MUST be set to zero and MUST be ignored.

Query Changes Request Arguments (4 bytes): An optional 32-bit Stream Object Header that specifies a Query Changes request arguments. This header MAY be set.

F – Include Storage Manifest (1 bit): If set, a bit that specifies to include the Storage Manifest; otherwise, the Storage Manifest is not included.<15> This field is only sent if Query Changes Request Arguments is specified.

G – Include Cell Changes (1 bit): If set, a bit that specifies to include cell changes; otherwise, cell changes are not included.<16> This field is only sent if Query Changes Request Arguments is specified.

H - Reserved2 (6 bits): A 6-bit reserved field that MUST be set to zero and MUST be ignored. This field is only sent if Query Changes Request Arguments is specified.

Cell ID (variable): A Cell ID (section 2.2.1.10) that specifies if the Query Changes are scoped to a specific cell. If the Cell ID is 0x0000, no scoping restriction is specified.

Query Changes Data Constraints (4 bytes): A 32-bit Stream Object Header that specifies Query Changes data constraints; this is optional if no maximum data elements constraint is required.

Maximum Data Elements (variable): A compact unsigned 64-bit integer (section 2.2.1.1) that specifies, in bytes, the limit of data elements at which the server starts breaking up the results into partial results. If the client specifies anything higher, the server truncates it to this value.

Query Changes Versioning (2 bytes): An optional 16-bit Stream Object Header that specifies Query Changes versioning.<17>

Major Version Number (4 bytes): An optional unsigned integer that specifies the major version number of the version of the file to query. A Major Version Number of 0 and a Minor Version Number of 0 is the most recent version of the document.

Minor Version Number (4 bytes): An optional unsigned integer that specifies the minor version number of the version of the file to query.

Version Token (variable): An optional byte stream that specifies the version token. This is specified if the versioning is not specified by Major Version Number and Minor Version Number.

Query Changes Filters (variable): An optional ordered array of Filters (section 2.2.2.1.3.1) that specifies how the results of the query will be filtered before it is returned to the client.

Knowledge (variable): An optional Knowledge (section 2.2.1.13) that specifies what the client knows about a state of a file.