sk.uniba.euromath.document.schema.plug
Interface INameListP<R extends IBaseRuleP>

Type Parameters:
R - rule type. instance of INewElementRuleP or IAttributeRuleP only.
All Superinterfaces:
IForeignNodeP, IQNameAcceptor
All Known Implementing Classes:
NameListImpl

public interface INameListP<R extends IBaseRuleP>
extends IQNameAcceptor, IForeignNodeP

Holds list of possible element/attibute QNames, with their corresponding rules. It should throw SchemaException in constructor, when one element rule can accept infinite local names.

Each rule, contained in list of accepted QNames, must be alternative to each other: we can pick one rule and create content accordingly.

There must not be element rules and attribute rules mixed together in one instance of NameListP.

Schema must not define rules for non-local elements/attributes. All local element/attribute rules can be returned using getLocalNames() function.

Author:
Martin Vysny

Method Summary
 Map<String,R> getLocalNames()
           Returns map, that maps String to AttributeRuleP or NewElementRuleP.
 
Methods inherited from interface sk.uniba.euromath.document.schema.IQNameAcceptor
accepts, getAccepts, getNamespaceUri
 
Methods inherited from interface sk.uniba.euromath.document.schema.plug.IForeignNodeP
acceptsNamespace, getNamespaces
 

Method Detail

getLocalNames

Map<String,R> getLocalNames()

Returns map, that maps String to AttributeRuleP or NewElementRuleP. Each string represents one local name, and corresponding object holds rules, that can be used to create this element/attribute's content.

General rule for schema says that each rule must generate finite set of local elements (elements from schema's namespace). Thus, this list will not be infinite.

Returns:
map of allowed localnames.


Copyright © 2003-2006 null. All Rights Reserved.