odata-abnf-construction-rules Grammar
odataUri
odataUri := serviceRoot [ odataRelativeUri ]
serviceRoot odataRelativeUri
serviceRoot
serviceRoot := ( "https" / "http" ) ; Note: case-insensitive
"://" host [ ":" port ]
"/" *( segment-nz "/" )
"https" "http" "://" host ":" port "/" segment-nz "/"
odataRelativeUri
odataRelativeUri := %s"$batch" [ "?" batchOptions ]
/ %s"$entity" "?" entityOptions
/ %s"$entity" "/" optionallyQualifiedEntityTypeName "?" entityCastOptions
/ %s"$metadata" [ "?" metadataOptions ] [ context ]
/ resourcePath [ "?" [ queryOptions ] ]
%s"$batch" "?" batchOptions %s"$entity" "?" entityOptions %s"$entity" "/" optionallyQualifiedEntityTypeName "?" entityCastOptions %s"$metadata" "?" metadataOptions context resourcePath "?" queryOptions
resourcePath
resourcePath := entitySetName [ collectionNavigation ]
/ singletonEntity [ singleNavigation ]
/ actionImportCall
/ entityColFunctionImportCall [ collectionNavigation ]
/ entityFunctionImportCall [ singleNavigation ]
/ complexColFunctionImportCall [ complexColPath ]
/ complexFunctionImportCall [ complexPath ]
/ primitiveColFunctionImportCall [ collectionPath ]
/ primitiveFunctionImportCall [ primitivePath ]
/ functionImportCallNoParens [ querySegment ]
/ crossjoin [ querySegment ]
/ %s"$all" [ "/" optionallyQualifiedEntityTypeName ]
entitySetName collectionNavigation singletonEntity singleNavigation actionImportCall entityColFunctionImportCall collectionNavigation entityFunctionImportCall singleNavigation complexColFunctionImportCall complexColPath complexFunctionImportCall complexPath primitiveColFunctionImportCall collectionPath primitiveFunctionImportCall primitivePath functionImportCallNoParens querySegment crossjoin querySegment %s"$all" "/" optionallyQualifiedEntityTypeName
collectionNavigation
collectionNavigation := collectionNavPath
/ "/" optionallyQualifiedEntityTypeName [ collectionNavPath ]
collectionNavPath "/" optionallyQualifiedEntityTypeName collectionNavPath
collectionNavPath
collectionNavPath := keyPredicate [ singleNavigation ]
/ filterInPath [ collectionNavigation ]
/ each [ boundOperation ]
/ boundOperation
/ count
/ ref
/ querySegment
keyPredicate singleNavigation filterInPath collectionNavigation each boundOperation boundOperation count ref querySegment
keyPredicate
keyPredicate := simpleKey / compoundKey / keyPathSegments
simpleKey compoundKey keyPathSegments
simpleKey
simpleKey := OPEN ( parameterAlias / keyPropertyValue ) CLOSE
OPEN parameterAlias keyPropertyValue CLOSE
compoundKey
compoundKey := OPEN keyValuePair *( COMMA keyValuePair ) CLOSE
OPEN keyValuePair COMMA keyValuePair CLOSE
keyValuePair
keyValuePair := ( primitiveKeyProperty / keyPropertyAlias ) EQ ( parameterAlias / keyPropertyValue )
primitiveKeyProperty keyPropertyAlias EQ parameterAlias keyPropertyValue
keyPropertyAlias
keyPropertyAlias := odataIdentifier
keyPathSegments
keyPathSegments := 1*( "/" keyPathLiteral )
keyPathLiteral
keyPathLiteral := *pchar
keyPropertyValue
keyPropertyValue := boolean
/ guid
/ dateTimeOffsetLiteral
/ date
/ timeOfDayLiteral
/ decimalLiteral
/ sbyteLiteral
/ byte
/ int16Literal
/ int32Literal
/ int64Literal
/ stringLiteral
/ durationLiteral
/ enumLiteral
boolean guid dateTimeOffsetLiteral date timeOfDayLiteral decimalLiteral sbyteLiteral byte int16Literal int32Literal int64Literal stringLiteral durationLiteral enumLiteral
singleNavigation
singleNavigation := singleNavPath
/ "/" optionallyQualifiedEntityTypeName [ singleNavPath ]
singleNavPath "/" optionallyQualifiedEntityTypeName singleNavPath
singleNavPath
singleNavPath := "/" propertyPath
/ boundOperation
/ ref
/ value ; request the media resource of a media entity
/ querySegment
"/" propertyPath boundOperation ref value querySegment
propertyPath
propertyPath := entityColNavigationProperty [ collectionNavigation ]
/ entityNavigationProperty [ singleNavigation ]
/ complexColProperty [ complexColPath ]
/ complexProperty [ complexPath ]
/ primitiveColProperty [ collectionPath ]
/ primitiveProperty [ primitivePath ]
/ streamProperty [ boundOperation ]
entityColNavigationProperty collectionNavigation entityNavigationProperty singleNavigation complexColProperty complexColPath complexProperty complexPath primitiveColProperty collectionPath primitiveProperty primitivePath streamProperty boundOperation
collectionPath
collectionPath := count / boundOperation / ordinalIndex / querySegment
count boundOperation ordinalIndex querySegment
primitivePath
primitivePath := value / boundOperation / querySegment
value boundOperation querySegment
complexColPath
complexColPath := collectionPath
/ "/" optionallyQualifiedComplexTypeName [ collectionPath ]
collectionPath "/" optionallyQualifiedComplexTypeName collectionPath
complexPath
complexPath := complexNavPath
/ "/" optionallyQualifiedComplexTypeName [ complexNavPath ]
complexNavPath "/" optionallyQualifiedComplexTypeName complexNavPath
complexNavPath
complexNavPath := "/" propertyPath
/ boundOperation
/ querySegment
"/" propertyPath boundOperation querySegment
filterInPath
filterInPath := %s"/$filter" OPEN boolCommonExpr CLOSE
%s"/$filter" OPEN boolCommonExpr CLOSE
count
count := %s"/$count"
value
value := %s"/$value"
querySegment
querySegment := %s"/$query"
ordinalIndex
ordinalIndex := "/" [ "-" ] 1*DIGIT
boundOperation
boundOperation := "/" ( boundActionCall
/ boundEntityColFunctionCall [ collectionNavigation ]
/ boundEntityFunctionCall [ singleNavigation ]
/ boundComplexColFunctionCall [ complexColPath ]
/ boundComplexFunctionCall [ complexPath ]
/ boundPrimitiveColFunctionCall [ collectionPath ]
/ boundPrimitiveFunctionCall [ primitivePath ]
/ boundFunctionCallNoParens [ querySegment ]
)
"/" boundActionCall boundEntityColFunctionCall collectionNavigation boundEntityFunctionCall singleNavigation boundComplexColFunctionCall complexColPath boundComplexFunctionCall complexPath boundPrimitiveColFunctionCall collectionPath boundPrimitiveFunctionCall primitivePath boundFunctionCallNoParens querySegment
actionImportCall
actionImportCall := actionImport
boundActionCall
boundActionCall := [ namespace "." ] action
boundEntityFunctionCall
boundEntityFunctionCall := [ namespace "." ] entityFunction functionParameters
namespace "." entityFunction functionParameters
boundEntityColFunctionCall
boundEntityColFunctionCall := [ namespace "." ] entityColFunction functionParameters
namespace "." entityColFunction functionParameters
boundComplexFunctionCall
boundComplexFunctionCall := [ namespace "." ] complexFunction functionParameters
namespace "." complexFunction functionParameters
boundComplexColFunctionCall
boundComplexColFunctionCall := [ namespace "." ] complexColFunction functionParameters
namespace "." complexColFunction functionParameters
boundPrimitiveFunctionCall
boundPrimitiveFunctionCall := [ namespace "." ] primitiveFunction functionParameters
namespace "." primitiveFunction functionParameters
boundPrimitiveColFunctionCall
boundPrimitiveColFunctionCall := [ namespace "." ] primitiveColFunction functionParameters
namespace "." primitiveColFunction functionParameters
boundFunctionCallNoParens
boundFunctionCallNoParens := [ namespace "." ] entityFunction
/ [ namespace "." ] entityColFunction
/ [ namespace "." ] complexFunction
/ [ namespace "." ] complexColFunction
/ [ namespace "." ] primitiveFunction
/ [ namespace "." ] primitiveColFunction
namespace "." entityFunction namespace "." entityColFunction namespace "." complexFunction namespace "." complexColFunction namespace "." primitiveFunction namespace "." primitiveColFunction
entityFunctionImportCall
entityFunctionImportCall := entityFunctionImport functionParameters
entityFunctionImport functionParameters
entityColFunctionImportCall
entityColFunctionImportCall := entityColFunctionImport functionParameters
entityColFunctionImport functionParameters
complexFunctionImportCall
complexFunctionImportCall := complexFunctionImport functionParameters
complexFunctionImport functionParameters
complexColFunctionImportCall
complexColFunctionImportCall := complexColFunctionImport functionParameters
complexColFunctionImport functionParameters
primitiveFunctionImportCall
primitiveFunctionImportCall := primitiveFunctionImport functionParameters
primitiveFunctionImport functionParameters
primitiveColFunctionImportCall
primitiveColFunctionImportCall := primitiveColFunctionImport functionParameters
primitiveColFunctionImport functionParameters
functionImportCallNoParens
functionImportCallNoParens := entityFunctionImport
/ entityColFunctionImport
/ complexFunctionImport
/ complexColFunctionImport
/ primitiveFunctionImport
/ primitiveColFunctionImport
entityFunctionImport entityColFunctionImport complexFunctionImport complexColFunctionImport primitiveFunctionImport primitiveColFunctionImport
functionParameters
functionParameters := OPEN [ BWS functionParameter *( BWS COMMA BWS functionParameter ) ] BWS CLOSE
OPEN BWS functionParameter BWS COMMA BWS functionParameter BWS CLOSE
functionParameter
functionParameter := parameterName EQ ( parameterAlias / primitiveLiteral )
parameterName EQ parameterAlias primitiveLiteral
parameterName
parameterName := odataIdentifier
parameterAlias
parameterAlias := AT odataIdentifier
crossjoin
crossjoin := %s"$crossjoin" OPEN
entitySetName *( COMMA entitySetName )
CLOSE
%s"$crossjoin" OPEN entitySetName COMMA entitySetName CLOSE
queryOptions
queryOptions := queryOption *( "&" queryOption )
queryOption "&" queryOption
queryOption
queryOption := systemQueryOption
/ aliasAndValue
/ nameAndValue
/ customQueryOption
systemQueryOption aliasAndValue nameAndValue customQueryOption
batchOptions
batchOptions := batchOption *( "&" batchOption )
batchOption "&" batchOption
batchOption
batchOption := format
/ customQueryOption
entityOptions
entityOptions := *( entityIdOption "&" ) id *( "&" entityIdOption )
entityIdOption "&" id "&" entityIdOption
entityIdOption
entityIdOption := format
/ customQueryOption
entityCastOptions
entityCastOptions := *( entityCastOption "&" ) id *( "&" entityCastOption )
entityCastOption "&" id "&" entityCastOption
entityCastOption
entityCastOption := entityIdOption
/ expand
/ select
entityIdOption expand select
id
id := ( "$id" / "id" ) EQ IRI-in-query
systemQueryOption
systemQueryOption := compute
/ deltatoken
/ expand
/ filter
/ format
/ id
/ inlinecount
/ orderby
/ schemaversion
/ search
/ select
/ skip
/ skiptoken
/ top
/ index
compute deltatoken expand filter format id inlinecount orderby schemaversion search select skip skiptoken top index
compute
compute := ( "$compute" / "compute" ) EQ computeItem *( COMMA computeItem )
"$compute" "compute" EQ computeItem COMMA computeItem
computeItem
computeItem := commonExpr RWS "as" RWS computedProperty
commonExpr RWS "as" RWS computedProperty
computedProperty
computedProperty := odataIdentifier
expand
expand := ( "$expand" / "expand" ) EQ expandItem *( COMMA expandItem )
"$expand" "expand" EQ expandItem COMMA expandItem
expandItem
expandItem := "$value"
/ expandPath
/ optionallyQualifiedEntityTypeName "/" expandPath
"$value" expandPath optionallyQualifiedEntityTypeName "/" expandPath
expandPath
expandPath := ( STAR [ ref / OPEN levels CLOSE ]
/ ( navigationProperty / entityAnnotationInQuery ) [ "/" optionallyQualifiedEntityTypeName ]
[ ref [ OPEN expandRefOption *( SEMI expandRefOption ) CLOSE ]
/ count [ OPEN expandCountOption *( SEMI expandCountOption ) CLOSE ]
/ OPEN expandOption *( SEMI expandOption ) CLOSE
]
/ ( complexProperty / complexColProperty / optionallyQualifiedComplexTypeName / complexAnnotationInQuery ) "/" expandPath
/ streamProperty
)
STAR ref OPEN levels CLOSE navigationProperty entityAnnotationInQuery "/" optionallyQualifiedEntityTypeName ref OPEN expandRefOption SEMI expandRefOption CLOSE count OPEN expandCountOption SEMI expandCountOption CLOSE OPEN expandOption SEMI expandOption CLOSE complexProperty complexColProperty optionallyQualifiedComplexTypeName complexAnnotationInQuery "/" expandPath streamProperty
expandCountOption
expandCountOption := filter
/ search
expandRefOption
expandRefOption := expandCountOption
/ orderby
/ skip
/ top
/ inlinecount
expandCountOption orderby skip top inlinecount
expandOption
expandOption := expandRefOption
/ select
/ expand
/ compute
/ levels
/ aliasAndValue
expandRefOption select expand compute levels aliasAndValue
levels
levels := ( "$levels" / "levels" ) EQ ( oneToNine *DIGIT / "max" )
"$levels" "levels" EQ oneToNine DIGIT "max"
filter
filter := ( "$filter" / "filter" ) EQ boolCommonExpr
"$filter" "filter" EQ boolCommonExpr
orderby
orderby := ( "$orderby" / "orderby" ) EQ orderbyItem *( COMMA orderbyItem )
"$orderby" "orderby" EQ orderbyItem COMMA orderbyItem
orderbyItem
orderbyItem := commonExpr [ RWS ( "asc" / "desc" ) ]
skip
skip := ( "$skip" / "skip" ) EQ 1*DIGIT
top
top := ( "$top" / "top" ) EQ 1*DIGIT
index
index := ( "$index" / "index" ) EQ [ "-" ] 1*DIGIT
"$index" "index" EQ "-" DIGIT
inlinecount
inlinecount := ( "$count" / "count" ) EQ boolean
schemaversion
schemaversion := ( "$schemaversion" / "schemaversion" ) EQ ( STAR / 1*unreserved )
"$schemaversion" "schemaversion" EQ STAR unreserved
search
search := ( "$search" / "search" ) EQ BWS ( searchExpr / searchExpr-incomplete )
"$search" "search" EQ BWS searchExpr searchExpr-incomplete
searchExpr
searchExpr := ( searchParenExpr
/ searchNegateExpr
/ searchPhrase
/ searchWord
) [ searchOrExpr
/ searchAndExpr
]
searchParenExpr searchNegateExpr searchPhrase searchWord searchOrExpr searchAndExpr
searchParenExpr
searchParenExpr := OPEN BWS searchExpr BWS CLOSE
OPEN BWS searchExpr BWS CLOSE
searchNegateExpr
searchNegateExpr := %s"NOT" RWS searchExpr
searchOrExpr
searchOrExpr := RWS %s"OR" RWS searchExpr
searchAndExpr
searchAndExpr := RWS [ %s"AND" RWS ] searchExpr
searchPhrase
searchPhrase := quotation-mark 1*( qchar-no-AMP-DQUOTE / SP ) quotation-mark
quotation-mark qchar-no-AMP-DQUOTE SP quotation-mark
searchWord
searchWord := searchChar *( searchChar / SQUOTE )
searchChar searchChar SQUOTE
searchChar
searchChar := unreserved / pct-encoded-no-DQUOTE / "!" / "*" / "+" / "," / ":" / "@" / "/" / "?" / "$" / "="
unreserved pct-encoded-no-DQUOTE "!" "*" "+" "," ":" "@" "/" "?" "$" "="
searchExpr-incomplete
searchExpr-incomplete := SQUOTE *( SQUOTE-in-string / qchar-no-AMP-SQUOTE / quotation-mark / SP ) SQUOTE
SQUOTE SQUOTE-in-string qchar-no-AMP-SQUOTE quotation-mark SP SQUOTE
select
select := ( "$select" / "select" ) EQ selectItem *( COMMA selectItem )
"$select" "select" EQ selectItem COMMA selectItem
selectItem
selectItem := STAR
/ allOperationsInSchema
/ selectProperty
/ optionallyQualifiedActionName
/ optionallyQualifiedFunctionName
/ ( optionallyQualifiedEntityTypeName / optionallyQualifiedComplexTypeName )
"/" ( selectProperty
/ optionallyQualifiedActionName
/ optionallyQualifiedFunctionName
)
STAR allOperationsInSchema selectProperty optionallyQualifiedActionName optionallyQualifiedFunctionName optionallyQualifiedEntityTypeName optionallyQualifiedComplexTypeName "/" selectProperty optionallyQualifiedActionName optionallyQualifiedFunctionName
selectProperty
selectProperty := primitiveProperty / primitiveAnnotationInQuery
/ ( primitiveColProperty / primitiveColAnnotationInQuery ) [ OPEN selectOptionPC *( SEMI selectOptionPC ) CLOSE ]
/ navigationProperty
/ selectPath [ OPEN selectOption *( SEMI selectOption ) CLOSE
/ "/" selectProperty
]
primitiveProperty primitiveAnnotationInQuery primitiveColProperty primitiveColAnnotationInQuery OPEN selectOptionPC SEMI selectOptionPC CLOSE navigationProperty selectPath OPEN selectOption SEMI selectOption CLOSE "/" selectProperty
selectPath
selectPath := ( complexProperty / complexColProperty / complexAnnotationInQuery ) [ "/" optionallyQualifiedComplexTypeName ]
complexProperty complexColProperty complexAnnotationInQuery "/" optionallyQualifiedComplexTypeName
selectOptionPC
selectOptionPC := filter / search / inlinecount / orderby / skip / top
filter search inlinecount orderby skip top
selectOption
selectOption := selectOptionPC
/ compute / select / aliasAndValue
selectOptionPC compute select aliasAndValue
allOperationsInSchema
allOperationsInSchema := namespace "." STAR
optionallyQualifiedActionName
optionallyQualifiedActionName := [ namespace "." ] action
optionallyQualifiedFunctionName
optionallyQualifiedFunctionName := [ namespace "." ] function [ OPEN parameterNames CLOSE ]
namespace "." function OPEN parameterNames CLOSE
parameterNames
parameterNames := parameterName *( COMMA parameterName )
parameterName COMMA parameterName
deltatoken
deltatoken := "$deltatoken" EQ 1*( qchar-no-AMP )
"$deltatoken" EQ qchar-no-AMP
skiptoken
skiptoken := "$skiptoken" EQ 1*( qchar-no-AMP )
"$skiptoken" EQ qchar-no-AMP
aliasAndValue
aliasAndValue := parameterAlias EQ parameterValue
parameterAlias EQ parameterValue
nameAndValue
nameAndValue := parameterName EQ parameterValue
parameterName EQ parameterValue
parameterValue
parameterValue := arrayOrObject
/ commonExpr
customQueryOption
customQueryOption := customName [ EQ customValue ]
customName
customName := qchar-no-AMP-EQ-AT-DOLLAR *( qchar-no-AMP-EQ )
qchar-no-AMP-EQ-AT-DOLLAR qchar-no-AMP-EQ
customValue
customValue := *( qchar-no-AMP )
complexAnnotationInQuery
complexAnnotationInQuery := annotationInQuery ; complex-valued annotation
entityAnnotationInQuery
entityAnnotationInQuery := annotationInQuery ; entity-valued annotation
primitiveAnnotationInQuery
primitiveAnnotationInQuery := annotationInQuery ; primitive-valued annotation
primitiveColAnnotationInQuery
primitiveColAnnotationInQuery := annotationInQuery ; primitive collection-valued annotation
context
context := "#" contextFragment
contextFragment
contextFragment := %s"Collection($ref)"
/ %s"$ref"
/ %s"Collection(Edm.EntityType)"
/ %s"Collection(Edm.ComplexType)"
/ singletonEntity [ navigation *( containmentNavigation ) [ "/" qualifiedEntityTypeName ] ] [ selectList ]
/ qualifiedTypeName [ selectList ]
/ entitySet ( %s"/$deletedEntity" / %s"/$link" / %s"/$deletedLink" )
/ entitySet keyPredicate "/" contextPropertyPath [ selectList ]
/ entitySet [ selectList ] [ %s"/$entity" / %s"/$delta" ]
%s"Collection($ref)" %s"$ref" %s"Collection(Edm.EntityType)" %s"Collection(Edm.ComplexType)" singletonEntity navigation containmentNavigation "/" qualifiedEntityTypeName selectList qualifiedTypeName selectList entitySet %s"/$deletedEntity" %s"/$link" %s"/$deletedLink" entitySet keyPredicate "/" contextPropertyPath selectList entitySet selectList %s"/$entity" %s"/$delta"
entitySet
entitySet := entitySetName *( containmentNavigation ) [ "/" qualifiedEntityTypeName ]
entitySetName containmentNavigation "/" qualifiedEntityTypeName
containmentNavigation
containmentNavigation := keyPredicate [ "/" qualifiedEntityTypeName ] navigation
keyPredicate "/" qualifiedEntityTypeName navigation
navigation
navigation := *( "/" complexProperty [ "/" qualifiedComplexTypeName ] ) "/" navigationProperty
"/" complexProperty "/" qualifiedComplexTypeName "/" navigationProperty
selectList
selectList := OPEN [ selectListItem *( COMMA selectListItem ) ] CLOSE
OPEN selectListItem COMMA selectListItem CLOSE
selectListItem
selectListItem := STAR ; all structural properties
/ allOperationsInSchema
/ [ ( qualifiedEntityTypeName / qualifiedComplexTypeName ) "/" ]
( qualifiedActionName
/ qualifiedFunctionName
/ selectListProperty
)
STAR allOperationsInSchema qualifiedEntityTypeName qualifiedComplexTypeName "/" qualifiedActionName qualifiedFunctionName selectListProperty
selectListProperty
selectListProperty := primitiveProperty
/ primitiveColProperty
/ ( navigationProperty / entityAnnotationInFragment ) [ "+" ] [ selectList ]
/ ( complexProperty / complexColProperty / complexAnnotationInFragment ) [ "/" qualifiedComplexTypeName ] [ "/" selectListProperty ]
primitiveProperty primitiveColProperty navigationProperty entityAnnotationInFragment "+" selectList complexProperty complexColProperty complexAnnotationInFragment "/" qualifiedComplexTypeName "/" selectListProperty
contextPropertyPath
contextPropertyPath := primitiveProperty
/ primitiveColProperty
/ complexColProperty
/ complexProperty [ [ "/" qualifiedComplexTypeName ] "/" contextPropertyPath ]
primitiveProperty primitiveColProperty complexColProperty complexProperty "/" qualifiedComplexTypeName "/" contextPropertyPath
qualifiedActionName
qualifiedActionName := namespace "." action
qualifiedFunctionName
qualifiedFunctionName := namespace "." function [ OPEN parameterNames CLOSE ]
namespace "." function OPEN parameterNames CLOSE
complexAnnotationInFragment
complexAnnotationInFragment := annotationInFragment ; complex-valued annotation
entityAnnotationInFragment
entityAnnotationInFragment := annotationInFragment ; entity-valued annotation
commonExpr
commonExpr := ( primitiveLiteral
/ arrayOrObject
/ rootExpr
/ functionExpr
/ negateExpr
/ methodCallExpr
/ parenExpr
/ castExpr
/ isofExpr
/ notExpr
/ firstMemberExpr
)
[ addExpr
/ subExpr
/ mulExpr
/ divExpr
/ divbyExpr
/ modExpr
]
[ eqExpr
/ neExpr
/ ltExpr
/ leExpr
/ gtExpr
/ geExpr
/ hasExpr
/ inExpr
]
[ andExpr
/ orExpr
]
primitiveLiteral arrayOrObject rootExpr functionExpr negateExpr methodCallExpr parenExpr castExpr isofExpr notExpr firstMemberExpr addExpr subExpr mulExpr divExpr divbyExpr modExpr eqExpr neExpr ltExpr leExpr gtExpr geExpr hasExpr inExpr andExpr orExpr
boolCommonExpr
boolCommonExpr := commonExpr ; resulting in a Boolean
rootExpr
rootExpr := %s"$root/" ( entitySetName [ collectionNavigationExpr ]
/ singletonEntity [ singleNavigationExpr ]
/ entityColFunctionImport functionExprParameters [ collectionNavigationExpr ]
/ entityFunctionImport functionExprParameters [ singleNavigationExpr ]
/ complexColFunctionImport functionExprParameters [ complexColPathExpr ]
/ complexFunctionImport functionExprParameters [ complexPathExpr ]
/ primitiveColFunctionImport functionExprParameters [ collectionPathExpr ]
/ primitiveFunctionImport functionExprParameters [ primitivePathExpr ]
)
%s"$root/" entitySetName collectionNavigationExpr singletonEntity singleNavigationExpr entityColFunctionImport functionExprParameters collectionNavigationExpr entityFunctionImport functionExprParameters singleNavigationExpr complexColFunctionImport functionExprParameters complexColPathExpr complexFunctionImport functionExprParameters complexPathExpr primitiveColFunctionImport functionExprParameters collectionPathExpr primitiveFunctionImport functionExprParameters primitivePathExpr
firstMemberExpr
firstMemberExpr := memberExpr
/ inscopeVariableExpr [ "/" memberExpr ]
memberExpr inscopeVariableExpr "/" memberExpr
memberExpr
memberExpr := directMemberExpr
/ ( optionallyQualifiedEntityTypeName / optionallyQualifiedComplexTypeName ) "/" directMemberExpr
directMemberExpr optionallyQualifiedEntityTypeName optionallyQualifiedComplexTypeName "/" directMemberExpr
directMemberExpr
directMemberExpr := propertyPathExpr
/ boundFunctionExpr
/ annotationExpr
propertyPathExpr boundFunctionExpr annotationExpr
propertyPathExpr
propertyPathExpr := ( entityColNavigationProperty [ collectionNavigationExpr ]
/ entityNavigationProperty [ singleNavigationExpr ]
/ complexColProperty [ complexColPathExpr ]
/ complexProperty [ complexPathExpr ]
/ primitiveColProperty [ collectionPathExpr ]
/ primitiveProperty [ primitivePathExpr ]
/ streamProperty [ primitivePathExpr ]
)
entityColNavigationProperty collectionNavigationExpr entityNavigationProperty singleNavigationExpr complexColProperty complexColPathExpr complexProperty complexPathExpr primitiveColProperty collectionPathExpr primitiveProperty primitivePathExpr streamProperty primitivePathExpr
annotationExpr
annotationExpr := annotationInQuery
[ collectionPathExpr
/ singleNavigationExpr
/ complexPathExpr
/ primitivePathExpr
]
annotationInQuery collectionPathExpr singleNavigationExpr complexPathExpr primitivePathExpr
annotationInQuery
annotationInQuery := AT [ namespace "." ] termName [ HASH annotationQualifier ]
AT namespace "." termName HASH annotationQualifier
annotationInFragment
annotationInFragment := AT [ namespace "." ] termName [ "#" annotationQualifier ]
AT namespace "." termName "#" annotationQualifier
annotationQualifier
annotationQualifier := odataIdentifier
inscopeVariableExpr
inscopeVariableExpr := implicitVariableExpr
/ parameterAlias
/ lambdaVariableExpr ; only allowed inside a lambdaPredicateExpr
implicitVariableExpr parameterAlias lambdaVariableExpr
implicitVariableExpr
implicitVariableExpr := %s"$it" ; the current instance of the resource identified by the resource path
/ %s"$this" ; the instance on which the query option is evaluated
lambdaVariableExpr
lambdaVariableExpr := odataIdentifier
collectionNavigationExpr
collectionNavigationExpr := collectionNavNoCastExpr
/ "/" optionallyQualifiedEntityTypeName collectionNavNoCastExpr
collectionNavNoCastExpr "/" optionallyQualifiedEntityTypeName collectionNavNoCastExpr
collectionNavNoCastExpr
collectionNavNoCastExpr := keyPredicate [ singleNavigationExpr ]
/ filterExpr [ collectionNavigationExpr ]
/ collectionPathExpr
keyPredicate singleNavigationExpr filterExpr collectionNavigationExpr collectionPathExpr
singleNavigationExpr
singleNavigationExpr := "/" memberExpr
filterExpr
filterExpr := %s"/$filter" OPEN boolCommonExpr CLOSE
%s"/$filter" OPEN boolCommonExpr CLOSE
complexColPathExpr
complexColPathExpr := collectionPathExpr
/ "/" optionallyQualifiedComplexTypeName [ collectionPathExpr ]
collectionPathExpr "/" optionallyQualifiedComplexTypeName collectionPathExpr
collectionPathExpr
collectionPathExpr := count [ OPEN expandCountOption *( SEMI expandCountOption ) CLOSE ]
/ filterExpr [ collectionPathExpr ]
/ "/" anyExpr
/ "/" allExpr
/ "/" boundFunctionExpr
/ "/" annotationExpr
count OPEN expandCountOption SEMI expandCountOption CLOSE filterExpr collectionPathExpr "/" anyExpr "/" allExpr "/" boundFunctionExpr "/" annotationExpr
complexPathExpr
complexPathExpr := "/" directMemberExpr
/ "/" optionallyQualifiedComplexTypeName [ "/" directMemberExpr ]
"/" directMemberExpr "/" optionallyQualifiedComplexTypeName "/" directMemberExpr
primitivePathExpr
primitivePathExpr := "/" [ annotationExpr / boundFunctionExpr ]
"/" annotationExpr boundFunctionExpr
boundFunctionExpr
boundFunctionExpr := functionExpr ; boundFunction segments can only be composed if the type of the
functionExpr
functionExpr := [ namespace "." ]
( entityColFunction functionExprParameters [ collectionNavigationExpr ]
/ entityFunction functionExprParameters [ singleNavigationExpr ]
/ complexColFunction functionExprParameters [ complexColPathExpr ]
/ complexFunction functionExprParameters [ complexPathExpr ]
/ primitiveColFunction functionExprParameters [ collectionPathExpr ]
/ primitiveFunction functionExprParameters [ primitivePathExpr ]
)
namespace "." entityColFunction functionExprParameters collectionNavigationExpr entityFunction functionExprParameters singleNavigationExpr complexColFunction functionExprParameters complexColPathExpr complexFunction functionExprParameters complexPathExpr primitiveColFunction functionExprParameters collectionPathExpr primitiveFunction functionExprParameters primitivePathExpr
functionExprParameters
functionExprParameters := OPEN [ BWS functionExprParameter *( BWS COMMA BWS functionExprParameter ) ] BWS CLOSE
OPEN BWS functionExprParameter BWS COMMA BWS functionExprParameter BWS CLOSE
functionExprParameter
functionExprParameter := parameterName EQ ( parameterAlias / parameterValue )
parameterName EQ parameterAlias parameterValue
anyExpr
anyExpr := "any" OPEN BWS [ lambdaVariableExpr BWS COLON BWS lambdaPredicateExpr ] BWS CLOSE
"any" OPEN BWS lambdaVariableExpr BWS COLON BWS lambdaPredicateExpr BWS CLOSE
allExpr
allExpr := "all" OPEN BWS lambdaVariableExpr BWS COLON BWS lambdaPredicateExpr BWS CLOSE
"all" OPEN BWS lambdaVariableExpr BWS COLON BWS lambdaPredicateExpr BWS CLOSE
lambdaPredicateExpr
lambdaPredicateExpr := boolCommonExpr ; containing at least one lambdaVariableExpr
methodCallExpr
methodCallExpr := indexOfMethodCallExpr
/ toLowerMethodCallExpr
/ toUpperMethodCallExpr
/ trimMethodCallExpr
/ substringMethodCallExpr
/ concatMethodCallExpr
/ lengthMethodCallExpr
/ matchesPatternMethodCallExpr
/ yearMethodCallExpr
/ monthMethodCallExpr
/ dayMethodCallExpr
/ hourMethodCallExpr
/ minuteMethodCallExpr
/ secondMethodCallExpr
/ fractionalsecondsMethodCallExpr
/ totalsecondsMethodCallExpr
/ dateMethodCallExpr
/ timeMethodCallExpr
/ roundMethodCallExpr
/ floorMethodCallExpr
/ ceilingMethodCallExpr
/ distanceMethodCallExpr
/ geoLengthMethodCallExpr
/ totalOffsetMinutesMethodCallExpr
/ minDateTimeMethodCallExpr
/ maxDateTimeMethodCallExpr
/ nowMethodCallExpr
/ caseMethodCallExpr
/ boolMethodCallExpr
indexOfMethodCallExpr toLowerMethodCallExpr toUpperMethodCallExpr trimMethodCallExpr substringMethodCallExpr concatMethodCallExpr lengthMethodCallExpr matchesPatternMethodCallExpr yearMethodCallExpr monthMethodCallExpr dayMethodCallExpr hourMethodCallExpr minuteMethodCallExpr secondMethodCallExpr fractionalsecondsMethodCallExpr totalsecondsMethodCallExpr dateMethodCallExpr timeMethodCallExpr roundMethodCallExpr floorMethodCallExpr ceilingMethodCallExpr distanceMethodCallExpr geoLengthMethodCallExpr totalOffsetMinutesMethodCallExpr minDateTimeMethodCallExpr maxDateTimeMethodCallExpr nowMethodCallExpr caseMethodCallExpr boolMethodCallExpr
boolMethodCallExpr
boolMethodCallExpr := endsWithMethodCallExpr
/ startsWithMethodCallExpr
/ containsMethodCallExpr
/ intersectsMethodCallExpr
/ hasSubsetMethodCallExpr
/ hasSubsequenceMethodCallExpr
endsWithMethodCallExpr startsWithMethodCallExpr containsMethodCallExpr intersectsMethodCallExpr hasSubsetMethodCallExpr hasSubsequenceMethodCallExpr
concatMethodCallExpr
concatMethodCallExpr := "concat" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
"concat" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
containsMethodCallExpr
containsMethodCallExpr := "contains" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
"contains" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
endsWithMethodCallExpr
endsWithMethodCallExpr := "endswith" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
"endswith" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
indexOfMethodCallExpr
indexOfMethodCallExpr := "indexof" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
"indexof" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
lengthMethodCallExpr
lengthMethodCallExpr := "length" OPEN BWS commonExpr BWS CLOSE
"length" OPEN BWS commonExpr BWS CLOSE
matchesPatternMethodCallExpr
matchesPatternMethodCallExpr := "matchesPattern" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
"matchesPattern" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
startsWithMethodCallExpr
startsWithMethodCallExpr := "startswith" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
"startswith" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
substringMethodCallExpr
substringMethodCallExpr := "substring" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS [ COMMA BWS commonExpr BWS ] CLOSE
"substring" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
toLowerMethodCallExpr
toLowerMethodCallExpr := "tolower" OPEN BWS commonExpr BWS CLOSE
"tolower" OPEN BWS commonExpr BWS CLOSE
toUpperMethodCallExpr
toUpperMethodCallExpr := "toupper" OPEN BWS commonExpr BWS CLOSE
"toupper" OPEN BWS commonExpr BWS CLOSE
trimMethodCallExpr
trimMethodCallExpr := "trim" OPEN BWS commonExpr BWS CLOSE
"trim" OPEN BWS commonExpr BWS CLOSE
yearMethodCallExpr
yearMethodCallExpr := "year" OPEN BWS commonExpr BWS CLOSE
"year" OPEN BWS commonExpr BWS CLOSE
monthMethodCallExpr
monthMethodCallExpr := "month" OPEN BWS commonExpr BWS CLOSE
"month" OPEN BWS commonExpr BWS CLOSE
dayMethodCallExpr
dayMethodCallExpr := "day" OPEN BWS commonExpr BWS CLOSE
"day" OPEN BWS commonExpr BWS CLOSE
hourMethodCallExpr
hourMethodCallExpr := "hour" OPEN BWS commonExpr BWS CLOSE
"hour" OPEN BWS commonExpr BWS CLOSE
minuteMethodCallExpr
minuteMethodCallExpr := "minute" OPEN BWS commonExpr BWS CLOSE
"minute" OPEN BWS commonExpr BWS CLOSE
secondMethodCallExpr
secondMethodCallExpr := "second" OPEN BWS commonExpr BWS CLOSE
"second" OPEN BWS commonExpr BWS CLOSE
fractionalsecondsMethodCallExpr
fractionalsecondsMethodCallExpr := "fractionalseconds" OPEN BWS commonExpr BWS CLOSE
"fractionalseconds" OPEN BWS commonExpr BWS CLOSE
totalsecondsMethodCallExpr
totalsecondsMethodCallExpr := "totalseconds" OPEN BWS commonExpr BWS CLOSE
"totalseconds" OPEN BWS commonExpr BWS CLOSE
dateMethodCallExpr
dateMethodCallExpr := "date" OPEN BWS commonExpr BWS CLOSE
"date" OPEN BWS commonExpr BWS CLOSE
timeMethodCallExpr
timeMethodCallExpr := "time" OPEN BWS commonExpr BWS CLOSE
"time" OPEN BWS commonExpr BWS CLOSE
totalOffsetMinutesMethodCallExpr
totalOffsetMinutesMethodCallExpr := "totaloffsetminutes" OPEN BWS commonExpr BWS CLOSE
"totaloffsetminutes" OPEN BWS commonExpr BWS CLOSE
minDateTimeMethodCallExpr
minDateTimeMethodCallExpr := "mindatetime" OPEN BWS CLOSE
"mindatetime" OPEN BWS CLOSE
maxDateTimeMethodCallExpr
maxDateTimeMethodCallExpr := "maxdatetime" OPEN BWS CLOSE
"maxdatetime" OPEN BWS CLOSE
nowMethodCallExpr
nowMethodCallExpr := "now" OPEN BWS CLOSE
roundMethodCallExpr
roundMethodCallExpr := "round" OPEN BWS commonExpr BWS CLOSE
"round" OPEN BWS commonExpr BWS CLOSE
floorMethodCallExpr
floorMethodCallExpr := "floor" OPEN BWS commonExpr BWS CLOSE
"floor" OPEN BWS commonExpr BWS CLOSE
ceilingMethodCallExpr
ceilingMethodCallExpr := "ceiling" OPEN BWS commonExpr BWS CLOSE
"ceiling" OPEN BWS commonExpr BWS CLOSE
distanceMethodCallExpr
distanceMethodCallExpr := "geo.distance" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
"geo.distance" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
geoLengthMethodCallExpr
geoLengthMethodCallExpr := "geo.length" OPEN BWS commonExpr BWS CLOSE
"geo.length" OPEN BWS commonExpr BWS CLOSE
intersectsMethodCallExpr
intersectsMethodCallExpr := "geo.intersects" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
"geo.intersects" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
hasSubsetMethodCallExpr
hasSubsetMethodCallExpr := "hassubset" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
"hassubset" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
hasSubsequenceMethodCallExpr
hasSubsequenceMethodCallExpr := "hassubsequence" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
"hassubsequence" OPEN BWS commonExpr BWS COMMA BWS commonExpr BWS CLOSE
caseMethodCallExpr
caseMethodCallExpr := "case" OPEN BWS boolCommonExpr BWS COLON BWS commonExpr BWS
*( COMMA BWS boolCommonExpr BWS COLON BWS commonExpr BWS ) CLOSE
"case" OPEN BWS boolCommonExpr BWS COLON BWS commonExpr BWS COMMA BWS boolCommonExpr BWS COLON BWS commonExpr BWS CLOSE
parenExpr
parenExpr := OPEN BWS commonExpr BWS CLOSE
OPEN BWS commonExpr BWS CLOSE
listExpr
listExpr := OPEN BWS [ primitiveLiteral BWS *( COMMA BWS primitiveLiteral BWS ) ] CLOSE
OPEN BWS primitiveLiteral BWS COMMA BWS primitiveLiteral BWS CLOSE
andExpr
andExpr := RWS "and" RWS boolCommonExpr
RWS "and" RWS boolCommonExpr
orExpr
orExpr := RWS "or" RWS boolCommonExpr
eqExpr
eqExpr := RWS "eq" RWS commonExpr
neExpr
neExpr := RWS "ne" RWS commonExpr
ltExpr
ltExpr := RWS "lt" RWS commonExpr
leExpr
leExpr := RWS "le" RWS commonExpr
gtExpr
gtExpr := RWS "gt" RWS commonExpr
geExpr
geExpr := RWS "ge" RWS commonExpr
inExpr
inExpr := RWS "in" RWS ( listExpr / commonExpr )
RWS "in" RWS listExpr commonExpr
hasExpr
hasExpr := RWS "has" RWS enumLiteral
addExpr
addExpr := RWS "add" RWS commonExpr
subExpr
subExpr := RWS "sub" RWS commonExpr
mulExpr
mulExpr := RWS "mul" RWS commonExpr
divExpr
divExpr := RWS "div" RWS commonExpr
divbyExpr
divbyExpr := RWS "divby" RWS commonExpr
modExpr
modExpr := RWS "mod" RWS commonExpr
negateExpr
negateExpr := "-" BWS commonExpr
notExpr
notExpr := "not" RWS boolCommonExpr
isofExpr
isofExpr := "isof" OPEN BWS [ commonExpr BWS COMMA BWS ] optionallyQualifiedTypeName BWS CLOSE
"isof" OPEN BWS commonExpr BWS COMMA BWS optionallyQualifiedTypeName BWS CLOSE
castExpr
castExpr := "cast" OPEN BWS [ commonExpr BWS COMMA BWS ] optionallyQualifiedTypeName BWS CLOSE
"cast" OPEN BWS commonExpr BWS COMMA BWS optionallyQualifiedTypeName BWS CLOSE
arrayOrObject
arrayOrObject := array
/ object
array
array := begin-array
[ valueInUrl *( value-separator valueInUrl ) ]
end-array
begin-array valueInUrl value-separator valueInUrl end-array
object
object := begin-object
[ member *( value-separator member ) ]
end-object
begin-object member value-separator member end-object
member
member := stringInUrl name-separator valueInUrl
stringInUrl name-separator valueInUrl
valueInUrl
valueInUrl := stringInUrl
/ commonExpr
begin-object
begin-object := BWS ( "{" / "%7B" ) BWS
end-object
end-object := BWS ( "}" / "%7D" )
begin-array
begin-array := BWS ( "[" / "%5B" ) BWS
end-array
end-array := BWS ( "]" / "%5D" )
quotation-mark
quotation-mark := DQUOTE / "%22"
name-separator
name-separator := BWS COLON BWS
value-separator
value-separator := BWS COMMA BWS
stringInUrl
stringInUrl := quotation-mark *charInJSON quotation-mark
quotation-mark charInJSON quotation-mark
charInJSON
charInJSON := qchar-unescaped
/ qchar-JSON-special
/ escape ( quotation-mark
/ escape
/ ( "/" / "%2F" ) ; solidus U+002F - literal form is allowed in the query part of a URL
/ %s"b" ; backspace U+0008
/ %s"f" ; form feed U+000C
/ %s"n" ; line feed U+000A
/ %s"r" ; carriage return U+000D
/ %s"t" ; tab U+0009
/ %s"u" 4HEXDIG ; U+XXXX
)
qchar-unescaped qchar-JSON-special escape quotation-mark escape "/" "%2F" %s"b" %s"f" %s"n" %s"r" %s"t" %s"u" HEXDIG HEXDIG HEXDIG HEXDIG
qchar-JSON-special
qchar-JSON-special := SP / ":" / "{" / "}" / "[" / "]" ; some agents put these unencoded into the query part of a URL
escape
escape := "\" / "%5C" ; reverse solidus U+005C
qualifiedTypeName
qualifiedTypeName := singleQualifiedTypeName
/ %s"Collection" OPEN singleQualifiedTypeName CLOSE
singleQualifiedTypeName %s"Collection" OPEN singleQualifiedTypeName CLOSE
optionallyQualifiedTypeName
optionallyQualifiedTypeName := singleQualifiedTypeName
/ %s"Collection" OPEN singleQualifiedTypeName CLOSE
/ singleTypeName
/ %s"Collection" OPEN singleTypeName CLOSE
singleQualifiedTypeName %s"Collection" OPEN singleQualifiedTypeName CLOSE singleTypeName %s"Collection" OPEN singleTypeName CLOSE
singleQualifiedTypeName
singleQualifiedTypeName := qualifiedEntityTypeName
/ qualifiedComplexTypeName
/ qualifiedTypeDefinitionName
/ qualifiedEnumTypeName
/ primitiveTypeName
qualifiedEntityTypeName qualifiedComplexTypeName qualifiedTypeDefinitionName qualifiedEnumTypeName primitiveTypeName
singleTypeName
singleTypeName := entityTypeName
/ complexTypeName
/ typeDefinitionName
/ enumerationTypeName
entityTypeName complexTypeName typeDefinitionName enumerationTypeName
qualifiedEntityTypeName
qualifiedEntityTypeName := namespace "." entityTypeName
namespace "." entityTypeName
qualifiedComplexTypeName
qualifiedComplexTypeName := namespace "." complexTypeName
namespace "." complexTypeName
qualifiedTypeDefinitionName
qualifiedTypeDefinitionName := namespace "." typeDefinitionName
namespace "." typeDefinitionName
qualifiedEnumTypeName
qualifiedEnumTypeName := namespace "." enumerationTypeName
namespace "." enumerationTypeName
optionallyQualifiedEntityTypeName
optionallyQualifiedEntityTypeName := [ namespace "." ] entityTypeName
namespace "." entityTypeName
optionallyQualifiedComplexTypeName
optionallyQualifiedComplexTypeName := [ namespace "." ] complexTypeName
namespace "." complexTypeName
namespace
namespace := namespacePart *( "." namespacePart )
namespacePart "." namespacePart
namespacePart
namespacePart := odataIdentifier
entitySetName
entitySetName := odataIdentifier
singletonEntity
singletonEntity := odataIdentifier
entityTypeName
entityTypeName := odataIdentifier
complexTypeName
complexTypeName := odataIdentifier
typeDefinitionName
typeDefinitionName := odataIdentifier
enumerationTypeName
enumerationTypeName := odataIdentifier
enumerationMember
enumerationMember := odataIdentifier
termName
termName := odataIdentifier
odataIdentifier
odataIdentifier := identifierLeadingCharacter *127identifierCharacter
identifierLeadingCharacter identifierCharacter
identifierLeadingCharacter
identifierLeadingCharacter := ALPHA / "_" ; plus percent-encoded Unicode characters from the categories L or Nl
identifierCharacter
identifierCharacter := ALPHA / "_" / DIGIT ; plus percent-encoded Unicode characters from the categories L, Nl, Nd, Mn, Mc, Pc, or Cf
primitiveTypeName
primitiveTypeName := %s"Edm." ( %s"Binary"
/ %s"Boolean"
/ %s"Byte"
/ %s"Date"
/ %s"DateTimeOffset"
/ %s"Decimal"
/ %s"Double"
/ %s"Duration"
/ %s"Guid"
/ %s"Int16"
/ %s"Int32"
/ %s"Int64"
/ %s"SByte"
/ %s"Single"
/ %s"Stream"
/ %s"String"
/ %s"TimeOfDay"
/ abstractSpatialTypeName [ concreteSpatialTypeName ]
)
%s"Edm." %s"Binary" %s"Boolean" %s"Byte" %s"Date" %s"DateTimeOffset" %s"Decimal" %s"Double" %s"Duration" %s"Guid" %s"Int16" %s"Int32" %s"Int64" %s"SByte" %s"Single" %s"Stream" %s"String" %s"TimeOfDay" abstractSpatialTypeName concreteSpatialTypeName
abstractSpatialTypeName
abstractSpatialTypeName := %s"Geography"
/ %s"Geometry"
%s"Geography" %s"Geometry"
concreteSpatialTypeName
concreteSpatialTypeName := %s"Collection"
/ %s"LineString"
/ %s"MultiLineString"
/ %s"MultiPoint"
/ %s"MultiPolygon"
/ %s"Point"
/ %s"Polygon"
%s"Collection" %s"LineString" %s"MultiLineString" %s"MultiPoint" %s"MultiPolygon" %s"Point" %s"Polygon"
primitiveProperty
primitiveProperty := primitiveKeyProperty / primitiveNonKeyProperty
primitiveKeyProperty primitiveNonKeyProperty
primitiveKeyProperty
primitiveKeyProperty := odataIdentifier
primitiveNonKeyProperty
primitiveNonKeyProperty := odataIdentifier
primitiveColProperty
primitiveColProperty := odataIdentifier
complexProperty
complexProperty := odataIdentifier
complexColProperty
complexColProperty := odataIdentifier
streamProperty
streamProperty := odataIdentifier
navigationProperty
navigationProperty := entityNavigationProperty / entityColNavigationProperty
entityNavigationProperty entityColNavigationProperty
entityNavigationProperty
entityNavigationProperty := odataIdentifier
entityColNavigationProperty
entityColNavigationProperty := odataIdentifier
action
action := odataIdentifier
actionImport
actionImport := odataIdentifier
function
function := entityFunction
/ entityColFunction
/ complexFunction
/ complexColFunction
/ primitiveFunction
/ primitiveColFunction
entityFunction entityColFunction complexFunction complexColFunction primitiveFunction primitiveColFunction
entityFunction
entityFunction := odataIdentifier
entityColFunction
entityColFunction := odataIdentifier
complexFunction
complexFunction := odataIdentifier
complexColFunction
complexColFunction := odataIdentifier
primitiveFunction
primitiveFunction := odataIdentifier
primitiveColFunction
primitiveColFunction := odataIdentifier
entityFunctionImport
entityFunctionImport := odataIdentifier
entityColFunctionImport
entityColFunctionImport := odataIdentifier
complexFunctionImport
complexFunctionImport := odataIdentifier
complexColFunctionImport
complexColFunctionImport := odataIdentifier
primitiveFunctionImport
primitiveFunctionImport := odataIdentifier
primitiveColFunctionImport
primitiveColFunctionImport := odataIdentifier
primitiveLiteral
primitiveLiteral := null
/ boolean
/ guid
/ dateTimeOffsetLiteral
/ date
/ timeOfDayLiteral
/ decimalLiteral
/ doubleLiteral
/ singleLiteral
/ sbyteLiteral
/ byte
/ int16Literal
/ int32Literal
/ int64Literal
/ stringLiteral
/ durationLiteral
/ enumLiteral
/ binaryLiteral
/ geographyCollection
/ geographyLineString
/ geographyMultiLineString
/ geographyMultiPoint
/ geographyMultiPolygon
/ geographyPoint
/ geographyPolygon
/ geometryCollection
/ geometryLineString
/ geometryMultiLineString
/ geometryMultiPoint
/ geometryMultiPolygon
/ geometryPoint
/ geometryPolygon
null boolean guid dateTimeOffsetLiteral date timeOfDayLiteral decimalLiteral doubleLiteral singleLiteral sbyteLiteral byte int16Literal int32Literal int64Literal stringLiteral durationLiteral enumLiteral binaryLiteral geographyCollection geographyLineString geographyMultiLineString geographyMultiPoint geographyMultiPolygon geographyPoint geographyPolygon geometryCollection geometryLineString geometryMultiLineString geometryMultiPoint geometryMultiPolygon geometryPoint geometryPolygon
primitiveValue
primitiveValue := booleanValue
/ guidValue
/ durationValue
/ dateTimeOffsetValue
/ dateValue
/ timeOfDayValue
/ enumValue
/ fullCollectionLiteral
/ fullLineStringLiteral
/ fullMultiPointLiteral
/ fullMultiLineStringLiteral
/ fullMultiPolygonLiteral
/ fullPointLiteral
/ fullPolygonLiteral
/ decimalValue
/ doubleValue
/ singleValue
/ sbyteValue
/ byteValue
/ int16Value
/ int32Value
/ int64Value
/ binaryValue
booleanValue guidValue durationValue dateTimeOffsetValue dateValue timeOfDayValue enumValue fullCollectionLiteral fullLineStringLiteral fullMultiPointLiteral fullMultiLineStringLiteral fullMultiPolygonLiteral fullPointLiteral fullPolygonLiteral decimalValue doubleValue singleValue sbyteValue byteValue int16Value int32Value int64Value binaryValue
binaryLiteral
binaryLiteral := "binary" SQUOTE binaryValue SQUOTE
"binary" SQUOTE binaryValue SQUOTE
binaryValue
binaryValue := *(4base64char) [ base64b16 / base64b8 ]
base64char base64char base64char base64char base64b16 base64b8
base64b16
base64b16 := 2base64char ( %s"A" / %s"E" / %s"I" / %s"M" / %s"Q" / %s"U" / %s"Y" / %s"c" / %s"g" / %s"k" / %s"o" / %s"s" / %s"w" / %s"0" / %s"4" / %s"8" ) [ "=" ]
base64char base64char %s"A" %s"E" %s"I" %s"M" %s"Q" %s"U" %s"Y" %s"c" %s"g" %s"k" %s"o" %s"s" %s"w" %s"0" %s"4" %s"8" "="
base64b8
base64b8 := base64char ( %s"A" / %s"Q" / %s"g" / %s"w" ) [ "==" ]
base64char %s"A" %s"Q" %s"g" %s"w" "=="
base64char
base64char := ALPHA / DIGIT / "-" / "_"
boolean
boolean := "true" / "false"
booleanValue
booleanValue := %s"true" / %s"false"
decimalLiteral
decimalLiteral := [ SIGN ] 1*DIGIT [ "." 1*DIGIT ] [ "e" [ SIGN ] 1*DIGIT ] / nanInfinity
SIGN DIGIT "." DIGIT "e" SIGN DIGIT nanInfinity
decimalValue
decimalValue := ["+"/"-"] 1*DIGIT [ "." 1*DIGIT ] [ "e" ["+"/"-"] 1*DIGIT ] / nanInfinity
"+" "-" DIGIT "." DIGIT "e" "+" "-" DIGIT nanInfinity
doubleLiteral
doubleLiteral := decimalLiteral ; IEEE 754 binary64 floating-point number (15-17 decimal digits)
doubleValue
doubleValue := decimalValue ; IEEE 754 binary64 floating-point number (15-17 decimal digits)
singleLiteral
singleLiteral := decimalLiteral ; IEEE 754 binary32 floating-point number (6-9 decimal digits)
singleValue
singleValue := decimalValue ; IEEE 754 binary32 floating-point number (6-9 decimal digits)
nanInfinity
nanInfinity := %s"NaN" / %s"-INF" / %s"INF"
guid
guid := 8HEXDIG "-" 4HEXDIG "-" 4HEXDIG "-" 4HEXDIG "-" 12HEXDIG
HEXDIG HEXDIG HEXDIG HEXDIG HEXDIG HEXDIG HEXDIG HEXDIG "-" HEXDIG HEXDIG HEXDIG HEXDIG "-" HEXDIG HEXDIG HEXDIG HEXDIG "-" HEXDIG HEXDIG HEXDIG HEXDIG "-" HEXDIG HEXDIG HEXDIG HEXDIG HEXDIG HEXDIG HEXDIG HEXDIG HEXDIG HEXDIG HEXDIG HEXDIG
guidValue
guidValue := guid
byte
byte := 1*3DIGIT ; numbers in the range from 0 to 255
byteValue
byteValue := byte
sbyteLiteral
sbyteLiteral := [ SIGN ] 1*3DIGIT ; numbers in the range from -128 to 127
sbyteValue
sbyteValue := ["+"/"-"] 1*3DIGIT ; numbers in the range from -128 to 127
int16Literal
int16Literal := [ SIGN ] 1*5DIGIT ; numbers in the range from -32768 to 32767
int16Value
int16Value := ["+"/"-"] 1*5DIGIT ; numbers in the range from -32768 to 32767
int32Literal
int32Literal := [ SIGN ] 1*10DIGIT ; numbers in the range from -2147483648 to 2147483647
int32Value
int32Value := ["+"/"-"] 1*10DIGIT ; numbers in the range from -2147483648 to 2147483647
int64Literal
int64Literal := [ SIGN ] 1*19DIGIT ; numbers in the range from -9223372036854775808 to 9223372036854775807
int64Value
int64Value := ["+"/"-"] 1*19DIGIT ; numbers in the range from -9223372036854775808 to 9223372036854775807
stringLiteral
stringLiteral := SQUOTE *( SQUOTE-in-string / pchar-no-SQUOTE ) SQUOTE
SQUOTE SQUOTE-in-string pchar-no-SQUOTE SQUOTE
SQUOTE-in-string
SQUOTE-in-string := SQUOTE SQUOTE ; two consecutive single quotes represent one within a string literal
date
date := year "-" month "-" day
dateValue
dateValue := date
dateTimeOffsetLiteral
dateTimeOffsetLiteral := date "T" timeOfDayLiteral ( "Z" / SIGN hour COLON minute )
date "T" timeOfDayLiteral "Z" SIGN hour COLON minute
dateTimeOffsetValueInUrl
dateTimeOffsetValueInUrl := dateTimeOffsetLiteral ; legacy name referenced in Temporal spec
dateTimeOffsetValue
dateTimeOffsetValue := date "T" timeOfDayValue ( "Z" / ("+"/"-") hour ":" minute )
date "T" timeOfDayValue "Z" "+" "-" hour ":" minute
durationLiteral
durationLiteral := [ "duration" ] SQUOTE durationValue SQUOTE
"duration" SQUOTE durationValue SQUOTE
durationValue
durationValue := [ "-" ] "P" [ 1*DIGIT "D" ] [ "T" [ 1*DIGIT "H" ] [ 1*DIGIT "M" ] [ 1*DIGIT [ "." 1*DIGIT ] "S" ] ]
"-" "P" DIGIT "D" "T" DIGIT "H" DIGIT "M" DIGIT "." DIGIT "S"
timeOfDayLiteral
timeOfDayLiteral := hour COLON minute [ COLON second [ "." fractionalSeconds ] ]
hour COLON minute COLON second "." fractionalSeconds
timeOfDayValue
timeOfDayValue := hour ":" minute [ ":" second [ "." fractionalSeconds ] ]
hour ":" minute ":" second "." fractionalSeconds
oneToNine
oneToNine := "1" / "2" / "3" / "4" / "5" / "6" / "7" / "8" / "9"
"1" "2" "3" "4" "5" "6" "7" "8" "9"
zeroToFiftyNine
zeroToFiftyNine := ( "0" / "1" / "2" / "3" / "4" / "5" ) DIGIT
year
year := [ "-" ] ( "0" 3DIGIT / oneToNine 3*DIGIT )
"-" "0" DIGIT DIGIT DIGIT oneToNine DIGIT DIGIT DIGIT
month
month := "0" oneToNine
/ "1" ( "0" / "1" / "2" )
day
day := "0" oneToNine
/ ( "1" / "2" ) DIGIT
/ "3" ( "0" / "1" )
"0" oneToNine "1" "2" DIGIT "3" "0" "1"
hour
hour := ( "0" / "1" ) DIGIT
/ "2" ( "0" / "1" / "2" / "3" )
"0" "1" DIGIT "2" "0" "1" "2" "3"
minute
minute := zeroToFiftyNine
second
second := zeroToFiftyNine / "60" ; for leap seconds
fractionalSeconds
fractionalSeconds := 1*12DIGIT
enumLiteral
enumLiteral := [ qualifiedEnumTypeName ] SQUOTE singleEnumLiteral *( COMMA singleEnumLiteral ) SQUOTE
qualifiedEnumTypeName SQUOTE singleEnumLiteral COMMA singleEnumLiteral SQUOTE
singleEnumLiteral
singleEnumLiteral := enumerationMember / int64Literal
enumerationMember int64Literal
enumValue
enumValue := singleEnumValue *( "," singleEnumValue )
singleEnumValue "," singleEnumValue
singleEnumValue
singleEnumValue := enumerationMember / int64Value
enumerationMember int64Value
geographyCollection
geographyCollection := geographyPrefix SQUOTE fullCollectionLiteral SQUOTE
geographyPrefix SQUOTE fullCollectionLiteral SQUOTE
fullCollectionLiteral
fullCollectionLiteral := sridLiteral collectionLiteral
sridLiteral collectionLiteral
collectionLiteral
collectionLiteral := "GeometryCollection(" geoLiteral *( COMMA geoLiteral ) CLOSE
"GeometryCollection(" geoLiteral COMMA geoLiteral CLOSE
geoLiteral
geoLiteral := collectionLiteral
/ lineStringLiteral
/ multiPointLiteral
/ multiLineStringLiteral
/ multiPolygonLiteral
/ pointLiteral
/ polygonLiteral
collectionLiteral lineStringLiteral multiPointLiteral multiLineStringLiteral multiPolygonLiteral pointLiteral polygonLiteral
geographyLineString
geographyLineString := geographyPrefix SQUOTE fullLineStringLiteral SQUOTE
geographyPrefix SQUOTE fullLineStringLiteral SQUOTE
fullLineStringLiteral
fullLineStringLiteral := sridLiteral lineStringLiteral
sridLiteral lineStringLiteral
lineStringLiteral
lineStringLiteral := "LineString" lineStringData
"LineString" lineStringData
lineStringData
lineStringData := OPEN positionLiteral 1*( COMMA positionLiteral ) CLOSE
OPEN positionLiteral COMMA positionLiteral CLOSE
geographyMultiLineString
geographyMultiLineString := geographyPrefix SQUOTE fullMultiLineStringLiteral SQUOTE
geographyPrefix SQUOTE fullMultiLineStringLiteral SQUOTE
fullMultiLineStringLiteral
fullMultiLineStringLiteral := sridLiteral multiLineStringLiteral
sridLiteral multiLineStringLiteral
multiLineStringLiteral
multiLineStringLiteral := "MultiLineString(" [ lineStringData *( COMMA lineStringData ) ] CLOSE
"MultiLineString(" lineStringData COMMA lineStringData CLOSE
geographyMultiPoint
geographyMultiPoint := geographyPrefix SQUOTE fullMultiPointLiteral SQUOTE
geographyPrefix SQUOTE fullMultiPointLiteral SQUOTE
fullMultiPointLiteral
fullMultiPointLiteral := sridLiteral multiPointLiteral
sridLiteral multiPointLiteral
multiPointLiteral
multiPointLiteral := "MultiPoint(" [ pointData *( COMMA pointData ) ] CLOSE
"MultiPoint(" pointData COMMA pointData CLOSE
geographyMultiPolygon
geographyMultiPolygon := geographyPrefix SQUOTE fullMultiPolygonLiteral SQUOTE
geographyPrefix SQUOTE fullMultiPolygonLiteral SQUOTE
fullMultiPolygonLiteral
fullMultiPolygonLiteral := sridLiteral multiPolygonLiteral
sridLiteral multiPolygonLiteral
multiPolygonLiteral
multiPolygonLiteral := "MultiPolygon(" [ polygonData *( COMMA polygonData ) ] CLOSE
"MultiPolygon(" polygonData COMMA polygonData CLOSE
geographyPoint
geographyPoint := geographyPrefix SQUOTE fullPointLiteral SQUOTE
geographyPrefix SQUOTE fullPointLiteral SQUOTE
fullPointLiteral
fullPointLiteral := sridLiteral pointLiteral
sridLiteral
sridLiteral := "SRID" EQ 1*5DIGIT SEMI
pointLiteral
pointLiteral := "Point" pointData
pointData
pointData := OPEN positionLiteral CLOSE
positionLiteral
positionLiteral := doubleValue SP doubleValue [ SP doubleValue ] [ SP doubleValue ] ; longitude, latitude, altitude/elevation (optional), linear referencing measure (optional)
doubleValue SP doubleValue SP doubleValue SP doubleValue
geographyPolygon
geographyPolygon := geographyPrefix SQUOTE fullPolygonLiteral SQUOTE
geographyPrefix SQUOTE fullPolygonLiteral SQUOTE
fullPolygonLiteral
fullPolygonLiteral := sridLiteral polygonLiteral
sridLiteral polygonLiteral
polygonLiteral
polygonLiteral := "Polygon" polygonData
polygonData
polygonData := OPEN ringLiteral *( COMMA ringLiteral ) CLOSE
OPEN ringLiteral COMMA ringLiteral CLOSE
ringLiteral
ringLiteral := OPEN positionLiteral *( COMMA positionLiteral ) CLOSE
OPEN positionLiteral COMMA positionLiteral CLOSE
geometryCollection
geometryCollection := geometryPrefix SQUOTE fullCollectionLiteral SQUOTE
geometryPrefix SQUOTE fullCollectionLiteral SQUOTE
geometryLineString
geometryLineString := geometryPrefix SQUOTE fullLineStringLiteral SQUOTE
geometryPrefix SQUOTE fullLineStringLiteral SQUOTE
geometryMultiLineString
geometryMultiLineString := geometryPrefix SQUOTE fullMultiLineStringLiteral SQUOTE
geometryPrefix SQUOTE fullMultiLineStringLiteral SQUOTE
geometryMultiPoint
geometryMultiPoint := geometryPrefix SQUOTE fullMultiPointLiteral SQUOTE
geometryPrefix SQUOTE fullMultiPointLiteral SQUOTE
geometryMultiPolygon
geometryMultiPolygon := geometryPrefix SQUOTE fullMultiPolygonLiteral SQUOTE
geometryPrefix SQUOTE fullMultiPolygonLiteral SQUOTE
geometryPoint
geometryPoint := geometryPrefix SQUOTE fullPointLiteral SQUOTE
geometryPrefix SQUOTE fullPointLiteral SQUOTE
geometryPolygon
geometryPolygon := geometryPrefix SQUOTE fullPolygonLiteral SQUOTE
geometryPrefix SQUOTE fullPolygonLiteral SQUOTE
geographyPrefix
geographyPrefix := "geography"
geometryPrefix
geometryPrefix := "geometry"
asyncresult
asyncresult := "AsyncResult" ":" OWS 3DIGIT
"AsyncResult" ":" OWS DIGIT DIGIT DIGIT
content-id
content-id := "Content-ID" ":" OWS request-id
"Content-ID" ":" OWS request-id
isolation
isolation := [ "OData-" ] "Isolation" ":" OWS "snapshot"
"OData-" "Isolation" ":" OWS "snapshot"
request-id
request-id := 1*unreserved
odata-entityid
odata-entityid := "OData-EntityID" ":" OWS IRI-in-header
"OData-EntityID" ":" OWS IRI-in-header
odata-error
odata-error := "OData-Error" ":" OWS "{" DQUOTE %s"code" DQUOTE ":" *( VCHAR / SP )
"OData-Error" ":" OWS "{" DQUOTE %s"code" DQUOTE ":" VCHAR SP
odata-maxversion
odata-maxversion := "OData-MaxVersion" ":" OWS 1*DIGIT "." 1*DIGIT
"OData-MaxVersion" ":" OWS DIGIT "." DIGIT
odata-version
odata-version := "OData-Version" ":" OWS "4.0" [ oneToNine ]
"OData-Version" ":" OWS "4.0" oneToNine
prefer
prefer := "Prefer" ":" OWS preference *( OWS "," OWS preference )
"Prefer" ":" OWS preference OWS "," OWS preference
preference
preference := allowEntityReferencesPreference
/ callbackPreference
/ continueOnErrorPreference
/ includeAnnotationsPreference
/ maxpagesizePreference
/ omitValuesPreference
/ respondAsyncPreference
/ returnPreference
/ trackChangesPreference
/ waitPreference
allowEntityReferencesPreference callbackPreference continueOnErrorPreference includeAnnotationsPreference maxpagesizePreference omitValuesPreference respondAsyncPreference returnPreference trackChangesPreference waitPreference
allowEntityReferencesPreference
allowEntityReferencesPreference := [ "odata." ] "allow-entityreferences"
"odata." "allow-entityreferences"
callbackPreference
callbackPreference := [ "odata." ] "callback" OWS ";" OWS "url" EQ-h DQUOTE URI DQUOTE
"odata." "callback" OWS ";" OWS "url" EQ-h DQUOTE URI DQUOTE
continueOnErrorPreference
continueOnErrorPreference := [ "odata." ] "continue-on-error" [ EQ-h boolean ]
"odata." "continue-on-error" EQ-h boolean
includeAnnotationsPreference
includeAnnotationsPreference := [ "odata." ] "include-annotations" EQ-h DQUOTE annotationsList DQUOTE
"odata." "include-annotations" EQ-h DQUOTE annotationsList DQUOTE
annotationsList
annotationsList := annotationIdentifier *("," annotationIdentifier)
annotationIdentifier "," annotationIdentifier
annotationIdentifier
annotationIdentifier := [ excludeOperator ]
( STAR
/ namespace "." ( termName / STAR )
)
[ "#" odataIdentifier ]
excludeOperator STAR namespace "." termName STAR "#" odataIdentifier
excludeOperator
excludeOperator := "-"
maxpagesizePreference
maxpagesizePreference := [ "odata." ] "maxpagesize" EQ-h oneToNine *DIGIT
"odata." "maxpagesize" EQ-h oneToNine DIGIT
omitValuesPreference
omitValuesPreference := "omit-values" EQ-h ( "nulls" / "defaults" )
"omit-values" EQ-h "nulls" "defaults"
respondAsyncPreference
respondAsyncPreference := "respond-async"
returnPreference
returnPreference := "return" EQ-h ( %s"representation" / %s"minimal" )
"return" EQ-h %s"representation" %s"minimal"
trackChangesPreference
trackChangesPreference := [ "odata." ] "track-changes"
waitPreference
waitPreference := "wait" EQ-h 1*DIGIT
obs-text
obs-text := %x80-FF
OWS
OWS := *( SP / HTAB ) ; "optional" whitespace
BWS-h
BWS-h := *( SP / HTAB ) ; "bad" whitespace in header values
EQ-h
EQ-h := BWS-h EQ BWS-h
RWS
RWS := 1*( SP / HTAB / "%20" / "%09" ) ; "required" whitespace
BWS
BWS := *( SP / HTAB / "%20" / "%09" ) ; "bad" whitespace
COLON
COLON := ":" / "%3A"
COMMA
COMMA := "," / "%2C"
HASH
HASH := "%23" ; the # character is not allowed in the query part
SIGN
SIGN := "+" / "%2B" / "-"
SQUOTE
SQUOTE := "'" / "%27"
CLOSE
CLOSE := ")" / "%29"
URI
URI := scheme ":" hier-part [ "?" query ] [ "#" fragment ]
scheme ":" hier-part "?" query "#" fragment
hier-part
hier-part := "//" authority path-abempty
/ path-absolute
/ path-rootless
"//" authority path-abempty path-absolute path-rootless
scheme
scheme := ALPHA *( ALPHA / DIGIT / "+" / "-" / "." )
authority
authority := [ userinfo "@" ] host [ ":" port ]
userinfo
userinfo := *( unreserved / pct-encoded / sub-delims / ":" )
unreserved pct-encoded sub-delims ":"
host
host := IP-literal / IPv4address / reg-name
IP-literal IPv4address reg-name
IP-literal
IP-literal := "[" ( IPv6address / IPvFuture ) "]"
"[" IPv6address IPvFuture "]"
IPvFuture
IPvFuture := "v" 1*HEXDIG "." 1*( unreserved / sub-delims / ":" )
"v" HEXDIG "." unreserved sub-delims ":"
IPv6address
IPv6address := 6( h16 ":" ) ls32
/ "::" 5( h16 ":" ) ls32
/ [ h16 ] "::" 4( h16 ":" ) ls32
/ [ *1( h16 ":" ) h16 ] "::" 3( h16 ":" ) ls32
/ [ *2( h16 ":" ) h16 ] "::" 2( h16 ":" ) ls32
/ [ *3( h16 ":" ) h16 ] "::" h16 ":" ls32
/ [ *4( h16 ":" ) h16 ] "::" ls32
/ [ *5( h16 ":" ) h16 ] "::" h16
/ [ *6( h16 ":" ) h16 ] "::"
h16 ":" h16 ":" h16 ":" h16 ":" h16 ":" h16 ":" ls32 "::" h16 ":" h16 ":" h16 ":" h16 ":" h16 ":" ls32 h16 "::" h16 ":" h16 ":" h16 ":" h16 ":" ls32 h16 ":" h16 "::" h16 ":" h16 ":" h16 ":" ls32 h16 ":" h16 "::" h16 ":" h16 ":" ls32 h16 ":" h16 "::" h16 ":" ls32 h16 ":" h16 "::" ls32 h16 ":" h16 "::" h16 h16 ":" h16 "::"
ls32
ls32 := ( h16 ":" h16 ) / IPv4address
IPv4address
IPv4address := dec-octet "." dec-octet "." dec-octet "." dec-octet
dec-octet "." dec-octet "." dec-octet "." dec-octet
dec-octet
dec-octet := "1" 2DIGIT ; 100-199
/ "2" %x30-34 DIGIT ; 200-249
/ "25" %x30-35 ; 250-255
/ %x31-39 DIGIT ; 10-99
/ DIGIT ; 0-9
"1" DIGIT DIGIT "2" %x30-34 DIGIT "25" %x30-35 %x31-39 DIGIT DIGIT
reg-name
reg-name := *( unreserved / pct-encoded / sub-delims )
unreserved pct-encoded sub-delims
path-abempty
path-abempty := *( "/" segment )
path-absolute
path-absolute := "/" [ segment-nz *( "/" segment ) ]
path-rootless
path-rootless := segment-nz *( "/" segment )
segment
segment := *pchar
segment-nz
segment-nz := 1*pchar
pchar
pchar := unreserved / pct-encoded / sub-delims / ":" / "@"
unreserved pct-encoded sub-delims ":" "@"
query
query := *( pchar / "/" / "?" )
fragment
fragment := *( pchar / "/" / "?" )
pct-encoded
pct-encoded := "%" HEXDIG HEXDIG
unreserved
unreserved := ALPHA / DIGIT / "-" / "." / "_" / "~"
sub-delims
sub-delims := "$" / "&" / "'" / "=" / other-delims
other-delims
other-delims := "!" / "(" / ")" / "*" / "+" / "," / ";"
pchar-no-SQUOTE
pchar-no-SQUOTE := unreserved / pct-encoded-no-SQUOTE / other-delims / "$" / "&" / "=" / ":" / "@"
unreserved pct-encoded-no-SQUOTE other-delims "$" "&" "=" ":" "@"
pct-encoded-no-SQUOTE
pct-encoded-no-SQUOTE := "%" ( "0" / "1" / "3" / "4" / "5" / "6" / "8" / "9" / A-to-F ) HEXDIG
/ "%" "2" ( "0" / "1" / "2" / "3" / "4" / "5" / "6" / "8" / "9" / A-to-F )
"%" "0" "1" "3" "4" "5" "6" "8" "9" A-to-F HEXDIG "%" "2" "0" "1" "2" "3" "4" "5" "6" "8" "9" A-to-F
qchar-no-AMP
qchar-no-AMP := unreserved / pct-encoded / other-delims / ":" / "@" / "/" / "?" / "$" / "'" / "="
unreserved pct-encoded other-delims ":" "@" "/" "?" "$" "'" "="
qchar-no-AMP-EQ
qchar-no-AMP-EQ := unreserved / pct-encoded / other-delims / ":" / "@" / "/" / "?" / "$" / "'"
unreserved pct-encoded other-delims ":" "@" "/" "?" "$" "'"
qchar-no-AMP-EQ-AT-DOLLAR
qchar-no-AMP-EQ-AT-DOLLAR := unreserved / pct-encoded / other-delims / ":" / "/" / "?" / "'"
unreserved pct-encoded other-delims ":" "/" "?" "'"
qchar-no-AMP-SQUOTE
qchar-no-AMP-SQUOTE := unreserved / pct-encoded / other-delims / ":" / "@" / "/" / "?" / "$" / "="
unreserved pct-encoded other-delims ":" "@" "/" "?" "$" "="
qchar-no-AMP-DQUOTE
qchar-no-AMP-DQUOTE := unreserved / pct-encoded-no-DQUOTE / other-delims / ":" / "@" / "/" / "?" / "$" / "'" / "="
unreserved pct-encoded-no-DQUOTE other-delims ":" "@" "/" "?" "$" "'" "="
qchar-unescaped
qchar-unescaped := unreserved / pct-encoded-unescaped / other-delims / ":" / "@" / "/" / "?" / "$" / "'" / "="
unreserved pct-encoded-unescaped other-delims ":" "@" "/" "?" "$" "'" "="
pct-encoded-unescaped
pct-encoded-unescaped := "%" ( "0" / "1" / "3" / "4" / "6" / "7" / "8" / "9" / A-to-F ) HEXDIG
/ "%" "2" ( "0" / "1" / "3" / "4" / "5" / "6" / "7" / "8" / "9" / A-to-F )
/ "%" "5" ( DIGIT / "A" / "B" / "D" / "E" / "F" )
"%" "0" "1" "3" "4" "6" "7" "8" "9" A-to-F HEXDIG "%" "2" "0" "1" "3" "4" "5" "6" "7" "8" "9" A-to-F "%" "5" DIGIT "A" "B" "D" "E" "F"
pct-encoded-no-DQUOTE
pct-encoded-no-DQUOTE := "%" ( "0" / "1" / "3" / "4" / "5" / "6" / "7" / "8" / "9" / A-to-F ) HEXDIG
/ "%" "2" ( "0" / "1" / "3" / "4" / "5" / "6" / "7" / "8" / "9" / A-to-F )
"%" "0" "1" "3" "4" "5" "6" "7" "8" "9" A-to-F HEXDIG "%" "2" "0" "1" "3" "4" "5" "6" "7" "8" "9" A-to-F
IRI-in-query
IRI-in-query := 1*qchar-no-AMP
ALPHA
ALPHA := %x41-5A / %x61-7A
HEXDIG
HEXDIG := DIGIT / A-to-F
A-to-F
A-to-F := "A" / "B" / "C" / "D" / "E" / "F"