Return-Path: X-Original-To: apmail-incubator-clerezza-dev-archive@minotaur.apache.org Delivered-To: apmail-incubator-clerezza-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 7308E62D6 for ; Thu, 30 Jun 2011 14:47:53 +0000 (UTC) Received: (qmail 1367 invoked by uid 500); 30 Jun 2011 14:47:53 -0000 Delivered-To: apmail-incubator-clerezza-dev-archive@incubator.apache.org Received: (qmail 1283 invoked by uid 500); 30 Jun 2011 14:47:52 -0000 Mailing-List: contact clerezza-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: clerezza-dev@incubator.apache.org Delivered-To: mailing list clerezza-dev@incubator.apache.org Received: (qmail 1273 invoked by uid 99); 30 Jun 2011 14:47:52 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 30 Jun 2011 14:47:52 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 30 Jun 2011 14:47:49 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 07E0643CBD7 for ; Thu, 30 Jun 2011 14:47:29 +0000 (UTC) Date: Thu, 30 Jun 2011 14:47:29 +0000 (UTC) From: "Henry Story (JIRA)" To: clerezza-dev@incubator.apache.org Message-ID: <397111770.5704.1309445249029.JavaMail.tomcat@hel.zones.apache.org> In-Reply-To: <1501908294.30431.1304790483129.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Issue Comment Edited] (CLEREZZA-510) DSL for writing RDF elegantly MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/CLEREZZA-510?page=3Dcom.atlassi= an.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D13= 057854#comment-13057854 ]=20 Henry Story edited comment on CLEREZZA-510 at 6/30/11 2:46 PM: --------------------------------------------------------------- The Ascii Arrow notation is now the default. That is it is now possible to write rdf statements when needed in Scala cod= e in a way that is easy for humans to read and write, as it removes a lot o= f duplication. For examples see the Test Suite.=20 (sorry for edits, it does not look good in jira. There is no easy link from= the editing page to any markup notation) was (Author: bblfish): The Ascii Arrow notation is now the default. That is it is now possible to write rdf statements when needed in Scala cod= e in a way that is easy for humans to read and write, as it removes a lot o= f duplication. Here is an example from the Test Suite. (For Unicode and english language s= tyles examples see there too.) =09=09 val ez =3D EzGraph() =09=09 // example using arrows =09=09 ( =09=09 ez.b_("reto").a(FOAF.Person) =09=09=09 -- FOAF.name --> "Reto Bachman-Gm=C3=BCr".lang(rm) =09=09=09 -- FOAF.title --> "Mr" =09=09=09 -- FOAF.currentProject --> "http://clerezza.org/".uri =09=09=09 -- FOAF.knows --> ( =09=09=09 ez.u("http://bblfish.net/#hjs").a(FOAF.Person) =09=09=09 -- FOAF.name --> "Henry Story" =09=09=09 -- FOAF.currentProject --> "http://webid.info/".uri =09=09=09 -<- identity -- ( =09=09=09 ez.bnode.a(RSAPublicKey) //. notation because o= f precedence of operators =09=09=09 -- modulus --> 65537 =09=09=09 -- public_exponent --> (bblfishModulus^^hex= ) // brackets needed due to precedence =09=09=09 ) =09=09=09 -- FOAF.knows -->> List(ez.b_("reto").ref,ez.b_("danny")= .ref) =09=09=09 ) =09=09=09 -- FOAF.knows --> (ez.b_("danny").a(FOAF.Person) =09=09=09 -- FOAF.name --> "Danny Aye= rs".lang(en) =09=09 -- FOAF.knows --> "htt= p://bblfish.net/#hjs".uri //knows =09=09=09=09=09 -- FOAF.knows --> ez.b_("reto") =09=09=09 ) =09=09 ) =20 > DSL for writing RDF elegantly > ----------------------------- > > Key: CLEREZZA-510 > URL: https://issues.apache.org/jira/browse/CLEREZZA-510 > Project: Clerezza > Issue Type: New Feature > Reporter: Henry Story > Assignee: Henry Story > Attachments: NiceLookingGraphInScala.png > > > Writing RDF like=20 > graph.add(new TripleImp(Subj,rel,obj)) > is tedious to read and to write and makes every thing seem really heavy. = Make it look good. -- This message is automatically generated by JIRA. For more information on JIRA, see: http://www.atlassian.com/software/jira