Excluding unreachable elements, issue #2

13 views
Skip to first unread message

Maloney, Christopher (NIH/NLM/NCBI) [C]

unread,
Sep 27, 2012, 4:51:11 PM9/27/12
to dtdan...@googlegroups.com

Hi Audrey,

 

I know we had talked about reusing my XQuery implementation to finding all the unreachable elements in a DTD, based on a given set of possible roots, but it didn’t seem like a good fit to me, so I implemented it in Java, as described here:  https://github.com/NCBITools/DtdAnalyzer/issues/2.

 

I reassigned this to you, so you can modify your documentor XSLT to drop all the elements that have reachable=”false”.  You might also want to make use of the root=”true” to call attention to this in the documentation page for the root elements, putting it in somewhere on the page.

 

The code is merged back into the master branch, so you should be able to do “git pull origin master” to get it.  Let me know if you get any kind of merge conflicts.

 

I also updated output format to match what we talked about before – no more <modules>.

 

 

Chris Maloney

NIH/NLM/NCBI (Contractor)

Building 45, 5AN.24D-22

301-594-2842

 

Audrey Hamelers

unread,
Sep 28, 2012, 1:20:44 PM9/28/12
to dtdan...@googlegroups.com, malo...@ncbi.nlm.nih.gov
Okay, will do. The documentation already displays tags, so if there's a "root" tag that'll show up, but I'll also put some kind of "Root Element" note near the top of the page when root="true" (it's a good idea for people who choose not to use tags).

Audrey Hamelers

unread,
Sep 28, 2012, 1:21:40 PM9/28/12
to dtdan...@googlegroups.com, malo...@ncbi.nlm.nih.gov
By the way, what about entities—is there any way to tell if they are "reachable"? Does such a concept even apply, for entities?


On Thursday, September 27, 2012 4:51:15 PM UTC-4, Maloney, Christopher (NIH/NLM/NCBI) [C] wrote:

Demian Hess

unread,
Sep 28, 2012, 1:30:17 PM9/28/12
to dtdan...@googlegroups.com
Entities don't rait as reachable or unreachable, I'm afraid. Either they are defined or not. I think you could detect whether a parameter entity was actually called within a DTD, but don't see much benefit in it.

--
You received this message because you are subscribed to the Google Groups "DtdAnalyzer" group.
To view this discussion on the web visit https://groups.google.com/d/msg/dtdanalyzer/-/gF0kRa3Lp9gJ.

To post to this group, send email to dtdan...@googlegroups.com.
To unsubscribe from this group, send email to dtdanalyzer...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/dtdanalyzer?hl=en.



--
Demian Hess

Avalon Consulting, LLC
527 Maple Avenue East, Suite 200, Vienna, VA 22180

Mobile: 301-943-8307
Fax: 845-367-5496
he...@avalonconsult.com



Maloney, Christopher (NIH/NLM/NCBI) [C]

unread,
Sep 28, 2012, 1:50:56 PM9/28/12
to dtdan...@googlegroups.com

Yes, that’s my take on entities, too. 

 

Attributes are a different matter, though.  An attribute is unreachable if it has no attributeDeclaration children pointing to a reachable element.  I guess we should include the @reachable attribute on those, as well as elements?

 

 

Chris Maloney

NIH/NLM/NCBI (Contractor)

Building 45, 5AN.24D-22

301-594-2842

 

Audrey Hamelers

unread,
Sep 28, 2012, 2:18:27 PM9/28/12
to dtdan...@googlegroups.com, malo...@ncbi.nlm.nih.gov
That's unnecessary; I've already handled that in the XSL.

I've implemented reachable and root elements in the XSL and it's looking great. I think we're almost ready to let the frontmatter group use this. One issue I noticed: you're no longer tagging individual tags in annotation-type="tag". Was this intentional?

Thanks,

Audrey

Audrey Hamelers

unread,
Sep 28, 2012, 2:21:38 PM9/28/12
to dtdan...@googlegroups.com, malo...@ncbi.nlm.nih.gov
Now:
<annotation type="tags">root rock-group mess-of-fun
</annotation>

Previously:
<annotation type="tags">
    <tag>root</tag>
    <tag>rock-group</tag>
    <tag>mess-of-fun</tag>
</annotation>

Audrey Hamelers

unread,
Sep 28, 2012, 2:54:50 PM9/28/12
to dtdan...@googlegroups.com, malo...@ncbi.nlm.nih.gov
Actually, it looks like all the internal tagging for all types of annotations (<p>, <ul>, etc.) are missing.

Maloney, Christopher (NIH/NLM/NCBI) [C]

unread,
Sep 28, 2012, 3:05:42 PM9/28/12
to Hamelers, Audrey (NIH/NLM/NCBI) [C], dtdan...@googlegroups.com

That’s right – the Markdown processing is not implemented yet.  You were going from my mockup before, this hasn’t ever worked yet in the real app.  I’ll try to get to it this weekend.

 

Chris Maloney

NIH/NLM/NCBI (Contractor)

Building 45, 5AN.24D-22

301-594-2842

 

Audrey Hamelers

unread,
Sep 28, 2012, 3:06:27 PM9/28/12
to dtdan...@googlegroups.com, malo...@ncbi.nlm.nih.gov
Aha, that explains it.


On Thursday, September 27, 2012 4:51:15 PM UTC-4, Maloney, Christopher (NIH/NLM/NCBI) [C] wrote:

Maloney, Christopher (NIH/NLM/NCBI) [C]

unread,
Sep 28, 2012, 3:07:27 PM9/28/12
to Hamelers, Audrey (NIH/NLM/NCBI) [C], dtdan...@googlegroups.com

One more thing – could you make sure you commit and push your documentor XSLT before you go today?  I’d like to be able to play with it this weekend.

 

 

Chris Maloney

NIH/NLM/NCBI (Contractor)

Building 45, 5AN.24D-22

301-594-2842

 

From: Hamelers, Audrey (NIH/NLM/NCBI) [C]
Sent: Friday, September 28, 2012 3:06 PM
To: dtdan...@googlegroups.com
Cc: Maloney, Christopher (NIH/NLM/NCBI) [C]
Subject: Re: Excluding unreachable elements, issue #2

 

Aha, that explains it.

Demian Hess

unread,
Sep 28, 2012, 3:11:33 PM9/28/12
to dtdan...@googlegroups.com, Hamelers, Audrey (NIH/NLM/NCBI) [C]
BTW: I did update the compare dtds xslt but have tried putting it in git--haven't had time to set up a repo. i'll try this weekend

i am still working on the presentation--just going slow as mollasses because of other projects. looking at the time constraint (only about 35 minutes), i've realized that we probably don't have enough time to shift presenters--would really chew up minutes. i'm trying to put together about 15 slides per the rough outline--will send around definitely this weekend so you can help fill in the lides on schematron, annotations, documentation etc so i hit the points that are important.

--
You received this message because you are subscribed to the Google Groups "DtdAnalyzer" group.
To post to this group, send email to dtdan...@googlegroups.com.
To unsubscribe from this group, send email to dtdanalyzer...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/dtdanalyzer?hl=en.

Audrey Hamelers

unread,
Sep 28, 2012, 3:37:07 PM9/28/12
to dtdan...@googlegroups.com, Hamelers, Audrey (NIH/NLM/NCBI) [C]
Chris, I pushed out my changes.

Demian, you could try using one of these github clients: http://mac.github.com http://windows.github.com/

It makes the whole process much easier.

Demian Hess

unread,
Sep 28, 2012, 3:44:06 PM9/28/12
to dtdan...@googlegroups.com
i'll try the windows git--can't remember if i've ever installed that before...

To view this discussion on the web visit https://groups.google.com/d/msg/dtdanalyzer/-/ui4S4o6BF1gJ.

To post to this group, send email to dtdan...@googlegroups.com.
To unsubscribe from this group, send email to dtdanalyzer...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/dtdanalyzer?hl=en.
Reply all
Reply to author
Forward
0 new messages