{"id":5525,"date":"2016-07-08T08:12:54","date_gmt":"2016-07-07T23:12:54","guid":{"rendered":"http:\/\/blog.antenna.co.jp\/ILSoft2\/?p=5525"},"modified":"2016-07-08T08:12:54","modified_gmt":"2016-07-07T23:12:54","slug":"xslt%e3%82%92%e5%ad%a6%e3%81%b6%e3%80%80%ef%bc%8810%ef%bc%89%e5%bc%8f%e3%81%ab%e3%82%88%e3%82%8b%e3%83%8e%e3%83%bc%e3%83%89%e9%9b%86%e5%90%88%e3%81%ae%e4%bd%9c%e6%88%90%e3%80%81%e3%83%8e%e3%83%bc","status":"publish","type":"post","link":"https:\/\/blog.antenna.co.jp\/ILSoft2\/archives\/5525\/","title":{"rendered":"XSLT\u3092\u5b66\u3076\u3000\uff0810\uff09\u5f0f\u306b\u3088\u308b\u30ce\u30fc\u30c9\u96c6\u5408\u306e\u4f5c\u6210\u3001\u30ce\u30fc\u30c9\u96c6\u5408\u306e\u548c\u96c6\u5408\u3001\u30d5\u30a3\u30eb\u30bf\u30fc\u5f0f"},"content":{"rendered":"<p>\u524d\u56de<sup>[1]<\/sup>\u306e\u5b9a\u7fa9[19]\u306b\u3042\u308b\u3088\u3046\u306b\u30ed\u30b1\u30fc\u30b7\u30e7\u30f3\u30d1\u30b9\u3092\u30d1\u30b9\u5f0f\u3068\u3057\u3066\u4f7f\u3046\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u305d\u306e\u3068\u304d\u30d1\u30b9\u5f0f\u306f\u30ed\u30b1\u30fc\u30b7\u30e7\u30f3\u30d1\u30b9\u306b\u3088\u3063\u3066\u9078\u629e\u3057\u305f\u30ce\u30fc\u30c9\u306e\u96c6\u5408\u3092\u8fd4\u3057\u307e\u3059\u3002<\/p>\n<p>\u30ce\u30fc\u30c9\u306e\u96c6\u5408\u306f\u3001&#8217;|&#8217;\u30aa\u30da\u30ec\u30fc\u30bf\u3067\u548c\u96c6\u5408\u306b\u3067\u304d\u307e\u3059\uff08\u524d\u56de\u306e\u5b9a\u7fa9[18]\uff09\u3002\u5b9a\u7fa9[18]\u3060\u3051\u3067\u306f\u5206\u304b\u308a\u307e\u305b\u3093\u304c\u3001XPath\u4ed5\u69d8\u66f8<sup>[2]<\/sup>\u306b\u306f\u300c\u30aa\u30da\u30e9\u30f3\u30c9\u306f\u30ce\u30fc\u30c9\u96c6\u5408\u3067\u306a\u3051\u308c\u3070\u306a\u3089\u306a\u3044\u300d\u3068\u3055\u308c\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u4ee5\u4e0a\u306b\u3088\u308a\u3001<strong>\u5f0f<\/strong>\u306e\u4e2d\u3067\u306f\u3001\u30ed\u30b1\u30fc\u30b7\u30e7\u30f3\u30d1\u30b9\u3067\u30ce\u30fc\u30c9\u96c6\u5408\u3092\u4f5c\u308a\u3001\u30ce\u30fc\u30c9\u96c6\u5408\u306e\u548c\u96c6\u5408\u3092\u4f5c\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<p>\u5b9a\u7fa9[19]\u3067\u306f\u3001\u30d1\u30b9\u5f0f\u306e\u751f\u6210\u65b9\u6cd5\u306bFilterExpr\uff08\u30d5\u30a3\u30eb\u30bf\u30fc\u5f0f\uff09\u3092\u4f7f\u3046\u65b9\u6cd5\u3082\u3042\u308a\u307e\u3059\u3002\u30d5\u30a3\u30eb\u30bf\u30fc\u5f0f\u306b\u306f\u3001FilterExpr\u306e\u5f8c\u306b\u8ff0\u90e8\uff08Predicate\uff09\u3092\u4ed8\u3051\u308b\u3082\u306e\u304c\u3042\u308a\u307e\u3059\u3002\u3053\u306e\u3068\u304d\u306e\u8ff0\u90e8\u306f\u300c\u30ed\u30b1\u30fc\u30b7\u30e7\u30f3\u30d1\u30b9\u3067\u4f7f\u308f\u308c\u308b\u3068\u304d\u3068\u540c\u69d8\u306b\u5f0f\u3092\u30d5\u30a3\u30eb\u30bf\u30fc\u3059\u308b\u305f\u3081\u306b\u4f7f\u308f\u308c\u308b\u3002\u30d5\u30a3\u30eb\u30bf\u30fc\u3055\u308c\u308b\u5f0f\u304c\u30ce\u30fc\u30c9\u96c6\u5408\u306b\u306a\u3089\u306a\u3051\u308c\u3070\u30a8\u30e9\u30fc\u3068\u306a\u308b\u3002\u8ff0\u90e8\u306f\u3001\u30ce\u30fc\u30c9\u96c6\u5408\u3092child\u8ef8\u306b\u95a2\u3057\u3066\u30d5\u30a3\u30eb\u30bf\u30fc\u3059\u308b\u300d\u3068\u3055\u308c\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u3064\u307e\u308a\u3001\u30d1\u30b9\u5f0f\u304cFilterExpr Predicate\u3067\u751f\u6210\u3055\u308c\u308b\u3068\u304d\u3001FilterExpr\u306f\u30ce\u30fc\u30c9\u96c6\u5408\u3067\u306a\u3051\u308c\u3070\u306a\u308a\u307e\u305b\u3093\u3002<\/p>\n<p>FilterExpr\u306f\u57fa\u672c\u5f0f\uff08PrimaryExpr\uff09\u3067\u69cb\u6210\u3055\u308c\u307e\u3059\u3002\u57fa\u672c\u5f0f\u306e\u4e2d\u3067\u30ce\u30fc\u30c9\u96c6\u5408\u3092\u751f\u6210\u3067\u304d\u308b\u306e\u306f\u3001VariableReference\uff08\u5909\u6570\u53c2\u7167\uff09\u3001()\u3067\u56f2\u3063\u305f\u5f0f\u3001FunctionCall\u3067\u3059\u3002<\/p>\n<p>[15] PrimaryExpr ::= VariableReference<br \/>\n| \u2018(\u2018 Expr \u2018)\u2019<br \/>\n| Literal<br \/>\n| Number<br \/>\n| FunctionCall <\/p>\n<p>\u524d\u56de\u8ff0\u90e8\u306b\u4e8c\u7a2e\u985e\u3042\u308b\u3053\u3068\u306b\u6ce8\u610f\u3057\u307e\u3057\u305f\u304c\u3001\u3053\u306e\u9055\u3044\u306f()\u3067\u56f2\u3063\u305f\u5f0f\u3068\u7d44\u307f\u5408\u308f\u305b\u308b\u3068\u660e\u78ba\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>XML\u6587\u66f8\u4e2d\u3067\u3001\u4f8b\u3048\u3070p\u304c\u8981\u7d20\u30ce\u30fc\u30c9\u3067\u3042\u308b\u3068\u304d\u3001\u30d1\u30b9\u5f0fp\uff08child::p\uff09\u81ea\u4f53\u306f\u57fa\u672c\u5f0f\u3067\u306f\u3042\u308a\u307e\u305b\u3093\u304c\u3001(p)\u306f\u57fa\u672c\u5f0f\u3067\u3059\u3002<\/p>\n<p>\u8ff0\u90e8[]\u3068\u7d44\u307f\u5408\u308f\u305b\u305f\u3068\u304d\u3001\u6b21\u306e\u4e8c\u7a2e\u985e\u3068\u306a\u308a\u307e\u3059\u3002<br \/>\n(1) p[1]\u306f\u30b9\u30c6\u30c3\u30d7\u3067\u3042\u308a\u3001\u30ed\u30b1\u30fc\u30b7\u30e7\u30f3\u30d1\u30b9\u3067\u3059\u3002<br \/>\n(2) \u305d\u308c\u306b\u5bfe\u3057\u3066\u3001(p)[1]\u306f\u30d5\u30a3\u30eb\u30bf\u30fc\u5f0f\u3067\u3059\u3002<\/p>\n<p>\u3053\u306e\u5834\u5408\u306f\u9055\u3044\u306f\u660e\u78ba\u3067\u306f\u3042\u308a\u307e\u305b\u3093\u304c\u3001\u6b21\u306e\u3088\u3046\u306a\u5834\u5408\u306f\u9055\u3044\u304c\u660e\u78ba\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<p><strong>preceding::foo[1] \u3068(preceding::foo)[1]\u306e\u6bd4\u8f03 <\/strong><\/p>\n<p>preceding\u8ef8\u306e\u5b9a\u7fa9\u306f\u6b21\u306e\u3088\u3046\u306b\u306a\u3063\u3066\u3044\u307e\u3059\u3002\u300c\u8d77\u70b9\u30ce\u30fc\u30c9\u3068\u540c\u3058\u6587\u66f8\u306e\u4e2d\u3067\u3001\u6587\u66f8\u9806\u3067\u8d77\u70b9\u30ce\u30fc\u30c9\u306e\u524d\u306b\u3042\u308b\u3059\u3079\u3066\u306e\u30ce\u30fc\u30c9\u3092\u542b\u307f\u307e\u3059\u3002\u4f46\u3057\u3001\u5148\u7956\u3068\u5c5e\u6027\u30ce\u30fc\u30c9\u3068\u540d\u524d\u7a7a\u9593\u30ce\u30fc\u30c9\u306f\u9664\u5916\u3057\u307e\u3059\u3002\u300d(XPath 2.2 Axes)<\/p>\n<p>\u8ef8\u306b\u306f\u6587\u66f8\u9806\u306e\u8ef8\u3068\u3001\u9006\u6587\u66f8\u9806\u306e\u8ef8\u304c\u3042\u308a\u307e\u3059\u3002\u8d77\u70b9\u30ce\u30fc\u30c9\u3068\u8d77\u70b9\u30ce\u30fc\u30c9\u3088\u308a\u3082\u6587\u66f8\u306e\u4e2d\u3067\u5f8c\u306e\u30ce\u30fc\u30c9\u3092\u542b\u3080\u8ef8\u306f\u6587\u66f8\u9806\u306e\u8ef8\u3067\u3059\u3002\u8d77\u70b9\u30ce\u30fc\u30c9\u3068\u8d77\u70b9\u30ce\u30fc\u30c9\u3088\u308a\u3082\u6587\u66f8\u306e\u4e2d\u3067\u524d\u65b9\u306e\u30ce\u30fc\u30c9\u3092\u542b\u3080\u8ef8\u306f\u9006\u9806\u306e\u8ef8\u3067\u3059\u3002preceding\u8ef8\u306f\u3001\u9006\u9806\u306e\u8ef8\u306b\u5c5e\u3057\u307e\u3059\uff08XPath 2.4 Predicates\uff09\u3002<\/p>\n<p>\u30ce\u30fc\u30c9\u96c6\u5408\u306e\u30e1\u30f3\u30d0\u30fc\u306e\u8ef8\u306b\u95a2\u3059\u308b<strong>\u8fd1\u63a5\u4f4d\u7f6e<\/strong>\uff08proximity position\uff09\u3068\u306f\u3001\u6587\u66f8\u9806\u306e\u8ef8\u3067\u306f\u30e1\u30f3\u30d0\u30fc\u3092\u6587\u66f8\u9806\u306b\u4e26\u3079\u305f\u3068\u304d\u306e\u9806\u756a\u3001\u9006\u9806\u306e\u8ef8\u3067\u306f\u6587\u66f8\u3067\u51fa\u73fe\u3059\u308b\u9806\u5e8f\u306e\u9006\u306b\u4e26\u3079\u305f\u3068\u304d\u306e\u9806\u756a\u3067\u3059\u3002<\/p>\n<p>\u305d\u3057\u3066\u3001\u8ff0\u90e8[]\u306f\u30ce\u30fc\u30c9\u96c6\u5408\u3092\u7d5e\u308a\u8fbc\u3093\u3067\u65b0\u3057\u3044\u30ce\u30fc\u30c9\u96c6\u5408\u3092\u4f5c\u308a\u307e\u3059\u3002\u8ff0\u90e8\u306e\u4e2d\u306e\u5f0f\u306f\u3001\u30ce\u30fc\u30c9\u96c6\u5408\u306e\u5404\u30ce\u30fc\u30c9\u3092\u8d77\u70b9\u306e\u30ce\u30fc\u30c9\u3068\u3057\u3001\u8fd1\u63a5\u4f4d\u7f6e\u3092\u6587\u8108\u4f4d\u7f6e\u3068\u3057\u3066\u8a55\u4fa1\u3057\u307e\u3059\u3002\u8a55\u4fa1\u7d50\u679c\u304c\u771f\u3067\u3042\u308c\u3070\u3001\u305d\u306e\u30ce\u30fc\u30c9\u306f\u65b0\u3057\u3044\u30ce\u30fc\u30c9\u96c6\u5408\u306b\u542b\u307e\u308c\u307e\u3059\u3002<\/p>\n<p>\u305d\u3053\u3067\u3001preceding::foo[1] \u306f\u8d77\u70b9\u30ce\u30fc\u30c9\u306e\u5148\u884c\u30ce\u30fc\u30c9\u3067\u3042\u308bfoo\u8981\u7d20\u30ce\u30fc\u30c9\u3092\u6587\u66f8\u306e\u9006\u9806\u306b\u305f\u3069\u308a\u3001\u305d\u306e\u3068\u304d\u306e1\u756a\u76ee\u306efoo\u8981\u7d20\u30ce\u30fc\u30c9\u3092\u9078\u629e\u3057\u307e\u3059\u3002<\/p>\n<p>(preceding::foo)[1] \u306f[1]\u306b\u9069\u7528\u3059\u308b\u8ef8\u306fchild\u8ef8\u306a\u306e\u3067\u5148\u884c\u30ce\u30fc\u30c9\u3067\u3042\u308bfoo\u8981\u7d20\u306e\u96c6\u5408\u306e\u6700\u521d\u306e\u30ce\u30fc\u30c9\u3092\u9078\u629e\u3057\u307e\u3059<sup>[3]<\/sup>\u3002<\/p>\n<p>[1] <a href=\"http:\/\/192.168.16.141\/ILSoft2\/archives\/5480\">XSLT\u3092\u5b66\u3076\uff089\uff09\u30b9\u30c6\u30c3\u30d7\u306e\u6587\u6cd5\u3092\u8ffd\u6c42\u3059\u308b-\u8ff0\u90e8\uff08Predicates\uff09\u3068\u5f0f<\/a><br \/>\n[2] <a href=\"https:\/\/www.w3.org\/TR\/xpath\/\">XML Path Language (XPath) Version 1.0<\/a><br \/>\n[3] <a href=\"https:\/\/www.w3.org\/TR\/xpath\/#node-sets\">3.3 Node-sets<\/a>\u306b\u306f\u3001\u3053\u306e\u3088\u3046\u306b\u66f8\u304b\u308c\u3066\u3044\u307e\u3059\u3002\u3061\u3087\u3063\u3068\u5f37\u5f01\u306e\u5370\u8c61\u304c\u3042\u308a\u307e\u3059\u304c\u3002<\/p>\n<p>\u3010\u5e83\u544a\u3011<br \/>\n<a href=\"https:\/\/www.antenna.co.jp\/epub\/ebookservice_casestudy.html#printbook\">Formatter\uff08XML\uff09\u95a2\u9023\u6280\u8853\u66f8\u3001PDF\u95a2\u9023\u66f8\u7c4d\u3054\u7d39\u4ecb<\/a><\/p>\n<p style=\"color: orange; font-style: italic;\">\u6b21\u56de:<br \/>\n<a href=\"http:\/\/192.168.16.141\/ILSoft2\/archives\/5513\">XSLT\u3092\u5b66\u3076 \uff0811\uff09\u8ad6\u7406\u5024\uff08Boolean\uff09\u3068\u95a2\u9023\u3059\u308b\u57fa\u672c\u7684\u306a\u95a2\u6570\u306e\u3044\u304f\u3064\u304b<\/a><\/p>\n<p style=\"color:orange;font-style:italic;\">\u524d\u56de:<br \/>\n<a href=\"http:\/\/192.168.16.141\/ILSoft2\/archives\/5480\">XSLT\u3092\u5b66\u3076\uff089\uff09\u30b9\u30c6\u30c3\u30d7\u306e\u6587\u6cd5\u3092\u8ffd\u6c42\u3059\u308b-\u8ff0\u90e8\uff08Predicates\uff09\u3068\u5f0f<\/a>\n<\/p>\n<p style=\"color: green; font-style: italic;\">\u521d\u56de:<br \/>\n<a href=\"http:\/\/192.168.16.141\/ILSoft2\/archives\/5113\">XSLT\u3092\u5b66\u3076\uff081\uff09XML\u306e\u30c4\u30ea\u30fc\u30e2\u30c7\u30eb\u3068XPath\/XSLT\u306e\u30c4\u30ea\u30fc\u30e2\u30c7\u30eb\u3067\u306f\u30eb\u30fc\u30c8\u306e\u610f\u5473\u304c\u9055\u3046<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u524d\u56de[1]\u306e\u5b9a\u7fa9[19]\u306b\u3042\u308b\u3088\u3046\u306b\u30ed\u30b1\u30fc\u30b7\u30e7\u30f3\u30d1\u30b9\u3092\u30d1\u30b9\u5f0f\u3068\u3057\u3066\u4f7f\u3046\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u305d\u306e\u3068\u304d\u30d1\u30b9\u5f0f\u306f\u30ed\u30b1\u30fc\u30b7\u30e7\u30f3\u30d1\u30b9\u306b\u3088\u3063\u3066\u9078\u629e\u3057\u305f\u30ce\u30fc\u30c9\u306e\u96c6\u5408\u3092\u8fd4\u3057\u307e\u3059\u3002 \u30ce\u30fc\u30c9\u306e\u96c6\u5408\u306f\u3001&#8217;|&#8217;\u30aa\u30da\u30ec\u30fc\u30bf\u3067\u548c [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[25,16],"tags":[52,257,258,597],"class_list":["post-5525","post","type-post","status-publish","format-standard","hentry","category-ah-formatter","category-structured-doc","tag-ah-formatter","tag-xmlpath","tag-xpath","tag-597"],"_links":{"self":[{"href":"https:\/\/blog.antenna.co.jp\/ILSoft2\/wp-json\/wp\/v2\/posts\/5525","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.antenna.co.jp\/ILSoft2\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.antenna.co.jp\/ILSoft2\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.antenna.co.jp\/ILSoft2\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.antenna.co.jp\/ILSoft2\/wp-json\/wp\/v2\/comments?post=5525"}],"version-history":[{"count":0,"href":"https:\/\/blog.antenna.co.jp\/ILSoft2\/wp-json\/wp\/v2\/posts\/5525\/revisions"}],"wp:attachment":[{"href":"https:\/\/blog.antenna.co.jp\/ILSoft2\/wp-json\/wp\/v2\/media?parent=5525"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.antenna.co.jp\/ILSoft2\/wp-json\/wp\/v2\/categories?post=5525"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.antenna.co.jp\/ILSoft2\/wp-json\/wp\/v2\/tags?post=5525"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}