Anatomy of a Selector expression

Anatomy of a Selector expression

The Selector is made up of one or more function tags written inside curly brackets { } that begin with one of the six keywords: Dev, Lang, WC, RegExp, Java, and Sel , followed by a colon. Each keyword enables you to make different types of matches; it is possible to match devices, device capabilities, environment variables, language, and changes in geographical locations. A Selector may also refer to another selector expression that has been defined in the same or another Module project.

TODO Describe language.

{ Dev: "device" }Matches a device type, OS and/or size.
{ Lang: "languageCode" }Matches a language.
{ WC: environmentVariable: "Wild*Card?String" }Matches an environment variable using wild cards * ? ^ characters.
{ RegExp: environmentVariable: "RegularExpression" }Matches an environment variable in a Regular Expression.
{ Java: "javaClassName" }Executes a Java class implementing the interface com.iizix.api.ISelectorExpression.
{ Sel: "selectorReference" }Used to get the result of another selector (circular references not allowed).

The predefined functions are written inside curly brackets { }. To edit a selection of e.g. a device match, double-click on the expression. The selection dialog box will then be shown.

If you place the mouse over an expression, a tool tip will be displayed that displays a summary of the expression and the match value of the last device that accessed the internal IIZI server. If no device accessed it, the values will be matched against the Eclipse-internal browser, e.g. Internet Explorer for Windows.

{Dev: "orient-portrait"} && {Dev: "dev-isSmartphone"}

Example of a selector expression with function tags and boolean operators.

The second part of the tag is a selector property within single or double quotes. These bracketed function tags are joined together by Boolean operators to create a boolean selector expression called an IIZI Selector Expression.