GuideTableRowElement.java 1.31 KB
/*
 * Decompiled with CFR 0_118.
 * 
 * Could not load the following classes:
 *  com.adobe.xfa.Element
 *  org.apache.commons.lang3.StringUtils
 *  org.apache.sling.commons.json.JSONObject
 */
package com.adobe.aemds.guide.addon.dor.elements;

import com.adobe.aemds.guide.addon.dor.elements.DoRElement;
import com.adobe.aemds.guide.addon.dor.elements.DoRTableRowElement;
import com.adobe.aemds.guide.addon.dor.elements.GuidePanelElement;
import com.adobe.xfa.Element;
import java.util.Properties;
import org.apache.commons.lang3.StringUtils;
import org.apache.sling.commons.json.JSONObject;

public class GuideTableRowElement
extends GuidePanelElement {
    public GuideTableRowElement(JSONObject jsonObject) {
        super(jsonObject);
        String property = "bindMatch";
        String value = jsonObject.optString(property);
        if (value.equals("none")) {
            this.bindRef = null;
            this.properties.remove("bindRef");
            this.properties.put(property, value);
        }
        if (StringUtils.isNotEmpty((CharSequence)(value = jsonObject.optString(property = "assistRole")))) {
            this.properties.put(property, value);
        }
    }

    @Override
    public DoRElement createDoRElement(Element xfaElement) throws Exception {
        return new DoRTableRowElement(xfaElement);
    }
}