导航菜单

页面标题

页面副标题

BAM Crawford v6.14.1 - c.java 源代码

正在查看: BAM Crawford v6.14.1 应用的 c.java JAVA 源代码文件

本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。


package com.subsplash.thechurchapp.handlers.table;

import android.sax.Element;
import android.sax.EndElementListener;
import android.sax.EndTextElementListener;
import android.sax.RootElement;
import android.util.Log;
import android.util.Xml;
import com.subsplash.thechurchapp.dataObjects.DisplayOptions;
import com.subsplash.thechurchapp.dataObjects.Header;
import com.subsplash.thechurchapp.dataObjects.HeaderItem;
import com.subsplash.thechurchapp.dataObjects.ItemDisplayOptions;
import com.subsplash.thechurchapp.dataObjects.ListDisplayOptions;
import com.subsplash.thechurchapp.handlers.common.NavigationHandler;
import com.subsplash.thechurchapp.handlers.notes.NoteHandler;
import com.subsplash.util.w;
import java.net.URL;
import java.util.ArrayList;
import java.util.List;

public class c implements com.subsplash.thechurchapp.api.d {
    private String a = null;
    private String b = null;
    private String c = null;
    private String d = null;
    private String e = null;
    private boolean f = false;
    private String g = null;

    class a implements EndTextElementListener {
        final com.subsplash.util.w a;

        a(com.subsplash.util.w wVar) {
            this.a = wVar;
        }

        @Override
        public void end(String str) {
            this.a.f(w.b.NONE, w.c.ICON, com.subsplash.util.h0.o("TableParser", str));
        }
    }

    class a0 implements EndTextElementListener {
        final HeaderItem a;

        a0(HeaderItem headerItem) {
            this.a = headerItem;
        }

        @Override
        public void end(String str) {
            this.a.subtitle = str;
            c.this.f = true;
        }
    }

    class b implements EndTextElementListener {
        final com.subsplash.util.w a;

        b(com.subsplash.util.w wVar) {
            this.a = wVar;
        }

        @Override
        public void end(String str) {
            this.a.f(w.b.DOUBLE, w.c.ICON, com.subsplash.util.h0.o("TableParser", str));
        }
    }

    class b0 implements EndElementListener {
        final HeaderItem a;
        final com.subsplash.util.w b;
        final TableHandler c;
        final Header.HeaderStyle d;
        final int e;

        b0(HeaderItem headerItem, com.subsplash.util.w wVar, TableHandler tableHandler, Header.HeaderStyle headerStyle, int i) {
            this.a = headerItem;
            this.b = wVar;
            this.c = tableHandler;
            this.d = headerStyle;
            this.e = i;
        }

        @Override
        public void end() {
            if (com.subsplash.util.h0.d(c.this.d)) {
                this.a.setNavigationHandler(NavigationHandler.CreateHandler(c.this.d, c.this.e));
                c.this.f = true;
            }
            if (this.b.b()) {
                this.a.imageResourceSet = this.b;
                c.this.f = true;
            }
            if (c.this.f) {
                TableHandler tableHandler = this.c;
                if (tableHandler.header == null) {
                    tableHandler.header = new Header();
                    this.c.header.setStyle(this.d);
                }
                this.c.header.addItem(this.a, this.e);
            }
            c.this.f = false;
            c.this.d = null;
            c.this.e = null;
        }
    }

    class C0064c implements EndTextElementListener {
        final com.subsplash.util.w a;

        C0064c(com.subsplash.util.w wVar) {
            this.a = wVar;
        }

        @Override
        public void end(String str) {
            this.a.f(w.b.IPAD, w.c.ICON, com.subsplash.util.h0.o("TableParser", str));
        }
    }

    class c0 implements EndTextElementListener {
        final TableHandler a;

        c0(TableHandler tableHandler) {
            this.a = tableHandler;
        }

        @Override
        public void end(String str) {
            if (!com.subsplash.util.h0.d(str) || str.equals("below")) {
                this.a.displayOptions.itemOptions.textPosition = ItemDisplayOptions.TextPosition.Below;
            } else if (str.equals("overlay")) {
                this.a.displayOptions.itemOptions.textPosition = ItemDisplayOptions.TextPosition.Overlay;
            } else {
                this.a.displayOptions.itemOptions.textPosition = ItemDisplayOptions.TextPosition.None;
            }
        }
    }

    class d implements EndTextElementListener {
        final com.subsplash.util.w a;

        d(com.subsplash.util.w wVar) {
            this.a = wVar;
        }

        @Override
        public void end(String str) {
            this.a.f(w.b.IPADDOUBLE, w.c.ICON, com.subsplash.util.h0.o("TableParser", str));
        }
    }

    class d0 implements EndTextElementListener {
        final TableRow a;

        d0(TableRow tableRow) {
            this.a = tableRow;
        }

        @Override
        public void end(String str) {
            if (com.subsplash.util.h0.d(this.a.getName())) {
                return;
            }
            this.a.setName(com.subsplash.util.h0.m("TableParser", str));
        }
    }

    class e implements EndTextElementListener {
        final com.subsplash.util.w a;

        e(com.subsplash.util.w wVar) {
            this.a = wVar;
        }

        @Override
        public void end(String str) {
            this.a.f(w.b.NONE, w.c.IMAGE, com.subsplash.util.h0.o("TableParser", str));
        }
    }

    class e0 implements EndTextElementListener {
        final TableRow a;

        e0(TableRow tableRow) {
            this.a = tableRow;
        }

        @Override
        public void end(String str) {
            this.a.setName(com.subsplash.util.h0.m("TableParser", str));
        }
    }

    class f implements EndTextElementListener {
        final com.subsplash.util.w a;

        f(com.subsplash.util.w wVar) {
            this.a = wVar;
        }

        @Override
        public void end(String str) {
            this.a.f(w.b.DOUBLE, w.c.IMAGE, com.subsplash.util.h0.o("TableParser", str));
        }
    }

    class f0 implements EndTextElementListener {
        final TableRow a;

        f0(TableRow tableRow) {
            this.a = tableRow;
        }

        @Override
        public void end(String str) {
            if (com.subsplash.util.h0.d(c.this.g)) {
                return;
            }
            this.a.setName(com.subsplash.util.h0.m("TableParser", str));
        }
    }

    class g implements EndTextElementListener {
        final com.subsplash.util.w a;

        g(com.subsplash.util.w wVar) {
            this.a = wVar;
        }

        @Override
        public void end(String str) {
            this.a.f(w.b.IPAD, w.c.IMAGE, com.subsplash.util.h0.o("TableParser", str));
        }
    }

    class g0 implements EndTextElementListener {
        final TableRow a;

        g0(TableRow tableRow) {
            this.a = tableRow;
        }

        @Override
        public void end(String str) {
            this.a.setAlternative(com.subsplash.util.h0.m("TableParser", str));
        }
    }

    class h implements EndTextElementListener {
        final com.subsplash.util.w a;

        h(com.subsplash.util.w wVar) {
            this.a = wVar;
        }

        @Override
        public void end(String str) {
            this.a.f(w.b.IPADDOUBLE, w.c.IMAGE, com.subsplash.util.h0.o("TableParser", str));
        }
    }

    class h0 implements EndTextElementListener {
        final TableRow a;

        h0(TableRow tableRow) {
            this.a = tableRow;
        }

        @Override
        public void end(String str) {
            this.a.setPosition(str);
        }
    }

    class i implements EndTextElementListener {
        i() {
        }

        @Override
        public void end(String str) {
            if (c.this.a == null) {
                c.this.a = str;
            }
        }
    }

    class i0 implements EndTextElementListener {
        final TableRow a;

        i0(TableRow tableRow) {
            this.a = tableRow;
        }

        @Override
        public void end(String str) {
            this.a.setDate(com.subsplash.util.h0.i("TableParser", str));
        }
    }

    class j implements EndTextElementListener {
        j() {
        }

        @Override
        public void end(String str) {
            c.this.a = str;
        }
    }

    class k implements EndTextElementListener {
        final TableHandler a;

        k(TableHandler tableHandler) {
            this.a = tableHandler;
        }

        @Override
        public void end(String str) {
            this.a.headerTitle = str;
        }
    }

    class l implements EndTextElementListener {
        l() {
        }

        @Override
        public void end(String str) {
            if (c.this.b == null) {
                c.this.b = str;
            }
        }
    }

    class m implements EndTextElementListener {
        m() {
        }

        @Override
        public void end(String str) {
            c.this.b = str;
        }
    }

    class n implements EndTextElementListener {
        n() {
        }

        @Override
        public void end(String str) {
            c.this.c = str;
        }
    }

    class o implements EndElementListener {
        final TableRow a;
        final com.subsplash.util.w b;
        final List c;

        o(TableRow tableRow, com.subsplash.util.w wVar, List list) {
            this.a = tableRow;
            this.b = wVar;
            this.c = list;
        }

        @Override
        public void end() {
            NavigationHandler CreateHandler;
            if (c.this.a != null && (CreateHandler = NavigationHandler.CreateHandler(c.this.a, c.this.b)) != null) {
                CreateHandler.setShortUrl(c.this.c);
                this.a.setHandler(CreateHandler);
            }
            c.this.o(this.a);
            c.this.p(this.a, this.b);
            this.c.add(this.a.copy());
            c.this.n();
            this.b.a();
            this.a.reuse();
        }
    }

    class p implements EndElementListener {
        final TableHandler a;
        final List b;

        p(TableHandler tableHandler, List list) {
            this.a = tableHandler;
            this.b = list;
        }

        @Override
        public void end() {
            this.a.tableRows = this.b;
        }
    }

    class q implements EndTextElementListener {
        q() {
        }

        @Override
        public void end(String str) {
            if (c.this.d == null) {
                c.this.d = str;
            }
        }
    }

    class r implements EndTextElementListener {
        r() {
        }

        @Override
        public void end(String str) {
            if (c.this.e == null) {
                c.this.e = str;
            }
        }
    }

    class s implements EndTextElementListener {
        s() {
        }

        @Override
        public void end(String str) {
            c.this.d = str;
        }
    }

    class t implements EndTextElementListener {
        t() {
        }

        @Override
        public void end(String str) {
            c.this.e = str;
        }
    }

    class u implements EndTextElementListener {
        final com.subsplash.util.w a;

        u(com.subsplash.util.w wVar) {
            this.a = wVar;
        }

        @Override
        public void end(String str) {
            URL o = com.subsplash.util.h0.o("TableParser", str);
            if (o != null) {
                this.a.f(w.b.NONE, w.c.IMAGE, o);
            }
        }
    }

    class v implements EndTextElementListener {
        final TableHandler a;

        v(TableHandler tableHandler) {
            this.a = tableHandler;
        }

        @Override
        public void end(String str) {
            this.a.tableTitle = str;
        }
    }

    class w implements EndTextElementListener {
        final com.subsplash.util.w a;

        w(com.subsplash.util.w wVar) {
            this.a = wVar;
        }

        @Override
        public void end(String str) {
            URL o = com.subsplash.util.h0.o("TableParser", str);
            if (o != null) {
                this.a.f(w.b.DOUBLE, w.c.IMAGE, o);
            }
        }
    }

    class x implements EndTextElementListener {
        final com.subsplash.util.w a;

        x(com.subsplash.util.w wVar) {
            this.a = wVar;
        }

        @Override
        public void end(String str) {
            URL o = com.subsplash.util.h0.o("TableParser", str);
            if (o != null) {
                this.a.f(w.b.IPAD, w.c.IMAGE, o);
            }
        }
    }

    class y implements EndTextElementListener {
        final com.subsplash.util.w a;

        y(com.subsplash.util.w wVar) {
            this.a = wVar;
        }

        @Override
        public void end(String str) {
            URL o = com.subsplash.util.h0.o("TableParser", str);
            if (o != null) {
                this.a.f(w.b.IPADDOUBLE, w.c.IMAGE, o);
            }
        }
    }

    class z implements EndTextElementListener {
        final HeaderItem a;

        z(HeaderItem headerItem) {
            this.a = headerItem;
        }

        @Override
        public void end(String str) {
            this.a.title = str;
            c.this.f = true;
        }
    }

    private void q(TableHandler tableHandler, Element element, int i2, Header.HeaderStyle headerStyle) {
        HeaderItem headerItem = new HeaderItem();
        com.subsplash.util.w wVar = new com.subsplash.util.w();
        element.getChild(com.subsplash.thechurchapp.handlers.common.a.JSON_KEY_HANDLER).setEndTextElementListener(new q());
        element.getChild("link").setEndTextElementListener(new r());
        element.getChild("handlerandroid").setEndTextElementListener(new s());
        element.getChild("linkandroid").setEndTextElementListener(new t());
        element.getChild("image").setEndTextElementListener(new u(wVar));
        element.getChild("http://dashboard.thechurchapp.org/platform/feeds/schemas/double/", "image").setEndTextElementListener(new w(wVar));
        element.getChild("http://dashboard.thechurchapp.org/platform/feeds/schemas/ipad/", "image").setEndTextElementListener(new x(wVar));
        element.getChild("http://dashboard.thechurchapp.org/platform/feeds/schemas/ipad_double/", "image").setEndTextElementListener(new y(wVar));
        element.getChild(NoteHandler.JSON_KEY_TITLE).setEndTextElementListener(new z(headerItem));
        element.getChild("subtitle").setEndTextElementListener(new a0(headerItem));
        element.setEndElementListener(new b0(headerItem, wVar, tableHandler, headerStyle, i2));
    }

    protected void n() {
        this.a = null;
        this.b = null;
        this.g = null;
        this.c = null;
    }

    protected void o(TableRow tableRow) {
        if (com.subsplash.util.h0.d(this.g)) {
            tableRow.setName(this.g);
        }
    }

    protected void p(TableRow tableRow, com.subsplash.util.w wVar) {
        URL d2 = wVar.d(w.c.IMAGE);
        if (d2 == null) {
            d2 = wVar.d(w.c.ICON);
        }
        tableRow.setThumbnailUrl(d2);
    }

    @Override
    public void parse(String str, com.subsplash.thechurchapp.handlers.common.a aVar) {
        TableHandler tableHandler = (TableHandler) aVar;
        TableRow tableRow = new TableRow();
        ArrayList arrayList = new ArrayList();
        com.subsplash.util.w wVar = new com.subsplash.util.w();
        ListDisplayOptions listDisplayOptions = tableHandler.displayOptions;
        listDisplayOptions.isXMLFallbackEnabledForIndicatorAspectRatio = listDisplayOptions.style == DisplayOptions.Style.Rows;
        RootElement rootElement = new RootElement("data");
        Element child = rootElement.getChild("header");
        Element requireChild = rootElement.requireChild("table");
        r(tableHandler, tableRow, arrayList, wVar, child, requireChild, requireChild.getChild("row"));
        try {
            Xml.parse(str, rootElement.getContentHandler());
            Log.i("TableParser", "Parsed");
        } catch (Exception e2) {
            Log.e("TableParser", "Unable to parse Table XML", e2);
            throw new RuntimeException(e2);
        }
    }

    protected void r(TableHandler tableHandler, TableRow tableRow, List list, com.subsplash.util.w wVar, Element element, Element element2, Element element3) {
        element.getChild(NoteHandler.JSON_KEY_TITLE).setEndTextElementListener(new k(tableHandler));
        element.getChild("tabletitle").setEndTextElementListener(new v(tableHandler));
        Element child = element2.getChild("tablesettings");
        if (child != null) {
            child.getChild("grid-titleposition").setEndTextElementListener(new c0(tableHandler));
        }
        q(tableHandler, element.getChild("banner"), 0, Header.HeaderStyle.BANNER);
        Element child2 = element.getChild("firstfeatured");
        Header.HeaderStyle headerStyle = Header.HeaderStyle.FEATURED;
        q(tableHandler, child2, 0, headerStyle);
        q(tableHandler, element.getChild("secondfeatured"), 1, headerStyle);
        element3.getChild("name").setEndTextElementListener(new d0(tableRow));
        element3.getChild("nameandroid").setEndTextElementListener(new e0(tableRow));
        element3.getChild(NoteHandler.JSON_KEY_TITLE).setEndTextElementListener(new f0(tableRow));
        element3.getChild("alternative").setEndTextElementListener(new g0(tableRow));
        element3.getChild("position").setEndTextElementListener(new h0(tableRow));
        element3.getChild("date").setEndTextElementListener(new i0(tableRow));
        element3.getChild("icon").setEndTextElementListener(new a(wVar));
        element3.getChild("http://dashboard.thechurchapp.org/platform/feeds/schemas/double/", "icon").setEndTextElementListener(new b(wVar));
        element3.getChild("http://dashboard.thechurchapp.org/platform/feeds/schemas/ipad/", "icon").setEndTextElementListener(new C0064c(wVar));
        element3.getChild("http://dashboard.thechurchapp.org/platform/feeds/schemas/ipad_double/", "icon").setEndTextElementListener(new d(wVar));
        element3.getChild("image").setEndTextElementListener(new e(wVar));
        element3.getChild("http://dashboard.thechurchapp.org/platform/feeds/schemas/double/", "image").setEndTextElementListener(new f(wVar));
        element3.getChild("http://dashboard.thechurchapp.org/platform/feeds/schemas/ipad/", "image").setEndTextElementListener(new g(wVar));
        element3.getChild("http://dashboard.thechurchapp.org/platform/feeds/schemas/ipad_double/", "image").setEndTextElementListener(new h(wVar));
        element3.getChild(com.subsplash.thechurchapp.handlers.common.a.JSON_KEY_HANDLER).setEndTextElementListener(new i());
        element3.getChild("handlerandroid").setEndTextElementListener(new j());
        element3.getChild("link").setEndTextElementListener(new l());
        element3.getChild("linkandroid").setEndTextElementListener(new m());
        element3.getChild("short_url").setEndTextElementListener(new n());
        element3.setEndElementListener(new o(tableRow, wVar, list));
        element2.setEndElementListener(new p(tableHandler, list));
    }
}