All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.alphasystem.docx4j.builder.wml.CTShdBuilder Maven / Gradle / Ivy

There is a newer version: 0.5.5
Show newest version

package com.alphasystem.docx4j.builder.wml;

import com.alphasystem.docx4j.builder.OpenXmlBuilder;
import org.docx4j.wml.CTShd;
import org.docx4j.wml.STShd;
import org.docx4j.wml.STThemeColor;


/**
 * Fluent API builder for org.docx4j.wml.CTShd.
 * 
 */
public class CTShdBuilder
    extends OpenXmlBuilder
{


    /**
     * Initialize the underlying object.
     * 
     */
    public CTShdBuilder() {
        this(null);
    }

    /**
     * Initialize the builder with given object.
     * 
     * @param object
     *     the given object
     */
    public CTShdBuilder(CTShd object) {
        super(object);
    }

    /**
     * Copies values fom src into target. Values of target will be overridden by the values from src.
     * 
     * @param src
     *     source object
     * @param target
     *     target object
     */
    public CTShdBuilder(CTShd src, CTShd target) {
        this(target);
        if (src!= null) {
            withVal(src.getVal()).withColor(src.getColor()).withThemeColor(src.getThemeColor()).withThemeTint(src.getThemeTint()).withThemeShade(src.getThemeShade()).withFill(src.getFill()).withThemeFill(src.getThemeFill()).withThemeFillTint(src.getThemeFillTint()).withThemeFillShade(src.getThemeFillShade());
        }
    }

    protected CTShd createObject() {
        return WmlBuilderFactory.OBJECT_FACTORY.createCTShd();
    }

    public CTShdBuilder withVal(STShd value) {
        if (value!= null) {
            object.setVal(value);
        }
        return this;
    }

    public CTShdBuilder withColor(String value) {
        if (value!= null) {
            object.setColor(value);
        }
        return this;
    }

    public CTShdBuilder withThemeColor(STThemeColor value) {
        if (value!= null) {
            object.setThemeColor(value);
        }
        return this;
    }

    public CTShdBuilder withThemeTint(String value) {
        if (value!= null) {
            object.setThemeTint(value);
        }
        return this;
    }

    public CTShdBuilder withThemeShade(String value) {
        if (value!= null) {
            object.setThemeShade(value);
        }
        return this;
    }

    public CTShdBuilder withFill(String value) {
        if (value!= null) {
            object.setFill(value);
        }
        return this;
    }

    public CTShdBuilder withThemeFill(STThemeColor value) {
        if (value!= null) {
            object.setThemeFill(value);
        }
        return this;
    }

    public CTShdBuilder withThemeFillTint(String value) {
        if (value!= null) {
            object.setThemeFillTint(value);
        }
        return this;
    }

    public CTShdBuilder withThemeFillShade(String value) {
        if (value!= null) {
            object.setThemeFillShade(value);
        }
        return this;
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy