<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://www.w3.org/Bugs/Public/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4"
          urlbase="https://www.w3.org/Bugs/Public/"
          
          maintainer="sysbot+bugzilla@w3.org"
>

    <bug>
          <bug_id>6816</bug_id>
          
          <creation_ts>2009-04-16 10:14:22 +0000</creation_ts>
          <short_desc>Resources loading: slight inconsistency in the code</short_desc>
          <delta_ts>2009-04-20 11:36:02 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>mobileOK Basic checker</product>
          <component>Java Library</component>
          <version>unspecified</version>
          <rep_platform>Other</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>enhancement</bug_severity>
          <target_milestone>---</target_milestone>
          <dependson>6815</dependson>
          
          <everconfirmed>1</everconfirmed>
          <reporter name="fd">fd</reporter>
          <assigned_to name="Abel Rionda">abel.rionda</assigned_to>
          
          
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>24759</commentid>
    <comment_count>0</comment_count>
    <who name="fd">fd</who>
    <bug_when>2009-04-16 10:14:22 +0000</bug_when>
    <thetext>Not a bug per se, but the library uses two different ways to load resources:
 1. through a call to getClass().getResourceAsStream() in MobileOKCatalog and XhtmlContent to resolve entities.
 2. through a call to getClassLoader().getResourceAsStream() in DOMUtils to resolved XSLT stylesheets.

That is almost the same thing, but there is a slight difference on the way paths are handled (absolute vs. relative). Sticking to one convention seems a good idea.

For an explanation of the difference, see, e.g.:
http://www.javaworld.com/javaworld/javaqa/2003-08/01-qa-0808-property.html?page=2

The convention to use depends on how we resolve bug 6815 to allow for more flexibility in XSLT paths. First one is probably better</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>24849</commentid>
    <comment_count>1</comment_count>
    <who name="fd">fd</who>
    <bug_when>2009-04-20 11:36:02 +0000</bug_when>
    <thetext>Resolution of bug 6815 de facto fixed the inconsistency: getClass().getResourceAsStream() is used throughout the mobileOK Checker.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>