Project

General

Profile

« Previous | Next » 

Revision 1363

Added by Jing Tao about 22 years ago

Add some debug info.

View differences:

src/edu/ucsb/nceas/metacat/DBEntityResolver.java
91 91
  public InputSource resolveEntity (String publicId, String systemId)
92 92
                     throws SAXException
93 93
  {
94
    MetaCatUtil.debugMessage("in DBEntityResolver.resolveEntity, 50");
94 95
    String dbSystemID;
95 96
    String doctype = null;
96 97

  
......
100 101
        DBSAXHandler dhandler = null;
101 102
        dhandler = (DBSAXHandler)handler;
102 103
        if ( dhandler.processingDTD() ) {
104
         
103 105
          // public ID is doctype
104 106
          if (publicId != null) {
105 107
            doctype = publicId;
108
            MetaCatUtil.debugMessage("in get type from publicId and doctype is: "
109
                                     +doctype, 50);
106 110
          // assume public ID (doctype) is docname
107 111
          } else if (systemId != null) {
108 112
            doctype = dhandler.getDocname();
......
126 130
    // get System ID for doctype
127 131
    if (doctype != null) {
128 132
      // look at db XML Catalog for System ID
133
      MetaCatUtil.debugMessage("get systemId from doctype: "+doctype);
129 134
      dbSystemID = getDTDSystemID(doctype);
135
      MetaCatUtil.debugMessage("The Systemid is: "+dbSystemID);
130 136
      boolean doctypeIsInDB = true;
131 137
      // no System ID found in db XML Catalog
132 138
      if (dbSystemID == null) {
......
135 141
        if (systemId != null) {
136 142
          dbSystemID = systemId;
137 143
        }
144
        MetaCatUtil.debugMessage("If above Systemid is null and then get "
145
                                 +" system id from file" + dbSystemID);
138 146
      }
139 147
      // there are dtd text provided; try to upload on Metacat
140 148
      if ( dtdtext != null ) {
......
167 175
      return is;
168 176
    } else {
169 177
      // use provided systemId for the other cases
178
      MetaCatUtil.debugMessage("doctype is null and using system id from file");
170 179
      InputStream istream = checkURLConnection(systemId);
171 180
      return null;
172 181

  

Also available in: Unified diff