You can subscribe to this list here.
2001 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
(22) |
Jul
(4) |
Aug
(9) |
Sep
(6) |
Oct
(5) |
Nov
(15) |
Dec
(4) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2002 |
Jan
(4) |
Feb
(10) |
Mar
(12) |
Apr
(16) |
May
(2) |
Jun
(7) |
Jul
(10) |
Aug
(9) |
Sep
(3) |
Oct
(17) |
Nov
(17) |
Dec
(6) |
2003 |
Jan
(12) |
Feb
(15) |
Mar
(25) |
Apr
(20) |
May
(8) |
Jun
(3) |
Jul
(21) |
Aug
(10) |
Sep
(7) |
Oct
(1) |
Nov
(3) |
Dec
(6) |
2004 |
Jan
(5) |
Feb
(16) |
Mar
(34) |
Apr
(26) |
May
(20) |
Jun
(58) |
Jul
(76) |
Aug
(51) |
Sep
(40) |
Oct
(16) |
Nov
(7) |
Dec
(6) |
2005 |
Jan
(10) |
Feb
(1) |
Mar
(17) |
Apr
(8) |
May
(11) |
Jun
(15) |
Jul
(1) |
Aug
(7) |
Sep
(6) |
Oct
(10) |
Nov
(14) |
Dec
(9) |
2006 |
Jan
(11) |
Feb
(22) |
Mar
(17) |
Apr
(1) |
May
(15) |
Jun
(9) |
Jul
(4) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2007 |
Jan
|
Feb
(10) |
Mar
|
Apr
|
May
(2) |
Jun
|
Jul
(1) |
Aug
|
Sep
|
Oct
(4) |
Nov
|
Dec
|
2008 |
Jan
(2) |
Feb
(1) |
Mar
(8) |
Apr
(8) |
May
(12) |
Jun
(9) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2010 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(2) |
2012 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
|
Nov
|
Dec
|
2013 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: fabien b. <fab...@gm...> - 2006-05-29 19:45:10
|
Hello, I'm currently in study in a french university and i have to develop a tool with java and the API TM4j to purpose a view of informations contained in a Topic Map. The tool may realize an informations view in a theme way. So i think i have to use scope but i don't know the way to extract all scopes from a topic map... I post here hopping to get a little algorithme to just extract scopes, or to get some informations about scopes. Please i need some help Ema |
From: <mag...@st...> - 2006-05-29 11:53:44
|
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Kal Ahmed wrote: > Agreed the security could be made tighter. I think that the goal of this > document is about how to get something up and running in a development > environment rather than how to get a live deployment running. To be > honest, I still think of the Hibernate backend as a development > environment as it has so many flaws (like not supporting tolog querying > and being s-l-o-o-o-w). ...so I migth be better off just using the In-memory Backend? > I would be happy to see someone write a proper installation guide for > TM4J/Hibernate/MySQL (I guess that MySQL would be the most commonly used > database), but preferably in Docbook format so that it could go into the > rest of the "standard" docs. > > Cheers > > Kal > > Magnus Folgerø wrote: > I've just read through the > http://tm4j.org/tm4j/docs/install_hibernate.txt and I think there's > something fishy about some of the stuff in there: > > ---------------- > mysql> GRANT ALL PRIVILEGES ON *.* TO 'tm4j'@'localhost' > -> IDENTIFIED BY 'some_pass' WITH GRANT OPTION; > mysql> GRANT ALL PRIVILEGES ON *.* TO 'tm4j'@'%' > -> IDENTIFIED BY 'some_pass' WITH GRANT OPTION; > ---------------- > > I can't see why tm4j should get root privileges? Wouldn't it be better > to grant tm4j access to the database tm4j (tm4j.*) and create this db > before granting privileges to users, and not afterwards like in the > howto? > Further, it should be pointed out that granting access to tm4j@'%' is > _only_ necessary if the db is not running at localhost. > > -- > best regards > Magnus >> >> - ------------------------------------------------------- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnk&kid=107521&bid=248729&dat=121642 _______________________________________________ Tm4j-users mailing list Tm4...@li... https://lists.sourceforge.net/lists/listinfo/tm4j-users >> >> > ------------------------------------------------------- > All the advantages of Linux Managed Hosting--Without the Cost and Risk! > Fully trained technicians. The highest number of Red Hat certifications in > the hosting industry. Fanatical Support. Click to learn more > http://sel.as-us.falkag.net/sel?cmd=k&kid7521&bid$8729&dat1642 > _______________________________________________ > Tm4j-users mailing list > Tm4...@li... > https://lists.sourceforge.net/lists/listinfo/tm4j-users -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2.2 (GNU/Linux) Comment: Using GnuPG with Mandriva - http://enigmail.mozdev.org iD8DBQFEeuC9B6/gap0IM6sRAjacAJ9JDyBXgkoSNT9GDhUvRz0IPFmWaQCfVUjw IcAxfLO5qSVjAoKAOr9+Jek= =fB9i -----END PGP SIGNATURE----- |
From: Kal A. <ka...@te...> - 2006-05-29 11:39:19
|
Hi Dandan, The default sorting algorithm is not exactly clever - if you sort a variable that binds to TopicMapObjects (like $TYPE binds to Topics in your query), then the sort order is by the ID property of the topics. Are you seeing the results at least grouped together by type (even if the types are not necessarily in the order you expect) ? Or are you seeing them all mixed up ? Cheers Kal Wang, Dandan wrote: > Hi All, > > I am working on the Tolog Query implementation. My problem is, > the returned tolog resultsets can not be sorted , even if I use the > "order by" clause. > for example: > query = "select $TYPE, $VALUE from occurrence(topicID, $OCC),type($OCC, > $TYPE), value($OCC, $VALUE) order by $TYPE ?"; > > for this query, the returned tologResultSets showing in a JTable will > not be ordered by ascending $TYPE. > > I also did some similar experiments in the TMNav, seems it has the same > problem. > > I would appreciate if anybody could give me some hints.. > > > Dandan > |
From: Kal A. <ka...@te...> - 2006-05-29 11:34:32
|
Agreed the security could be made tighter. I think that the goal of this=20 document is about how to get something up and running in a development=20 environment rather than how to get a live deployment running. To be=20 honest, I still think of the Hibernate backend as a development=20 environment as it has so many flaws (like not supporting tolog querying=20 and being s-l-o-o-o-w). I would be happy to see someone write a proper installation guide for=20 TM4J/Hibernate/MySQL (I guess that MySQL would be the most commonly used=20 database), but preferably in Docbook format so that it could go into the=20 rest of the "standard" docs. Cheers Kal Magnus Folger=F8 wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 >=20 > I've just read through the > http://tm4j.org/tm4j/docs/install_hibernate.txt and I think there's > something fishy about some of the stuff in there: >=20 > - ---------------- > mysql> GRANT ALL PRIVILEGES ON *.* TO 'tm4j'@'localhost' > -> IDENTIFIED BY 'some_pass' WITH GRANT OPTION; > mysql> GRANT ALL PRIVILEGES ON *.* TO 'tm4j'@'%' > -> IDENTIFIED BY 'some_pass' WITH GRANT OPTION; > - ---------------- >=20 > I can't see why tm4j should get root privileges? Wouldn't it be better > to grant tm4j access to the database tm4j (tm4j.*) and create this db > before granting privileges to users, and not afterwards like in the how= to? > Further, it should be pointed out that granting access to tm4j@'%' is > _only_ necessary if the db is not running at localhost. >=20 > - -- > best regards > Magnus > -----BEGIN PGP SIGNATURE----- > Version: GnuPG v1.4.2.2 (GNU/Linux) > Comment: Using GnuPG with Mandriva - http://enigmail.mozdev.org >=20 > iD8DBQFEdvWJB6/gap0IM6sRAjD+AJ0UzeEWYvWF3LzaxaudROcWpRAg6ACgk2XV > oq8lNr9a7bJfryZjAOOUSo0=3D > =3DJenl > -----END PGP SIGNATURE----- >=20 >=20 > ------------------------------------------------------- > All the advantages of Linux Managed Hosting--Without the Cost and Risk! > Fully trained technicians. The highest number of Red Hat certifications= in > the hosting industry. Fanatical Support. Click to learn more > http://sel.as-us.falkag.net/sel?cmd=3Dlnk&kid=3D107521&bid=3D248729&dat= =3D121642 > _______________________________________________ > Tm4j-users mailing list > Tm4...@li... > https://lists.sourceforge.net/lists/listinfo/tm4j-users >=20 >=20 |
From: <mag...@st...> - 2006-05-26 12:33:24
|
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 I've just read through the http://tm4j.org/tm4j/docs/install_hibernate.txt and I think there's something fishy about some of the stuff in there: - ---------------- mysql> GRANT ALL PRIVILEGES ON *.* TO 'tm4j'@'localhost' -> IDENTIFIED BY 'some_pass' WITH GRANT OPTION; mysql> GRANT ALL PRIVILEGES ON *.* TO 'tm4j'@'%' -> IDENTIFIED BY 'some_pass' WITH GRANT OPTION; - ---------------- I can't see why tm4j should get root privileges? Wouldn't it be better to grant tm4j access to the database tm4j (tm4j.*) and create this db before granting privileges to users, and not afterwards like in the howto? Further, it should be pointed out that granting access to tm4j@'%' is _only_ necessary if the db is not running at localhost. - -- best regards Magnus -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2.2 (GNU/Linux) Comment: Using GnuPG with Mandriva - http://enigmail.mozdev.org iD8DBQFEdvWJB6/gap0IM6sRAjD+AJ0UzeEWYvWF3LzaxaudROcWpRAg6ACgk2XV oq8lNr9a7bJfryZjAOOUSo0= =Jenl -----END PGP SIGNATURE----- |
From: Lars H. <he...@se...> - 2006-05-24 15:05:28
|
This msg does not appear in my mailbox. Sent yesterday. This is a forwarded message ===8<==============Original message text=============== Hi, >> If I want to know whether there exists any association between two topics, >> how can I write the code using TMAPI? > One possibility: [...] Notes: a) The code tests if both topics are role _players_ in the same association and does not take care about the role type. b) Using a java.util.List instead of a Set might be faster. The duplicates (if any, since that means a topic plays more than one role in the same association) are acceptable Best regards, Lars -- http://semagia.com http://topicgarden.com/mailinglist/ German Topic Maps mailinglist ===8<===========End of original message text=========== |
From: Wang, D. <dwa...@ws...> - 2006-05-23 14:57:21
|
Hi All, =20 I am working on the Tolog Query implementation. My problem is, the returned tolog resultsets can not be sorted , even if I use the = "order by" clause. for example: query =3D "select $TYPE, $VALUE from occurrence(topicID, = $OCC),type($OCC, $TYPE), value($OCC, $VALUE) order by $TYPE ?";=20 =20 for this query, the returned tologResultSets showing in a JTable will = not be ordered by ascending $TYPE. =20 I also did some similar experiments in the TMNav, seems it has the same = problem. =20 I would appreciate if anybody could give me some hints.. =20 =20 Dandan =20 |
From: Lars H. <he...@se...> - 2006-05-23 12:57:55
|
Hi, > If I want to know whether there exists any association between two topics, > how can I write the code using TMAPI? One possibility: public static boolean partOfSameAssociation(Topic t1, Topic t2) { boolean result = false; Set<Association> assocs = new HashSet<Association>(); // First collect the associations where Topic t1 // plays a role for (Iterator iter = t1.getRolesPlayed().iterator(); iter.hasNext();) { AssociationRole role = (AssociationRole) iter.next(); assocs.add(role.getAssociation()); } // Then find out if t2 is part in one of the collected // associations. for (Iterator iter t2.getRolesPlayed().iterator(); iter.hasNext();) { AssociationRole role = (AssociationRole) iter.next(); result = assocs.contains(role.getAssociation()); if (result) { break; } } return result; } if (partOfSameAssociation(topic1, topic2)) { System.out.println("Association found"); } else { System.out.println("Association not found"); } Best regards, Lars -- http://semagia.com http://topicgarden.com/mailinglist/ German Topic Maps mailinglist |
From: <zt...@sw...> - 2006-05-23 12:20:31
|
Hello, If I want to know whether there exists any association between two topi= cs, how can I write the code using TMAPI? Thanks! zhouting |
From: Lars H. <he...@se...> - 2006-05-18 13:09:50
|
Hi, > I'm using the TMAPI and want to have the following codes be created. > <topic> > <occurrence> > <instanceOf> > <topicRef xlink href="#description"/> > </instanceOf> > <resourceData>chapter1</resourceData> > </occurrence> > </topic> The TMAPI code would look like: // Assuming that "tm" is your org.tmapi.core.TopicMap instance // Topic that should be used as type for the occurrence Topic descr = tm.createTopic(); // Creates a topic name with the value "description" in the // unconstrained scope descr.createTopicName("description", null); // The topic "t" is the topic that should contain the occurrence Topic t = tm.createTopic(); // Create the occurrence with type "descr" in the unconstrained // scope Occurrence occ = t.createOccurrence("chapter1", descr, null); [...] > I want to create the "occurrence" in Java but I have looked up the TMAPI > indexs and haven't find the appropriate method. Can you help me? Thanks! The TMAPI indexes are for lookup operations only. You cannot modify the topic map instance with the indexes. Best regards, Lars -- http://semagia.com http://topicgarden.com/mailinglist/ German Topic Maps mailinglist |
From: <zt...@sw...> - 2006-05-18 09:09:38
|
Hello, I'm using the TMAPI and want to have the following codes be created. <topic> <occurrence> <instanceOf> <topicRef xlink href=3D"#description"/> </instanceOf> <resourceData>chapter1</resourceData> </occurrence> </topic> <topic> <baseName> <baseNameString>description</baseNameString> </baseName> </topic> I want to create the "occurrence" in Java but I have looked up the TMAP= I indexs and haven't find the appropriate method. Can you help me? Thanks! zhouting |
From: Lars H. <he...@se...> - 2006-05-17 15:52:20
|
Hi, [...] > I am a beginner in the use of tm4j and come across some problems. When I use > Java to parse my XTM file and want to extract the elements like > "assotiation","occurrence"etc, which function should I use? And where can I > find such functions? Which API are you using? If you're using the native TM4J API, you can use the objects and their methods here: http://tm4j.org/tm4j/docs/apiDocs/org/tm4j/topicmap/package-summary.html If you're using TMAPI you can use the objects / methods documented here: http://tmapi.org/apiDocs/index.html If you provide an use case I'll give you an example. Best regards, Lars -- http://semagia.com http://topicgarden.com/mailinglist/ German Topic Maps mailinglist |
From: <zt...@sw...> - 2006-05-15 03:54:27
|
Hello, I'm trying to put the elements parsing from the XTM file into my databa= se using Java, but some errors always occur. It is just like "[Microsoft][OD= BC Microsoft Access Driver] INSERT INTO has the syntax error". I don't know why. Thanks! zhouting |
From: <zt...@sw...> - 2006-05-13 01:01:17
|
Hello, I am a beginner in the use of tm4j and come across some problems. When = I use Java to parse my XTM file and want to extract the elements like "assotiation","occurrence"etc, which function should I use? And where can= I find such functions? Thanks in advance! zhouting |
From: Thomas M. <th...@sn...> - 2006-04-08 12:03:26
|
Hi, I want to look up all topics that have a certain subject indicator. While this works without problems with the in-memory backend, there seems to be no elegant solution for the Hibernate backend: // using Hibernate provider... LocatorFactory lf = provider.getLocatorFactory(); Locator psiSynonym = lf.createLocator( "URI", PSI_SYNONYM ); TopicMap tm; // ... Collection c = tm.getUtils().getMembersOfType( topic, psiSynonym ); The last line causes a ClassCastException with the Hibernate backend... because the Hibernate implementation of getMembersOfType() uses a cast to URILocatorImpl on the Locator object: LocatorDataObject ldo = (LocatorDataObject) sess.load( LocatorDataObject.class, ====> ((URILocatorImpl) subjectOrIndicator) .getPersistenceId()); But createLocator() returns instances of TransientURILocatorImpl, so this cannot work. I've found a workaround by using an implementation specific call to create suitable Locator instances: if (lf instanceof org.tm4j.topicmap.hibernate.LocatorFactoryImpl) { psiSynonym = ((org.tm4j.topicmap.hibernate.LocatorFactoryImpl)lf) .createPersistentLocator( "URI", PSI_SYNONYM ); } else { psiSynonym = lf.createLocator( "URI", PSI_SYNONYM ); } This works (and TM4J uses the same "trick" in its getSubClasses/getSuperClasses methods), but it does not seem elegant to me (it relies on the implementation instead of a public interface). Is there a better solution that uses only public API and does not depend on a certain implementation? bye, Thomas |
From: Kal A. <ka...@te...> - 2006-03-23 09:05:31
|
Hi Magnus If you have the source version of TM4J 0.9.7, you will need to compile=20 that first - it should be as simple as executing ant with no parameters=20 in the tm4j-0.9.7 directory. Hope this helps Kal Magnus Folger=F8 wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 >=20 > I'm trying to get tm4web to work, but I guess I have to do some initial > work with tm4j.. how do I build the files under tm4j-0.9.7/build/lib ? >=20 > output: >=20 > $ ant -f batch.xml -Dtopicmap=3Dtmworld.xtm topicmap > Buildfile: batch.xml >=20 > topicmap: > [mkdir] Created dir: > /home/mags/Documents/haupt/tm4j/tm4web/build/batch/temp > [mkdir] Created dir: > /home/mags/Documents/haupt/tm4j/tm4web/build/batch/html > [mkdir] Created dir: > /home/mags/Documents/haupt/tm4j/tm4web/build/batch/img > [mkdir] Created dir: > /home/mags/Documents/haupt/tm4j/tm4web/build/batch/css > [copy] Copying 1 file to > /home/mags/Documents/haupt/tm4j/tm4web/build/batch/temp > [copy] Copying 13 files to > /home/mags/Documents/haupt/tm4j/tm4web/build/batch/temp >=20 > BUILD FAILED > /home/mags/Documents/haupt/tm4j/tm4web/batch.xml:69: > /home/mags/Documents/haupt/tm4j/tm4j-0.9.7/build/lib not found. >=20 > Total time: 5 seconds > -----BEGIN PGP SIGNATURE----- > Version: GnuPG v1.4.2.2 (GNU/Linux) > Comment: Using GnuPG with Mandriva - http://enigmail.mozdev.org >=20 > iD8DBQFEITwMB6/gap0IM6sRArW5AJ9MkXyRNBK0YKiA+IvaiFQ+diP0kgCgmoaU > FWi59JYGhZSi3nlV2GdiPGk=3D > =3DBSjX > -----END PGP SIGNATURE----- >=20 >=20 > ------------------------------------------------------- > This SF.Net email is sponsored by xPML, a groundbreaking scripting lang= uage > that extends applications into web and mobile media. Attend the live we= bcast > and join the prime developer group breaking into this new coding territ= ory! > http://sel.as-us.falkag.net/sel?cmd=3Dlnk&kid=3D110944&bid=3D241720&dat= =3D121642 > _______________________________________________ > Tm4j-users mailing list > Tm4...@li... > https://lists.sourceforge.net/lists/listinfo/tm4j-users >=20 >=20 |
From: <mag...@st...> - 2006-03-22 11:58:17
|
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 I'm trying to get tm4web to work, but I guess I have to do some initial work with tm4j.. how do I build the files under tm4j-0.9.7/build/lib ? output: $ ant -f batch.xml -Dtopicmap=tmworld.xtm topicmap Buildfile: batch.xml topicmap: [mkdir] Created dir: /home/mags/Documents/haupt/tm4j/tm4web/build/batch/temp [mkdir] Created dir: /home/mags/Documents/haupt/tm4j/tm4web/build/batch/html [mkdir] Created dir: /home/mags/Documents/haupt/tm4j/tm4web/build/batch/img [mkdir] Created dir: /home/mags/Documents/haupt/tm4j/tm4web/build/batch/css [copy] Copying 1 file to /home/mags/Documents/haupt/tm4j/tm4web/build/batch/temp [copy] Copying 13 files to /home/mags/Documents/haupt/tm4j/tm4web/build/batch/temp BUILD FAILED /home/mags/Documents/haupt/tm4j/tm4web/batch.xml:69: /home/mags/Documents/haupt/tm4j/tm4j-0.9.7/build/lib not found. Total time: 5 seconds -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2.2 (GNU/Linux) Comment: Using GnuPG with Mandriva - http://enigmail.mozdev.org iD8DBQFEITwMB6/gap0IM6sRArW5AJ9MkXyRNBK0YKiA+IvaiFQ+diP0kgCgmoaU FWi59JYGhZSi3nlV2GdiPGk= =BSjX -----END PGP SIGNATURE----- |
From: Richard G. <ric...@ya...> - 2006-03-22 11:47:07
|
There is devguide.pdf in the docs directory of the download. Cheers, Richard. --- Magnus Folgerø <mag...@st...> wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > Does anyone know if there exists a printer-friendly version of the "TM4J > Developer's Guide"? > > -----BEGIN PGP SIGNATURE----- > Version: GnuPG v1.4.2.2 (GNU/Linux) > Comment: Using GnuPG with Mandriva - http://enigmail.mozdev.org > > iD8DBQFEIThiB6/gap0IM6sRAsXAAKCramuJwBf6QyV2ZRkg3Lv94G9udQCggUKB > p6nzY2uaF3ZbIXL2svy47FE= > =sIQj > -----END PGP SIGNATURE----- > > > ------------------------------------------------------- > This SF.Net email is sponsored by xPML, a groundbreaking scripting language > that extends applications into web and mobile media. Attend the live webcast > and join the prime developer group breaking into this new coding territory! > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642 > _______________________________________________ > Tm4j-users mailing list > Tm4...@li... > https://lists.sourceforge.net/lists/listinfo/tm4j-users > ___________________________________________________________ To help you stay safe and secure online, we've developed the all new Yahoo! Security Centre. http://uk.security.yahoo.com |
From: <mag...@st...> - 2006-03-22 11:42:38
|
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Does anyone know if there exists a printer-friendly version of the "TM4J Developer's Guide"? -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2.2 (GNU/Linux) Comment: Using GnuPG with Mandriva - http://enigmail.mozdev.org iD8DBQFEIThiB6/gap0IM6sRAsXAAKCramuJwBf6QyV2ZRkg3Lv94G9udQCggUKB p6nzY2uaF3ZbIXL2svy47FE= =sIQj -----END PGP SIGNATURE----- |
From: Holger <hri...@ru...> - 2006-03-21 18:45:26
|
Hi Lars, thanks for your help. It works fine. I achieved some "dirty" solution in = the meanwhile - however it was not as stable and not as good as yours. ;-) Best regards, Holger -----Urspr=FCngliche Nachricht----- Von: Lars Heuer [mailto:he...@se...]=20 Gesendet: Dienstag, 21. M=E4rz 2006 18:32 An: hri...@ru...; tm4...@li... Betreff: Re: [TM4J-users] Using locale for scoped base names Hi, [...] > // Put this in one line > static final String TM_LANG =3D \\ > "http://www.topicmaps.org/xtm/1.0/language.xtm"; [...] Note: The "#" at the end is missing. Should be: static final String TM_LANG =3D \\ "http://www.topicmaps.org/xtm/1.0/language.xtm#"; Best regards, Lars --=20 http://semagia.com http://topicgarden.com/mailinglist/ German Topic Maps mailinglist |
From: Lars H. <he...@se...> - 2006-03-21 17:34:26
|
Hi, [...] > // Put this in one line > static final String TM_LANG = \\ > "http://www.topicmaps.org/xtm/1.0/language.xtm"; [...] Note: The "#" at the end is missing. Should be: static final String TM_LANG = \\ "http://www.topicmaps.org/xtm/1.0/language.xtm#"; Best regards, Lars -- http://semagia.com http://topicgarden.com/mailinglist/ German Topic Maps mailinglist |
From: Lars H. <he...@se...> - 2006-03-21 16:37:04
|
Hi Holger, [...] > Depending on the locale of the client=E2=80=99s system, the correct bas= e name > should be shown. [...] > There is a method 'addPreferredTheme(Topic theme)' in the > TopicNameExtractor-Class that I have been trying to use to solve that > problem. How about: static final String TM_LANG =3D "http://www.topicmaps.org/xtm/1.0/language.xtm" Locale locale =3D Locale.getDefault(); // Note that the ISO 639 is not stable String preferredLang =3D locale.getLanguage().equals("de") ? "de" : "en"; // Used to create the subject identifier String langReference =3D TM_LANG + preferredLang; // Subject identifier Locator langLocator =3D topicMap.getBaseLocator().resolveRelative(loc); // Fetch topic by the subject identifier Topic langTopic =3D topicMap.getTopicBySubjectIndicator(langLoc); if (langTopic =3D=3D null) { langTopic =3D topicMap.createTopic(); langTopic.addSubjectIndicator(langLocator); } nameExtractor.addPreferredTheme(langTopic); =20 Best regards, Lars --=20 http://semagia.com http://topicgarden.com/mailinglist/ German Topic Maps mailinglist |
From: Lars H. <he...@se...> - 2006-03-21 16:36:33
|
Hi, Code was wrong, here a slightly modified version. --- // Put this in one line static final String TM_LANG = \\ "http://www.topicmaps.org/xtm/1.0/language.xtm"; Locale locale = Locale.getDefault(); // Note that the ISO 639 is not stable String preferredLang = locale.getLanguage().equals("de") ? "de" : "en"; // Used to create the subject identifier String langRef = TM_LANG + preferredLang; // Subject identifier Locator langLoc = topicMap.getBaseLocator().resolveRelative(langRef); // Fetch topic by the subject identifier Topic langTopic = topicMap.getTopicBySubjectIndicator(langLoc); if (langTopic == null) { langTopic = topicMap.createTopic(); langTopic.addSubjectIndicator(langLoc); } nameExtractor.addPreferredTheme(langTopic); --- Best regards, Lars -- http://semagia.com http://topicgarden.com/mailinglist/ German Topic Maps mailinglist |
From: Lars H. <he...@se...> - 2006-03-21 16:34:47
|
Hi Carolina, [...] > static String query = "ned:Reglas-del- > Producto(i\"file:ned.xtm#packseguridadtotal\",$Reglas)?"; > qEvaluator.addRulesModule(new FileInputStream(new File("Functions.tl")),"ned"); > qEvaluator.execute(sQuery); I think you've discovered another tolog parser bug. Maybe it works if you use a double colon "::" between the "ned" namespace and the predicate name? Did you try to import the "Functions.tl" module via the "import" directive, too? Does the following work: static String "import \"file://Functions.tl\" as ned\n" + "ned::Reglas-del-Producto(i\"file:ned.xtm#packseguridadtotal\",$Reglas)?" ? Best regards, Lars -- http://semagia.com http://topicgarden.com/mailinglist/ German Topic Maps mailinglist |
From: <ca...@in...> - 2006-03-21 16:27:42
|
Hi Lars,=20 First of all, thank you for your answer.=20 I've been trying your suggestions and I step to comment my results: [...] > Maybe it works if you use a double colon "::" between the "ned" >namespace and the predicate name? [...] I tried this one first and it works!! :). It seems that when parsing = tolog queries, colons are eliminated -or something like that-, could it = be? As I can read, the tolog 1.0 specification establishes that this = query has to be written with a single colon. If this is a bug, do I have = to report it?=20 On the other hand, when I tried to use the "import" directive -as you = told me- I got an exception (posted below), similar to the exception = obtained when I tried to use de "using" directive. Thanks a lot again, Carolina Anton The exception: ------------------------------------------ org.tm4j.tologx.TologParserException: Error parsing query string. at = org.tm4j.tologx.memory.QueryEvaluatorImpl.prepareQuery(QueryEvaluatorImpl= .java:156) at = org.tm4j.tologx.memory.QueryEvaluatorImpl.execute(QueryEvaluatorImpl.java= :166) at = es.indra.druida.ned.mapa.GestorMapa.ejecutaConsulta(GestorMapa.java:89) at = es.indra.druida.ned.mapa.test.FicheroReglasTest.main(FicheroReglasTest.ja= va:30) Caused by: line 1:1: unexpected token: import at org.tm4j.tologx.parser.TologParser.query(TologParser.java:508) at = org.tm4j.tologx.memory.QueryEvaluatorImpl.prepareQuery(QueryEvaluatorImpl= .java:152) ... 3 more -----Mensaje original----- De: Lars Heuer [mailto:he...@se...]=20 Enviado el: martes, 21 de marzo de 2006 15:23 Para: Ant=F3n Garc=EDa, Carolina CC: tm4...@li... Asunto: Re: [TM4J-users] Problems using a rule from an added module Hi Carolina, [...] > static String query =3D "ned:Reglas-del- =20 > Producto(i\"file:ned.xtm#packseguridadtotal\",$Reglas)?"; > qEvaluator.addRulesModule(new FileInputStream(new = File("Functions.tl")),"ned"); > qEvaluator.execute(sQuery); I think you've discovered another tolog parser bug. Maybe it works if you use a double colon "::" between the "ned" namespace and the predicate name? Did you try to import the "Functions.tl" module via the "import" directive, too? Does the following work: static String "import \"file://Functions.tl\" as ned\n" + = "ned::Reglas-del-Producto(i\"file:ned.xtm#packseguridadtotal\",$Reglas)?"= ? =20 Best regards, Lars --=20 http://semagia.com http://topicgarden.com/mailinglist/ German Topic Maps mailinglist |