swirl
Guide to OmniMark 9   OmniMark home
docs home 
IndexConceptsTasksSyntaxLibrariesLegacy LibrariesErrors
 
  Related Syntax   Related Concepts  
operator  

attribute is

 
 

Return type: Switch
Returns:       True if the attribute is of the type specified, otherwise false.

Syntax

attribute attribute-name element-qualifier*
   (is | isnt) (cdata | name | names | number | numbers 
                | nmtoken | nmtokens | id | idref | idrefs 
                | notation | entity | entities | group)
    


Purpose

You can use the attribute is test to determine whether an attribute is of a specified type. For example, the following code will succeed if attribute foo is of type name, and will fail otherwise:

  attribute "foo" is name
          

Attribute type tests can be combined by joining the types with | and parenthesizing them. Note that for a data attribute, a test of its type for id, idref, idrefs, notation, entity, or entities will always fail because those types of attributes cannot be associated with a notation.

Entity and notation attribute tests can be applied directly to attribute values which are declared as entity or notation, or directly to an item of an attribute declared as entities.

    Related Syntax
 
Related Concepts
 
 

Top [ INDEX ] [ CONCEPTS ] [ TASKS ] [ SYNTAX ] [ LIBRARIES ] [ LEGACY LIBRARIES ] [ ERRORS ]

OmniMark 9.1.0 Documentation Generated: September 2, 2010 at 1:51:21 pm
If you have any comments about this section of the documentation, please use this form.

Copyright © Stilo International plc, 1988-2010.