com.dft.api.shopify.model.ImageAltTextCreationRequest Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of shopify-admin-rest Show documentation
Show all versions of shopify-admin-rest Show documentation
Shopify Admin REST API using JDK 11 and Reactive Programming
The newest version!
package com.dft.api.shopify.model;
import java.util.Arrays;
import java.util.List;
public class ImageAltTextCreationRequest {
static final String KEY = "alt";
static final String NAMESPACE = "tags";
static final ShopifyMetafieldValueType VALUE_TYPE = ShopifyMetafieldValueType.STRING;
public static interface ImageAltTextStep {
public BuildStep withImageAltText(final String imageAltText);
}
public static interface BuildStep {
public List build();
}
public static ImageAltTextStep newBuilder() {
return new Steps();
}
private static class Steps implements ImageAltTextStep, BuildStep {
private ShopifyMetafield imageAltTextMetafield;
@Override
public List build() {
return Arrays.asList(imageAltTextMetafield);
}
@Override
public BuildStep withImageAltText(String imageAltText) {
this.imageAltTextMetafield = new ShopifyMetafield();
imageAltTextMetafield.setKey(KEY);
imageAltTextMetafield.setValue(imageAltText);
imageAltTextMetafield.setNamespace(NAMESPACE);
imageAltTextMetafield.setValueType(VALUE_TYPE);
return this;
}
}
}