从Perl哈希构建XML模式? [英] Building an XML Schema from a Perl Hash?

查看:138
本文介绍了从Perl哈希构建XML模式?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我们的应用程序的整个生命周期中,我们使用一个巨大的Perl哈希来存储所有细节。我们使用此散列中的数据来写入数据库中的XML文档。是否有可能通过此散列创建某种XML模式来验证数据库中的所有文档?有没有一个类似的Perl模块?

谢谢,

Kwalify Rx 是(Perl)数据结构的模式语言/验证器。



一个相关的有用工具是 dpath ,通过类似于XPath的语法访问数据结构中的项目。


We're using one huge Perl Hash throughout the life of our application to store all details. We use data in this hash to write to the XML documents in the database. Is it possible to create some sort of XML schema from this hash to validate all the documents in the database against? Is there a Perl module that does something similar?

Thanks,

解决方案

Kwalify and Rx are schema languages/validators for (Perl) data structures.

A related useful tool is dpath for accessing items in data structures with a syntax similar to XPath.

这篇关于从Perl哈希构建XML模式?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆