copyWithWrapped method

ShopifySharpDiscountApplication copyWithWrapped({
  1. Wrapped<String?>? type,
  2. Wrapped<String?>? code,
  3. Wrapped<String?>? title,
  4. Wrapped<String?>? description,
  5. Wrapped<String?>? value,
  6. Wrapped<String?>? valueType,
  7. Wrapped<String?>? allocationMethod,
  8. Wrapped<String?>? targetSelection,
  9. Wrapped<String?>? targetType,
})

Implementation

ShopifySharpDiscountApplication copyWithWrapped({
  Wrapped<String?>? type,
  Wrapped<String?>? code,
  Wrapped<String?>? title,
  Wrapped<String?>? description,
  Wrapped<String?>? value,
  Wrapped<String?>? valueType,
  Wrapped<String?>? allocationMethod,
  Wrapped<String?>? targetSelection,
  Wrapped<String?>? targetType,
}) {
  return ShopifySharpDiscountApplication(
    type: (type != null ? type.value : this.type),
    code: (code != null ? code.value : this.code),
    title: (title != null ? title.value : this.title),
    description: (description != null ? description.value : this.description),
    value: (value != null ? value.value : this.value),
    valueType: (valueType != null ? valueType.value : this.valueType),
    allocationMethod: (allocationMethod != null
        ? allocationMethod.value
        : this.allocationMethod),
    targetSelection: (targetSelection != null
        ? targetSelection.value
        : this.targetSelection),
    targetType: (targetType != null ? targetType.value : this.targetType),
  );
}