Interface DeliveryParcelDraft

All Superinterfaces:
Draft<DeliveryParcelDraft>

public interface DeliveryParcelDraft extends Draft<DeliveryParcelDraft>
DeliveryParcelDraft
Example to create an instance using the builder pattern

     DeliveryParcelDraft deliveryParcelDraft = DeliveryParcelDraft.builder()
             .build()
 
  • Method Details

    • getMeasurements

      @Valid @Valid ParcelMeasurements getMeasurements()
      Returns:
      measurements
    • getTrackingData

      @Valid @Valid TrackingData getTrackingData()
      Returns:
      trackingData
    • getItems

      @Valid @Valid List<DeliveryItem> getItems()
      Returns:
      items
    • setMeasurements

      void setMeasurements(ParcelMeasurements measurements)
      set measurements
      Parameters:
      measurements - value to be set
    • setTrackingData

      void setTrackingData(TrackingData trackingData)
      set trackingData
      Parameters:
      trackingData - value to be set
    • setItems

      void setItems(DeliveryItem... items)
      set items
      Parameters:
      items - values to be set
    • setItems

      void setItems(List<DeliveryItem> items)
      set items
      Parameters:
      items - values to be set
    • of

      static DeliveryParcelDraft of()
      factory method
      Returns:
      instance of DeliveryParcelDraft
    • of

      factory method to create a shallow copy DeliveryParcelDraft
      Parameters:
      template - instance to be copied
      Returns:
      copy instance
    • deepCopy

      factory method to create a deep copy of DeliveryParcelDraft
      Parameters:
      template - instance to be copied
      Returns:
      copy instance
    • builder

      static DeliveryParcelDraftBuilder builder()
      builder factory method for DeliveryParcelDraft
      Returns:
      builder
    • builder

      create builder for DeliveryParcelDraft instance
      Parameters:
      template - instance with prefilled values for the builder
      Returns:
      builder
    • withDeliveryParcelDraft

      default <T> T withDeliveryParcelDraft(Function<DeliveryParcelDraft,T> helper)
      accessor map function
      Type Parameters:
      T - mapped type
      Parameters:
      helper - function to map the object
      Returns:
      mapped value
    • typeReference

      static com.fasterxml.jackson.core.type.TypeReference<DeliveryParcelDraft> typeReference()
      gives a TypeReference for usage with Jackson DataBind
      Returns:
      TypeReference