/*
 * Decompiled with CFR 0.152.
 * 
 * Could not load the following classes:
 *  com.l7tech.common.io.DocumentReferenceProcessor$ReferenceCustomizer
 *  com.l7tech.common.io.DocumentReferenceProcessor$ReferenceInfo
 */
package com.l7tech.server.service.resolution;

import com.l7tech.common.io.DocumentReferenceProcessor;
import com.l7tech.server.service.resolution.k;
import java.io.IOException;
import java.net.URI;
import java.net.URISyntaxException;
import java.util.Collection;
import org.w3c.dom.Document;
import org.w3c.dom.Node;
import org.xml.sax.SAXException;

class m
implements DocumentReferenceProcessor.ReferenceCustomizer {
    final Collection val$referencedSchemaElements;
    final k this$0;

    /*
     * Ignored method signature, as it can't be verified against descriptor
     */
    m(k k2, Collection collection) {
        this.this$0 = k2;
        this.val$referencedSchemaElements = collection;
    }

    public String customize(Document document, Node node, String string, DocumentReferenceProcessor.ReferenceInfo referenceInfo) {
        if (referenceInfo.getReferenceUrl() != null) {
            try {
                URI uRI = new URI(string);
                String string2 = uRI.resolve(new URI(referenceInfo.getReferenceUrl())).toString();
                String string3 = this.this$0.resolveSchema(string2);
                try {
                    if (string3 != null) {
                        this.val$referencedSchemaElements.add(this.this$0.a(string2, string3));
                    }
                }
                catch (IOException iOException) {
                    throw m.a(iOException);
                }
            }
            catch (IOException iOException) {
            }
            catch (URISyntaxException uRISyntaxException) {
            }
            catch (SAXException sAXException) {
                // empty catch block
            }
        }
        return null;
    }

    private static IOException a(IOException iOException) {
        return iOException;
    }
}

