Class DirectoryEntryResolver

  • All Implemented Interfaces:
    Serializable, ObjectResolver

    public class DirectoryEntryResolver
    extends AbstractObjectResolver
    implements ObjectResolver
    This ObjectResolver allows to manage integrity for fields containing references to directory's entry.

    References contains the directory entry id.

    To use it, put the following code in your schema XSD (don't forget the directory name):

     <xs:element name="carBrand">
         <xs:restriction base="xs:string" ref:resolver="directoryResolver" ref:directory="carBrandsDirectory" />

    For hierarchical directories, which entries reference other entries. You can manage a specific reference containing the full entry path. You have to specify the parent field and the separator used to encode the reference.

     <xs:element name="coverage">
         <xs:restriction base="xs:string" ref:resolver="directoryResolver" ref:directory="l10ncoverage" ref:parentField="parent" ref:separator="/" />

    It's not necessary to define parentField and separator for directory using schema ending by xvocabulary. The feature is automatically enable.

    See Also:
    Serialized Form