com.logicommerce.sdk.models.order.implementations.OrderShippingTrackingPackageImpl Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of sdk Show documentation
Show all versions of sdk Show documentation
SDK for developing Logicommerce plugins.
package com.logicommerce.sdk.models.order.implementations;
import java.time.LocalDateTime;
import java.util.ArrayList;
import java.util.List;
import com.logicommerce.sdk.models.order.OrderShippingTrackingPackage;
import com.logicommerce.sdk.models.order.OrderShippingTrackingPackageActivity;
import com.logicommerce.utilities.annotations.Uses;
/**
* OrderShippingTrackingPackageImpl class.
*
* @author Logicommerce
* @since 1.0.16
*/
public class OrderShippingTrackingPackageImpl implements OrderShippingTrackingPackage {
private Integer id;
private Double weight;
private String weightUnits;
private LocalDateTime lastUpdate;
@Uses(value = OrderShippingTrackingPackageActivityImpl.class)
private List activities;
/** {@inheritDoc} */
@Override
public Integer getId() {
return id;
}
/** {@inheritDoc} */
@Override
public Double getWeight() {
return weight;
}
/** {@inheritDoc} */
@Override
public String getWeightUnits() {
return weightUnits;
}
/** {@inheritDoc} */
@Override
public LocalDateTime getLastUpdate() {
return lastUpdate;
}
/** {@inheritDoc} */
@Override
public List getActivities() {
return activities;
}
/** {@inheritDoc} */
@Override
public void setWeight(Double weight) {
this.weight = weight;
}
/** {@inheritDoc} */
@Override
public void setWeightUnits(String weightUnits) {
this.weightUnits = weightUnits;
}
/** {@inheritDoc} */
@Override
public void addActivty(OrderShippingTrackingPackageActivity activity) {
if (activities == null) {
activities = new ArrayList<>();
}
activities.add(activity);
}
/**
* Setter for the field id
.
*
* @param id a {@link java.lang.Integer} object
*/
public void setId(Integer id) {
this.id = id;
}
/**
* Setter for the field lastUpdate
.
*
* @param lastUpdate a {@link java.time.LocalDateTime} object
*/
public void setLastUpdate(LocalDateTime lastUpdate) {
this.lastUpdate = lastUpdate;
}
/**
* Setter for the field activities
.
*
* @param activities a {@link java.util.List} object
*/
public void setActivities(List activities) {
this.activities = activities;
}
}