Skip to content

Commit

Permalink
Recontribute
Browse files Browse the repository at this point in the history
  • Loading branch information
hugohills-regnosys committed Nov 15, 2023
1 parent dfba951 commit f0b695e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 27 deletions.
27 changes: 4 additions & 23 deletions RELEASE.md
Original file line number Diff line number Diff line change
@@ -1,30 +1,11 @@
# _Commodity Product - Delivery for Commodity Options and Forwards_

_Background_

Commodity Forwards and Options which are not swaptions do not use any `commodityPayout` but just `forwardPayout` or `optionPayout` with a commodity underlier instead. As commodity products, these forwards and options do also require access to the delivery structures, which have been confined to the `CommodityPayout` so far. This release adds the necessary delivery structures for `ForwardPayout` and `OptionPayout`.
# *Product Model - FpML Synonym Mappings for UPI*

_What is being released?_

- Support for commodity delivery for commodity forwards and options.
- Renamed delivery structures to make them generic as opposed to commodity-specific.
This release extends the FpML mapping coverage for the enum `ProductIdTypeEnum` to support UPIs.

_Data types_

- Type `CommoditySchedule` renamed `CalculationSchedule`.
- Type `CommodityScheduleDeliveryPeriods` renamed `CalculationScheduleDeliveryPeriods`.
- Type `CommodityDeliveryInformation` renamed `AssetDeliveryInformation`.
- Type `CommodityDeliveryPeriods` renamed `AssetDeliveryPeriods`.
- Type `CommodityDeliveryProfile` renamed `AssetDeliveryProfile`.
- Type `CommodityDeliveryProfileBlock` renamed `AssetDeliveryProfileBlock`.
- Added attribute `delivery` of type `AssetDeliveryInformation` to type `OptionPayout`.
- Added attribute `delivery` of type `AssetDeliveryInformation` to type `ForwardPayout`.
- Added attribute `schedule` of type `CalculationSchedule` to type `ForwardPayout`.
- Added conditions `DeliveryCapacity` and `PriceTimeIntervalQuantity` to type `OptionPayout`.
- Added conditions `DeliveryCapacity` and `PriceTimeIntervalQuantity` to type `ForwardPayout`.
- The `ProductIdentifierSourceMappingProcessor` has been updated to map FpML productIdScheme http://www.fpml.org/coding-scheme/external/iso4914 to `ProductIdTypeEnum->UPI`.

_Review directions_

In the CDM Portal, select the Textual Browser and inspect each of the changes identified above.

Changes can be reviewed in [PR#2519](https://github.com/finos/common-domain-model/pull/2519)
- In the CDM Portal, select the Textual Browser and inspect the change listed above.
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@

import cdm.base.staticdata.asset.common.ProductIdTypeEnum;
import cdm.base.staticdata.asset.common.ProductIdentifier;
import cdm.base.staticdata.asset.common.ProductTaxonomy;
import cdm.base.staticdata.asset.common.TaxonomySourceEnum;
import com.regnosys.rosetta.common.translation.MappingContext;
import com.regnosys.rosetta.common.translation.MappingProcessor;
import com.regnosys.rosetta.common.translation.MappingProcessorUtils;
Expand All @@ -26,7 +24,6 @@ public void map(Path synonymPath, RosettaModelObjectBuilder builder, RosettaMode
MappingProcessorUtils.getNonNullMappingForModelPath(getMappings(), PathUtils.toPath(getModelPath().newSubPath("value")))
.map(m -> m.getXmlPath())
.ifPresent(xmlPath -> {
//
ProductIdentifier.ProductIdentifierBuilder productIdentifierBuilder = (ProductIdentifier.ProductIdentifierBuilder) parent;
FieldWithMetaString.FieldWithMetaStringBuilder productIdentifierValueBuilder = (FieldWithMetaString.FieldWithMetaStringBuilder) builder;

Expand Down Expand Up @@ -68,8 +65,10 @@ protected ProductIdTypeEnum getSourceEnum(String scheme) {
return ProductIdTypeEnum.RIC;
} else if (scheme.contains("Bloomberg")){
return ProductIdTypeEnum.BBGID;
}else if (scheme.contains("commodity-reference-price")){
} else if (scheme.contains("commodity-reference-price")){
return ProductIdTypeEnum.ISDACRP;
} else if (scheme.contains("iso4914")) {
return ProductIdTypeEnum.UPI;
} else {
return ProductIdTypeEnum.OTHER;
}
Expand Down

0 comments on commit f0b695e

Please sign in to comment.