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

io.sphere.sdk.taxcategories.TaxCategoryImpl Maven / Gradle / Ivy

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

import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonProperty;
import io.sphere.sdk.models.ResourceImpl;

import javax.annotation.Nullable;
import java.time.ZonedDateTime;
import java.util.List;

class TaxCategoryImpl extends ResourceImpl implements TaxCategory {
    private final String name;
    @Nullable
    private final String description;
    private final List taxRates;

    @JsonCreator
    TaxCategoryImpl(final String id, final Long version, final ZonedDateTime createdAt, final ZonedDateTime lastModifiedAt,
                    final String name, @Nullable final String description,
                    @JsonProperty("rates") final List taxRates) {
        super(id, version, createdAt, lastModifiedAt);
        this.name = name;
        this.description = description;
        this.taxRates = taxRates;
    }

    @Override
    public String getName() {
        return name;
    }

    @Override
    @Nullable
    public String getDescription() {
        return description;
    }

    @Override
    @JsonProperty("rates")
    public List getTaxRates() {
        return taxRates;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy