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

io.sphere.sdk.producttypes.ProductType Maven / Gradle / Ivy

There is a newer version: 1.0.0-M26
Show newest version
package io.sphere.sdk.producttypes;

import com.fasterxml.jackson.core.type.TypeReference;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import io.sphere.sdk.models.Resource;
import io.sphere.sdk.models.Reference;

/** Describes common characteristics, most importantly common custom attributes, of many concrete products.

 

Operations:

  • Create a product type with {@link io.sphere.sdk.producttypes.commands.ProductTypeCreateCommand}.
  • Query a product type with {@link io.sphere.sdk.producttypes.queries.ProductTypeQuery}.
  • Delete a product type with {@link io.sphere.sdk.producttypes.commands.ProductTypeDeleteCommand}.
*/ @JsonDeserialize(as=ProductTypeImpl.class) public interface ProductType extends Resource, AttributeDefinitionContainer { String getName(); String getDescription(); @Override default Reference toReference() { return reference(this); } static String referenceTypeId(){ return "product-type"; } /** * * @deprecated use {@link #referenceTypeId()} instead * @return referenceTypeId */ @Deprecated static String typeId(){ return "product-type"; } static Reference reference(final ProductType productType) { return Reference.of(referenceTypeId(), productType.getId(), productType); } static Reference reference(final String id) { return Reference.of(referenceTypeId(), id); } static TypeReference typeReference() { return new TypeReference(){ @Override public String toString() { return "TypeReference"; } }; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy