Snap v8.10.4版本的 MD5 值为:3f7a8892a522fef17767953dff16af57

以下内容为反编译后的 n.java 源代码,内容仅作参考


package c.a.a.h;

import java.util.HashMap;
import java.util.Map;
import java.util.regex.Pattern;
public final class n implements c.a.a.f {
    public Map f349a = new HashMap();
    public Map f350b = new HashMap();
    public Map f351c = new HashMap();
    public Pattern d = Pattern.compile("[/*?\\[\\]]");

    public class a implements c.a.a.j.a {
        public final String f352a;
        public final String f353b;
        public final String f354c;
        public final c.a.a.i.a d;

        public a(n nVar, String str, String str2, String str3, c.a.a.i.a aVar) {
            this.f352a = str;
            this.f353b = str2;
            this.f354c = str3;
            this.d = aVar;
        }

        @Override
        public String a() {
            return this.f353b;
        }

        @Override
        public String b() {
            return this.f352a;
        }

        @Override
        public String c() {
            return this.f354c;
        }

        @Override
        public c.a.a.i.a d() {
            return this.d;
        }

        public String toString() {
            return this.f353b + this.f354c + " NS(" + this.f352a + "), FORM (" + this.d + ")";
        }
    }

    public n() {
        try {
            g();
            f();
        } catch (c.a.a.c unused) {
            throw new RuntimeException("The XMPSchemaRegistry cannot be initialized!");
        }
    }

    public synchronized c.a.a.j.a a(String str) {
        return (c.a.a.j.a) this.f351c.get(str);
    }

    public synchronized String b(String str) {
        return (String) this.f349a.get(str);
    }

    public synchronized String c(String str) {
        if (str != null) {
            if (!str.endsWith(":")) {
                str = str + ":";
            }
        }
        return (String) this.f350b.get(str);
    }

    public synchronized void d(String str, String str2, String str3, String str4, c.a.a.i.a aVar) {
        a.a.a.a.g.j.d(str);
        a.a.a.a.g.j.c(str2);
        a.a.a.a.g.j.d(str3);
        a.a.a.a.g.j.c(str4);
        c.a.a.i.a aVar2 = aVar != null ? new c.a.a.i.a(l.j(new c.a.a.i.d(aVar.f362a), null).f362a) : new c.a.a.i.a();
        if (this.d.matcher(str2).find() || this.d.matcher(str4).find()) {
            throw new c.a.a.c("Alias and actual property names must be simple", 102);
        }
        String b2 = b(str);
        String b3 = b(str3);
        if (b2 == null) {
            throw new c.a.a.c("Alias namespace is not registered", 101);
        }
        if (b3 == null) {
            throw new c.a.a.c("Actual namespace is not registered", 101);
        }
        String str5 = b2 + str2;
        if (this.f351c.containsKey(str5)) {
            throw new c.a.a.c("Alias is already existing", 4);
        }
        if (this.f351c.containsKey(b3 + str4)) {
            throw new c.a.a.c("Actual property is already an alias, use the base property", 4);
        }
        this.f351c.put(str5, new a(this, str3, b3, str4, aVar2));
    }

    public synchronized String e(String str, String str2) {
        a.a.a.a.g.j.d(str);
        if (str2 == null || str2.length() == 0) {
            throw new c.a.a.c("Empty prefix", 4);
        }
        if (str2.charAt(str2.length() - 1) != ':') {
            str2 = str2 + ':';
        }
        if (g.e(str2.substring(0, str2.length() - 1))) {
            String str3 = (String) this.f349a.get(str);
            String str4 = (String) this.f350b.get(str2);
            if (str3 != null) {
                return str3;
            }
            if (str4 != null) {
                String str5 = str2;
                int i = 1;
                while (this.f350b.containsKey(str5)) {
                    str5 = str2.substring(0, str2.length() - 1) + "_" + i + "_:";
                    i++;
                }
                str2 = str5;
            }
            this.f350b.put(str2, str);
            this.f349a.put(str, str2);
            return str2;
        }
        throw new c.a.a.c("The prefix is a bad XML name", 201);
    }

    public final void f() {
        c.a.a.i.a aVar = new c.a.a.i.a();
        aVar.e(1536, true);
        c.a.a.i.a aVar2 = new c.a.a.i.a();
        aVar2.e(7680, true);
        d("http://ns.adobe.com/xap/1.0/", "Author", "http://purl.org/dc/elements/1.1/", "creator", aVar);
        d("http://ns.adobe.com/xap/1.0/", "Authors", "http://purl.org/dc/elements/1.1/", "creator", null);
        d("http://ns.adobe.com/xap/1.0/", "Description", "http://purl.org/dc/elements/1.1/", "description", null);
        d("http://ns.adobe.com/xap/1.0/", "Format", "http://purl.org/dc/elements/1.1/", "format", null);
        d("http://ns.adobe.com/xap/1.0/", "Keywords", "http://purl.org/dc/elements/1.1/", "subject", null);
        d("http://ns.adobe.com/xap/1.0/", "Locale", "http://purl.org/dc/elements/1.1/", "language", null);
        d("http://ns.adobe.com/xap/1.0/", "Title", "http://purl.org/dc/elements/1.1/", "title", null);
        d("http://ns.adobe.com/xap/1.0/rights/", "Copyright", "http://purl.org/dc/elements/1.1/", "rights", null);
        d("http://ns.adobe.com/pdf/1.3/", "Author", "http://purl.org/dc/elements/1.1/", "creator", aVar);
        d("http://ns.adobe.com/pdf/1.3/", "BaseURL", "http://ns.adobe.com/xap/1.0/", "BaseURL", null);
        d("http://ns.adobe.com/pdf/1.3/", "CreationDate", "http://ns.adobe.com/xap/1.0/", "CreateDate", null);
        d("http://ns.adobe.com/pdf/1.3/", "Creator", "http://ns.adobe.com/xap/1.0/", "CreatorTool", null);
        d("http://ns.adobe.com/pdf/1.3/", "ModDate", "http://ns.adobe.com/xap/1.0/", "ModifyDate", null);
        d("http://ns.adobe.com/pdf/1.3/", "Subject", "http://purl.org/dc/elements/1.1/", "description", aVar2);
        d("http://ns.adobe.com/pdf/1.3/", "Title", "http://purl.org/dc/elements/1.1/", "title", aVar2);
        d("http://ns.adobe.com/photoshop/1.0/", "Author", "http://purl.org/dc/elements/1.1/", "creator", aVar);
        d("http://ns.adobe.com/photoshop/1.0/", "Caption", "http://purl.org/dc/elements/1.1/", "description", aVar2);
        d("http://ns.adobe.com/photoshop/1.0/", "Copyright", "http://purl.org/dc/elements/1.1/", "rights", aVar2);
        d("http://ns.adobe.com/photoshop/1.0/", "Keywords", "http://purl.org/dc/elements/1.1/", "subject", null);
        d("http://ns.adobe.com/photoshop/1.0/", "Marked", "http://ns.adobe.com/xap/1.0/rights/", "Marked", null);
        d("http://ns.adobe.com/photoshop/1.0/", "Title", "http://purl.org/dc/elements/1.1/", "title", aVar2);
        d("http://ns.adobe.com/photoshop/1.0/", "WebStatement", "http://ns.adobe.com/xap/1.0/rights/", "WebStatement", null);
        d("http://ns.adobe.com/tiff/1.0/", "Artist", "http://purl.org/dc/elements/1.1/", "creator", aVar);
        d("http://ns.adobe.com/tiff/1.0/", "Copyright", "http://purl.org/dc/elements/1.1/", "rights", null);
        d("http://ns.adobe.com/tiff/1.0/", "DateTime", "http://ns.adobe.com/xap/1.0/", "ModifyDate", null);
        d("http://ns.adobe.com/tiff/1.0/", "ImageDescription", "http://purl.org/dc/elements/1.1/", "description", null);
        d("http://ns.adobe.com/tiff/1.0/", "Software", "http://ns.adobe.com/xap/1.0/", "CreatorTool", null);
        d("http://ns.adobe.com/png/1.0/", "Author", "http://purl.org/dc/elements/1.1/", "creator", aVar);
        d("http://ns.adobe.com/png/1.0/", "Copyright", "http://purl.org/dc/elements/1.1/", "rights", aVar2);
        d("http://ns.adobe.com/png/1.0/", "CreationTime", "http://ns.adobe.com/xap/1.0/", "CreateDate", null);
        d("http://ns.adobe.com/png/1.0/", "Description", "http://purl.org/dc/elements/1.1/", "description", aVar2);
        d("http://ns.adobe.com/png/1.0/", "ModificationTime", "http://ns.adobe.com/xap/1.0/", "ModifyDate", null);
        d("http://ns.adobe.com/png/1.0/", "Software", "http://ns.adobe.com/xap/1.0/", "CreatorTool", null);
        d("http://ns.adobe.com/png/1.0/", "Title", "http://purl.org/dc/elements/1.1/", "title", aVar2);
    }

    public final void g() {
        e("http://www.w3.org/XML/1998/namespace", "xml");
        e("http://www.w3.org/1999/02/22-rdf-syntax-ns#", "rdf");
        e("http://purl.org/dc/elements/1.1/", "dc");
        e("http://iptc.org/std/Iptc4xmpCore/1.0/xmlns/", "Iptc4xmpCore");
        e("adobe:ns:meta/", "x");
        e("http://ns.adobe.com/iX/1.0/", "iX");
        e("http://ns.adobe.com/xap/1.0/", "xmp");
        e("http://ns.adobe.com/xap/1.0/rights/", "xmpRights");
        e("http://ns.adobe.com/xap/1.0/mm/", "xmpMM");
        e("http://ns.adobe.com/xap/1.0/bj/", "xmpBJ");
        e("http://ns.adobe.com/xmp/note/", "xmpNote");
        e("http://ns.adobe.com/pdf/1.3/", "pdf");
        e("http://ns.adobe.com/pdfx/1.3/", "pdfx");
        e("http://www.npes.org/pdfx/ns/id/", "pdfxid");
        e("http://www.aiim.org/pdfa/ns/schema#", "pdfaSchema");
        e("http://www.aiim.org/pdfa/ns/property#", "pdfaProperty");
        e("http://www.aiim.org/pdfa/ns/type#", "pdfaType");
        e("http://www.aiim.org/pdfa/ns/field#", "pdfaField");
        e("http://www.aiim.org/pdfa/ns/id/", "pdfaid");
        e("http://www.aiim.org/pdfa/ns/extension/", "pdfaExtension");
        e("http://ns.adobe.com/photoshop/1.0/", "photoshop");
        e("http://ns.adobe.com/album/1.0/", "album");
        e("http://ns.adobe.com/exif/1.0/", "exif");
        e("http://ns.adobe.com/exif/1.0/aux/", "aux");
        e("http://ns.adobe.com/tiff/1.0/", "tiff");
        e("http://ns.adobe.com/png/1.0/", "png");
        e("http://ns.adobe.com/jpeg/1.0/", "jpeg");
        e("http://ns.adobe.com/jp2k/1.0/", "jp2k");
        e("http://ns.adobe.com/camera-raw-settings/1.0/", "crs");
        e("http://ns.adobe.com/StockPhoto/1.0/", "bmsp");
        e("http://ns.adobe.com/creatorAtom/1.0/", "creatorAtom");
        e("http://ns.adobe.com/asf/1.0/", "asf");
        e("http://ns.adobe.com/xmp/wav/1.0/", "wav");
        e("http://ns.adobe.com/xmp/1.0/DynamicMedia/", "xmpDM");
        e("http://ns.adobe.com/xmp/transient/1.0/", "xmpx");
        e("http://ns.adobe.com/xap/1.0/t/", "xmpT");
        e("http://ns.adobe.com/xap/1.0/t/pg/", "xmpTPg");
        e("http://ns.adobe.com/xap/1.0/g/", "xmpG");
        e("http://ns.adobe.com/xap/1.0/g/img/", "xmpGImg");
        e("http://ns.adobe.com/xap/1.0/sType/Font#", "stFNT");
        e("http://ns.adobe.com/xap/1.0/sType/Dimensions#", "stDim");
        e("http://ns.adobe.com/xap/1.0/sType/ResourceEvent#", "stEvt");
        e("http://ns.adobe.com/xap/1.0/sType/ResourceRef#", "stRef");
        e("http://ns.adobe.com/xap/1.0/sType/Version#", "stVer");
        e("http://ns.adobe.com/xap/1.0/sType/Job#", "stJob");
        e("http://ns.adobe.com/xap/1.0/sType/ManifestItem#", "stMfs");
        e("http://ns.adobe.com/xmp/Identifier/qual/1.0/", "xmpidq");
    }
}