# Business Logic - JKKMltiseInfoAddCfmCC.editEKK1091D010InMsg() [117 LOC]

| Field | Value |
|-------|-------|
| Fully Qualified Name | `com.fujitsu.futurity.bp.custom.common.JKKMltiseInfoAddCfmCC` |
| Layer | CC/Common Component (package: `com.fujitsu.futurity.bp.custom.common`) |
| Module | `common` (Package: `com.fujitsu.futurity.bp.custom.common`) |

## 1. Role

### JKKMltiseInfoAddCfmCC.editEKK1091D010InMsg()

This method is a **message template builder** that maps business data into a `CAANMsg` object for the **Progress Registration** (Shincho Toroku) workflow step in the K-Opticom back-office system. It is called during the Multi-Session Information Registration process for IPv6-enabled broadband subscribers. The method takes a request parameter object, an input hash containing form-derived data (such as service contract number, progress status, and movement reason codes), and a work map carrying results from prior screen review meetings (e.g., application detail confirmation and optional ISP contract confirmation). It builds an `EKK1091D010CBSMsg` template, resolves null-safe mappings for optional fields, conditionally sets the movement datetime from either a pre-captured timestamp or the current system time, and assembles a movement reason detail list (with reason codes and memo entries). The prepared template is then wrapped into a `TEMPLATE_LIST_KEY` entry in the output parameter map, which is consumed by the downstream service component that actually registers the progress record. The method uses a **builder pattern** to progressively fill a `CAANMsg` with fields, and a **delegation pattern** by calling `setCommonParamMap`, `fillCAANMSGNullMapping`, and `setCommonTemplate` to handle cross-cutting concerns (common parameter injection, null defaults, and system/operator metadata).

## 2. Processing Pattern (Detailed Business Logic)

```mermaid
flowchart TD
    START(["editEKK1091D010InMsg param,inHash,workMap"])
    STEP1["paramMap = new HashMap"]
    STEP2["setCommonParamMap param,paramMap"]
    STEP3["template = new CAANMsg EKK1091D010CBSMsg"]
    STEP4["fillCAANMSGNullMapping template,all fields"]
    STEP5["template.set TEMPLATE_ID = EKK1091D010"]
    STEP6["inHash != null ?"]
    STEP7["template.set FUNC_CODE = inHash.func_code"]
    STEP8["inHash == null || svc_kei_no empty ?"]
    STEP9["template.setNull SVC_KEI_NO"]
    STEP10["template.set SVC_KEI_NO = inHash.svc_kei_no"]
    STEP11["inHash == null || prg_stat empty ?"]
    STEP12["template.setNull PRG_STAT"]
    STEP13["template.set PRG_STAT = inHash.prg_stat"]
    STEP14["template.set SEIKY_KEI_NO = inHash.seik_kei_no"]
    STEP15["inHash == null || ido_div empty ?"]
    STEP16["template.setNull IDO_DIV"]
    STEP17["template.set IDO_DIV = inHash.ido_div"]
    STEP18["template.set PRG_TKJK_1 = Multi-Session Info Registration"]
    STEP19["eko1091B001Hash = workMap.get EKK1091B001"]
    STEP20["ido_dtm = eko1091B001Hash.ido_dtm"]
    STEP21["IDO_DIV = 00001 or 00002 ?"]
    STEP22["template.set IDO_DTM = ido_dtm from eko1091B001Hash"]
    STEP23["template.set IDO_DTM = JCCModelCommon.getSysDateTimeStamp"]
    STEP24["eKK0361D010Hash = workMap.get EKK0361D010"]
    STEP25["template.set OP_SVC_KEI_NO = eKK0361D010Hash.op_svc_kei_no"]
    STEP26["ekk0011d020Msg = workMap.get EKK0011D020"]
    STEP27["ekk0011d020MsgList = ekk0011d020Msg.EKK0011D020CBSMSG1LIST"]
    STEP28["kk0021Map = ekk0011d020MsgList get 0"]
    STEP29["mskm_dtl_no = kk0021Map.MSKM_DTL_NO"]
    STEP30["template.set MSKM_DTL_NO = mskm_dtl_no"]
    STEP31["idoRsnList = inHash.ido_rsn_list"]
    STEP32["idoRsnMemoList = inHash.ido_rsn_memo_list"]
    STEP33["Create CAANMsg array from idoRsnList"]
    STEP34["for i = 0 to idoRsnList.size"]
    STEP35["idoRsnTemp.set IDO_RSN_CD = idoRsnList.get i"]
    STEP36["idoRsnTemp.set IDO_RSN_MEMO = idoRsnMemoList.get i"]
    STEP37["list[i] = idoRsnTemp"]
    STEP38["template.set EKK1091D010CBSMSG1LIST = list"]
    STEP39["setCommonTemplate param,template"]
    STEP40["paramMap.put TEMPLATE_LIST_KEY = templates"]
    STEP41["return paramMap"]

    START --> STEP1 --> STEP2 --> STEP3 --> STEP4 --> STEP5
    STEP5 --> STEP6
    STEP6 -->|"true"| STEP8
    STEP6 -->|"false"| STEP7 --> STEP8
    STEP8 -->|"true"| STEP9 --> STEP11
    STEP8 -->|"false"| STEP10 --> STEP11
    STEP11 -->|"true"| STEP12 --> STEP14
    STEP11 -->|"false"| STEP13 --> STEP14
    STEP14 --> STEP15
    STEP15 -->|"true"| STEP16 --> STEP18
    STEP15 -->|"false"| STEP17 --> STEP18
    STEP18 --> STEP19 --> STEP20 --> STEP21
    STEP21 -->|"IDO_DIV = 00001 or 00002"| STEP22
    STEP21 -->|"else"| STEP23
    STEP22 --> STEP24 --> STEP25 --> STEP26 --> STEP27 --> STEP28 --> STEP29 --> STEP30
    STEP30 --> STEP31 --> STEP32 --> STEP33 --> STEP34 --> STEP35 --> STEP36 --> STEP37 --> STEP38 --> STEP39 --> STEP40 --> STEP41
```

**Constant Resolution:**

| Constant Name | Resolved Value | Business Meaning |
|---|---|---|
| `TEMPLATE_ID_EKK1091D010` | `"EKK1091D010"` | Progress Registration template ID |
| `PRG_TKJK_1_VAL_IPV6_INFO_ADD` | `"Multi-Session Information Registration"` | The special progress item value indicating this is a multi-session IPv6 info registration |
| `IDO_DIV_SINKI` | `"00001"` | Movement Classification: New Contract |
| `IDO_DIV_TSUIKA` | `"00002"` | Movement Classification: Service Addition |
| `SVC_KEI_NO` | `"svc_kei_no"` | Service Contract Number key in input hash |
| `SEIKY_KEI_NO` | `"seik_kei_no"` | Billing Contract Number key in input hash |
| `IDO_DIV` | `"ido_div"` | Movement Classification key in input hash |
| `PRG_STAT` | `"prg_stat"` | Progress Status key in input hash |
| `IDO_RSN_LIST` | `"ido_rsn_list"` | Movement Reason Code List key in input hash |
| `IDO_RSN_MEMO_LIST` | `"ido_rsn_memo_list"` | Movement Reason Memo List key in input hash |
| `TEMPLATE_ID_EKK1091B001` | `"EKK1091B001"` | Progress Review Meeting template ID |
| `TEMPLATE_ID_EKK0361D010` | `"EKK0361D010"` | Optional ISP Service Contract Registration template ID |
| `TEMPLATE_ID_EKK0011D020` | `"EKK0011D020"` | Application Detail Registration template ID |

## 3. Parameter Analysis

| No | Parameter Name | Type | Business Description |
|----|---------------|------|---------------------|
| 1 | `param` | `IRequestParameterReadOnly` | Business data access interface providing model group and control map context for the current session; used by `setCommonParamMap` to inject operator/system metadata into the output and by `setCommonTemplate` to add operator ID and operating timestamp to the template. |
| 2 | `inHash` | `HashMap<String, Object>` | Input data hash from the screen/form submission. Contains fields: `func_code` (function code), `svc_kei_no` (service contract number), `prg_stat` (progress status), `seik_kei_no` (billing contract number), `ido_div` (movement classification), `ido_rsn_list` (list of movement reason codes), and `ido_rsn_memo_list` (list of movement reason memos). May be null for fields that are optional. |
| 3 | `workMap` | `HashMap<String, Object>` | Cross-method work context map carrying results from prior processing steps: `EKK1091B001` (progress review meeting result with `ido_dtm` timestamp), `EKK0361D010` (optional ISP service contract confirmation result with `op_svc_kei_no`), and `EKK0011D020` (application detail registration containing `mskm_dtl_no` from the first detail entry). |

**Instance fields / external state read:**

None directly accessed. All fields referenced via `private static final` constants defined within this class.

## 4. CRUD Operations / Called Services

### Pre-computed evidence from code analysis graph:

| CRUD | SC / CBS | SC Code | Entity / DB | Operation Description |
|------|----------|---------|-------------|----------------------|
| R | `JCCBatCommon.getSysDateTimeStamp` | JCCBatCommon | - | Calls `getSysDateTimeStamp` in `JCCBatCommon` for system timestamp |
| R | `JCCBPCommon.getSysDateTimeStamp` | JCCBPCommon | - | Calls `getSysDateTimeStamp` in `JCCBPCommon` for system timestamp |
| - | `JCKMvnoCustInfoAddCC.setNull` | JCKMvnoCustInfoAddCC | - | Calls `setNull` in `JCKMvnoCustInfoAddCC` |
| - | `JKKKapKeiInfoCancelCC.setNull` | JKKKapKeiInfoCancelCC | - | Calls `setNull` in `JKKKapKeiInfoCancelCC` |
| - | `JKKKisnUwHmdkAddCC.setNull` | JKKKisnUwHmdkAddCC | - | Calls `setNull` in `JKKKisnUwHmdkAddCC` |
| - | `JKKKojiChgPlaceNoCC.setNull` | JKKKojiChgPlaceNoCC | - | Calls `setNull` in `JKKKojiChgPlaceNoCC` |
| - | `JKKMltiseInfoAddCfmCC.fillCAANMSGNullMapping` | JKKMltiseInfoAddCfmCC | - | Calls `fillCAANMSGNullMapping` to set all template fields to null defaults |
| - | `JKKMltiseInfoAddCfmCC.setCommonParamMap` | JKKMltiseInfoAddCfmCC | - | Calls `setCommonParamMap` to inject common parameter metadata into output |
| - | `JKKMltiseInfoAddCfmCC.setCommonTemplate` | JKKMltiseInfoAddCfmCC | - | Calls `setCommonTemplate` to add operator/system metadata to template |
| - | `JKKMvnoSvcKeiStaAddCC.setNull` | JKKMvnoSvcKeiStaAddCC | - | Calls `setNull` in `JKKMvnoSvcKeiStaAddCC` |
| R | `CRSV0221_CRSV0221OP_CRSV022101SC.getContents` | CRSV0221_CRSV022101SC | CRSV0221_CRSV0221OP_CRSV022101 | Calls `getContents` in `CRSV0221_CRSV022101SC` |
| R | `DKSV0013_DKSV0013OP_DKSV001301SC_EDKA0010009CBSMsg1List.getContents` | DKSV0013_DKSV0013OP_DKSV001301SC_EDKA0010009CBSMsg1List | - | Calls `getContents` in `DKSV0013` SC |
| R | `DKSV0013_DKSV0013OP_DKSV001301SC.getContents` | DKSV0013_DKSV0013OP_DKSV001301SC | DKSV0013_DKSV0013OP_DKSV0013 | Calls `getContents` in `DKSV0013` SC |
| R | `FUSV0170_FUSV0170OP.getContents` | FUSV0170_FUSV0170OP | - | Calls `getContents` in `FUSV0170` SC |
| R | `KK0801CBMMsg.getContents` | KK0801CBMMsg | - | Calls `getContents` in `KK0801CBMMsg` |
| R | `JACModelCommon.getSysDateTimeStamp` | JACModelCommon | - | Calls `getSysDateTimeStamp` in `JACModelCommon` for system timestamp |
| R | `JCCModelCommon.getSysDateTimeStamp` | JCCModelCommon | - | Calls `getSysDateTimeStamp` in `JCCModelCommon` for system timestamp |
| R | `JCHModelCommon.getSysDateTimeStamp` | JCHModelCommon | - | Calls `getSysDateTimeStamp` in `JCHModelCommon` for system timestamp |
| R | `SCW00701SFLogic.getName` | SCW00701SFLogic | - | Calls `getName` in `SCW00701SFLogic` |

### Method calls directly within this method:

| CRUD | SC / CBS | SC Code | Entity / DB | Operation Description |
|------|----------|---------|-------------|----------------------|
| - | `setCommonParamMap` | - | - | Sets common parameter metadata (operator ID, operating date) into the output paramMap |
| - | `fillCAANMSGNullMapping` | - | - | Sets all EKK1091D010CBSMsg template fields to null defaults |
| - | `setCommonTemplate` | - | - | Sets common template metadata (operator ID, operating timestamp) on the CAANMsg |
| R | `JCCModelCommon.getSysDateTimeStamp` | JCCModelCommon | - | Retrieves current system date/time stamp for movement datetime |
| - | `template.set` / `template.setNull` | - | - | Maps business data fields into the CAANMsg template |

## 5. Dependency Trace

### Pre-computed evidence from code analysis graph:

No screen/batch entry points found within 8 hops. Direct callers found: 4 methods.
Terminal operations from this method: `setCommonTemplate` [-], `setNull` [-], `setNull` [-], `setNull` [-], `setNull` [-], `setNull` [-], `setNull` [-], `setNull` [-], `setNull` [-], `setNull` [-], `setNull` [-], `getName` [R], `getSysDateTimeStamp` [R], `getSysDateTimeStamp` [R], `getSysDateTimeStamp` [R], `getSysDateTimeStamp` [R], `getSysDateTimeStamp` [R], `setNull` [-], `setNull` [-], `setNull` [-]

| # | Caller (Screen/Batch) | Call Chain (Full Path to this Method) | Terminal (SC / CRUD / Entity) |
|---|----------------------|--------------------------------------|-------------------------------|
| 1 | CBS:JKKMltiseInfoAddCfmCC.getEKK1091D010Map | `JKKMltiseInfoAddCfmCC.getEKK1091D010Map` -> `editEKK1091D010InMsg` | `setCommonTemplate` [-], `setNull` [-], `fillCAANMSGNullMapping` [-] |
| 2 | CBS:JKKAddIpv6Info.getEKK1091D010Map | `JKKAddIpv6Info.getEKK1091D010Map` -> `editEKK1091D010InMsg` | `setCommonTemplate` [-], `setNull` [-], `fillCAANMSGNullMapping` [-] |
| 3 | CBS:JKKOspvckeiCnslCC.getEKK1091D010Map | `JKKOspvckeiCnslCC.getEKK1091D010Map` -> `editEKK1091D010InMsg` | `setCommonTemplate` [-], `setNull` [-], `fillCAANMSGNullMapping` [-] |
| 4 | Screen:JKKSV??? (via getEKK1091D010Map) | Screen -> `getEKK1091D010Map` -> `editEKK1091D010InMsg` | `setCommonTemplate` [-], `setNull` [-], `fillCAANMSGNullMapping` [-] |

## 6. Per-Branch Detail Blocks

**Block 1** — [SET] `(L1908)` Initialize the output parameter map.

| # | Type | Code |
|---|------|------|
| 1 | SET | `paramMap = new HashMap<String, Object>()` // Create output map for return value |

**Block 2** — [EXEC] `(L1911)` Set common parameters from the request parameter.

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `setCommonParamMap(param, paramMap)` // Inject operator/system metadata into paramMap |

**Block 3** — [SET] `(L1913)` Create the CAANMsg template using EKK1091D010CBSMsg.

| # | Type | Code |
|---|------|------|
| 1 | SET | `template = new CAANMsg(EKK1091D010CBSMsg.class.getName())` // Build Progress Registration message template |

**Block 4** — [EXEC] `(L1916)` Apply null defaults to all template fields.

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `fillCAANMSGNullMapping(template, new EKK1091D010CBSMsg().getContents())` // Set all fields to null mapping |

**Block 5** — [SET] `(L1919)` Set the template ID.

| # | Type | Code |
|---|------|------|
| 1 | SET | `template.set(EKK1091D010CBSMsg.TEMPLATEID, TEMPLATE_ID_EKK1091D010)` // TEMPLATE_ID_EKK1091D010 = "EKK1091D010" |

**Block 6** — [IF] `(inHash != null)` Set the function code from input hash [L1921]

| # | Type | Code |
|---|------|------|
| 1 | SET | `template.set(EKK1091D010CBSMsg.FUNC_CODE, inHash.get(JCMConstants.FUNC_CODE_KEY))` // Function code from form data |

- **Block 6.1** — [ELSE] `inHash == null` — Function code is not set (remains null from fillCAANMSGNullMapping) [L1921]

**Block 7** — [IF/ELSE] Service Contract Number (`SVC_KEI_NO`) null-safe mapping [L1925]

| # | Type | Code |
|---|------|------|
| 1 | SET | `inHash == null || inHash.get(SVC_KEI_NO) == null || "".equals(inHash.get(SVC_KEI_NO))` // Check if service contract number is absent |

- **Block 7.1** — [IF] SVC_KEI_NO is null or empty

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `template.setNull(EKK1091D010CBSMsg.SVC_KEI_NO)` // Set service contract number to null in template |

- **Block 7.2** — [ELSE] SVC_KEI_NO has a value

| # | Type | Code |
|---|------|------|
| 1 | SET | `template.set(EKK1091D010CBSMsg.SVC_KEI_NO, (String) inHash.get(SVC_KEI_NO))` // Map service contract number from input hash |

**Block 8** — [IF/ELSE] Progress Status (`PRG_STAT`) null-safe mapping [L1931]

| # | Type | Code |
|---|------|------|
| 1 | SET | `inHash == null || inHash.get(PRG_STAT) == null || "".equals(inHash.get(PRG_STAT))` // Check if progress status is absent |

- **Block 8.1** — [IF] PRG_STAT is null or empty

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `template.setNull(EKK1091D010CBSMsg.PRG_STAT)` // Set progress status to null in template |

- **Block 8.2** — [ELSE] PRG_STAT has a value

| # | Type | Code |
|---|------|------|
| 1 | SET | `template.set(EKK1091D010CBSMsg.PRG_STAT, (String) inHash.get(PRG_STAT))` // Map progress status from input hash |

**Block 9** — [SET] `(L1936)` Set the Billing Contract Number (`SEIKY_KEI_NO`).

| # | Type | Code |
|---|------|------|
| 1 | SET | `template.set(EKK1091D010CBSMsg.SEIKY_KEI_NO, (String)inHash.get(SEIKY_KEI_NO))` // Billing contract number cast from inHash |

**Block 10** — [IF/ELSE] Movement Classification (`IDO_DIV`) null-safe mapping [L1939]

| # | Type | Code |
|---|------|------|
| 1 | SET | `inHash == null || inHash.get(IDO_DIV) == null || "".equals(inHash.get(IDO_DIV))` // Check if movement classification is absent |

- **Block 10.1** — [IF] IDO_DIV is null or empty

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `template.setNull(EKK1091D010CBSMsg.IDO_DIV)` // Set movement classification to null |

- **Block 10.2** — [ELSE] IDO_DIV has a value

| # | Type | Code |
|---|------|------|
| 1 | SET | `template.set(EKK1091D010CBSMsg.IDO_DIV, (String) inHash.get(IDO_DIV))` // Map movement classification from input hash |

**Block 11** — [SET] `(L1944)` Set the Progress Special Item 1 to a fixed value.

| # | Type | Code |
|---|------|------|
| 1 | SET | `template.set(EKK1091D010CBSMsg.PRG_TKJK_1, PRG_TKJK_1_VAL_IPV6_INFO_ADD)` // PRG_TKJK_1_VAL_IPV6_INFO_ADD = "Multi-Session Information Registration" |

**Block 12** — [SET] `(L1947)` Retrieve the progress review meeting result from the work map.

| # | Type | Code |
|---|------|------|
| 1 | SET | `ekk1091B001Hash = (HashMap<String, Object>)workMap.get(TEMPLATE_ID_EKK1091B001)` // Progress review meeting result (EKK1091B001) |
| 2 | SET | `ido_dtm = null` // Initialize movement datetime to null |
| 3 | SET | `ido_dtm = (String)ekk1091B001Hash.get("ido_dtm")` // Get movement datetime from progress review meeting if available |

**Block 13** — [IF/ELSE] Movement Datetime source: pre-captured vs. system time based on Movement Classification [L1951]

| # | Type | Code |
|---|------|------|
| 1 | SET | `IDO_DIV_SINKI.equals((String)inHash.get(IDO_DIV)) || IDO_DIV_TSUIKA.equals((String)inHash.get(IDO_DIV))` // IDO_DIV = "00001" (New Contract) or "00002" (Service Addition) |

> Business Description: When the movement classification is New Contract (`00001`) or Service Addition (`00002`), the movement datetime is taken from the pre-captured progress review meeting map. Otherwise, the current system time is used.

- **Block 13.1** — [IF] Movement Classification is New Contract (`00001`) or Service Addition (`00002`)

> Business Description: For new contracts and service additions, preserve the movement datetime captured at the progress review meeting screen to maintain audit trail consistency.

| # | Type | Code |
|---|------|------|
| 1 | SET | `template.set(EKK1091D010CBSMsg.IDO_DTM, ido_dtm)` // Use pre-captured movement datetime from progress review meeting |

- **Block 13.2** — [ELSE] Movement Classification is something other than New Contract or Service Addition

> Business Description: For other movement types (e.g., contract change, suspension, resumption), set the movement datetime to the current system timestamp at the time of processing.

| # | Type | Code |
|---|------|------|
| 1 | SET | `template.set(EKK1091D010CBSMsg.IDO_DTM, JCCModelCommon.getSysDateTimeStamp())` // Current system datetime as fallback |

**Block 14** — [SET] `(L1956)` Set the Optional ISP Service Contract Number from the work map.

| # | Type | Code |
|---|------|------|
| 1 | SET | `eKK0361D010Hash = (HashMap<String, Object>)workMap.get(TEMPLATE_ID_EKK0361D010)` // Optional ISP service contract confirmation result (EKK0361D010) |
| 2 | SET | `template.set(EKK1091D010CBSMsg.OP_SVC_KEI_NO, eKK0361D010Hash.get(EKK0361D010CBSMsg.OP_SVC_KEI_NO))` // Map optional ISP service contract number |

**Block 15** — [SET] `(L1960)` Extract the Application Detail Number from the work map.

| # | Type | Code |
|---|------|------|
| 1 | SET | `ekk0011d020Msg = (HashMap<?, ?>)workMap.get(TEMPLATE_ID_EKK0011D020)` // Application detail registration result (EKK0011D020) |
| 2 | SET | `ekk0011d020MsgList = (ArrayList<?>)ekk0011d020Msg.get(EKK0011D020CBSMsg.EKK0011D020CBSMSG1LIST)` // Get the list of application detail entries |
| 3 | SET | `kk0021Map = (HashMap<?, ?>)ekk0011d020MsgList.get(0)` // Take the first entry |
| 4 | SET | `mskm_dtl_no = kk0021Map.get(EKK0011D020CBSMsg1List.MSKM_DTL_NO)` // Extract application detail number |
| 5 | SET | `template.set(EKK1091D010CBSMsg.MSKM_DTL_NO, mskm_dtl_no)` // Map application detail number to template |

**Block 16** — [SET] `(L1965)` Retrieve the Movement Reason Code list and Memo list from input hash.

| # | Type | Code |
|---|------|------|
| 1 | SET | `idoRsnList = (ArrayList)inHash.get(IDO_RSN_LIST)` // Movement reason codes list |
| 2 | SET | `idoRsnMemoList = (ArrayList)inHash.get(IDO_RSN_MEMO_LIST)` // Movement reason memos list |
| 3 | SET | `list = new CAANMsg[idoRsnList.size()]` // Create result array for detail items |

**Block 17** — [FOR] `(for int i = 0; i < idoRsnList.size(); i++)` Iterate over movement reason entries [L1968]

| # | Type | Code |
|---|------|------|
| 1 | SET | `idoRsnTemp = new CAANMsg(EKK1091D010CBSMsg1List.class.getName())` // Create a detail CAANMsg for each reason entry |

- **Block 17.1** — [IF/ELSE] Movement Reason Code null-safe mapping [L1970]

| # | Type | Code |
|---|------|------|
| 1 | SET | `idoRsnList == null || idoRsnList.get(i) == null || "".equals(idoRsnList.get(i))` // Check if reason code at index i is absent |

  - **Block 17.1.1** — [IF] Reason code at index `i` is null or empty

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `idoRsnTemp.setNull(EKK1091D010CBSMsg1List.IDO_RSN_CD)` // Set reason code to null |

  - **Block 17.1.2** — [ELSE] Reason code has a value

| # | Type | Code |
|---|------|------|
| 1 | SET | `idoRsnTemp.set(EKK1091D010CBSMsg1List.IDO_RSN_CD, idoRsnList.get(i))` // Set reason code from list |

- **Block 17.2** — [IF/ELSE] Movement Reason Memo null-safe mapping [L1978]

| # | Type | Code |
|---|------|------|
| 1 | SET | `idoRsnMemoList == null || idoRsnMemoList.get(i) == null || "".equals(idoRsnMemoList.get(i))` // Check if memo at index i is absent |

  - **Block 17.2.1** — [IF] Memo at index `i` is null or empty

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `idoRsnTemp.setNull(EKK1091D010CBSMsg1List.IDO_RSN_MEMO)` // Set reason memo to null |

  - **Block 17.2.2** — [ELSE] Memo has a value

| # | Type | Code |
|---|------|------|
| 1 | SET | `idoRsnTemp.set(EKK1091D010CBSMsg1List.IDO_RSN_MEMO, idoRsnMemoList.get(i))` // Set reason memo from list |

- **Block 17.3** — [SET] `(L1988)` Store the populated reason detail in the result array.

| # | Type | Code |
|---|------|------|
| 1 | SET | `list[i] = idoRsnTemp` // Add processed detail item to the result array |

**Block 18** — [SET] `(L1993)` Set the assembled movement reason detail list into the template.

| # | Type | Code |
|---|------|------|
| 1 | SET | `template.set(EKK1091D010CBSMsg.EKK1091D010CBSMSG1LIST, list)` // Map the movement reason detail list to template |

**Block 19** — [EXEC] `(L1996)` Set common template metadata (operator, system info).

| # | Type | Code |
|---|------|------|
| 1 | EXEC | `setCommonTemplate(param, template)` // Add operator ID and operating date to template |

**Block 20** — [SET] `(L1998)` Wrap the template in a templates array and put it in the output map.

| # | Type | Code |
|---|------|------|
| 1 | SET | `templates = new CAANMsg[1]` // Create templates array |
| 2 | SET | `templates[0] = template` // Place the single template in the array |
| 3 | SET | `paramMap.put(JCMConstants.TEMPLATE_LIST_KEY, templates)` // Put templates under TEMPLATE_LIST_KEY |

**Block 21** — [RETURN] `(L2002)` Return the constructed parameter map.

| # | Type | Code |
|---|------|------|
| 1 | RETURN | `return paramMap` // Return map containing the prepared CAANMsg template list |

## 7. Glossary

| Term | Type | Business Meaning |
|------|------|------------------|
| `svc_kei_no` | Field | Service Contract Number — the unique identifier for a service contract line item |
| `svc_kei_ucwk_no` | Field | Service Contract Internal Detail Number — internal tracking ID for service contract sub-lines |
| `seiky_kei_no` | Field | Billing Contract Number — the contract number used for invoicing/billing purposes |
| `prg_stat` | Field | Progress Status — tracks the workflow stage of a contract processing operation (e.g., "5101" for Option Requested, "5102" for Option Setup Complete) |
| `ido_div` | Field | Movement Classification — indicates the type of contract change (e.g., "00001" for New Contract, "00002" for Service Addition) |
| `ido_dtm` | Field | Movement Datetime — the timestamp of the contract movement/change |
| `ido_rsn_cd` | Field | Movement Reason Code — the code explaining why a contract movement occurred |
| `ido_rsn_memo` | Field | Movement Reason Memo — free-text explanation for the movement reason |
| `mskm_dtl_no` | Field | Application Detail Number — unique identifier for an application detail entry |
| `prg_tkjk_1` | Field | Progress Special Item 1 — a special-purpose flag field used to classify the type of progress operation |
| `op_svc_kei_no` | Field | Optional ISP Service Contract Number — the service contract number for the optional ISP (Internet Service Provider) contract |
| `func_code` | Field | Function Code — identifies which screen/function is making the request |
| CAANMsg | Technical | Common Application Annotation ANnotation — Fujitsu message/template object used for data transfer between presentation, business logic, and service component layers |
| EKK1091D010 | Template | Progress Registration template — the message schema for committing progress/state changes to the system |
| EKK1091B001 | Template | Progress Review Meeting template — captures the state of the progress review screen including timestamps |
| EKK0361D010 | Template | Optional ISP Service Contract Registration template — manages optional ISP contract registration data |
| EKK0011D020 | Template | Application Detail Registration template — holds application detail confirmation data |
| EKK | Code Prefix | K-Opticom prefix for customer-facing service component templates |
| Multi-Session | Business | Multi-Session — a broadband service feature allowing multiple concurrent device connections under a single subscription |
| IPv6 | Business | Internet Protocol version 6 — the newer IP addressing scheme used for the IPv6 Information Registration process |
| Progress Registration | Business | Shincho Toroku — the K-Opticom workflow step where service contract state changes (movements) are formally registered into the system |
| New Contract | Business | New Contract — a brand new service contract (IDO_DIV = "00001") |
| Service Addition | Business | Service Addition — adding a new service line to an existing contract (IDO_DIV = "00002") |
| SOD | Acronym | Service Order Data — telecom order fulfillment entity in the K-Opticom system |
| SC | Acronym | Service Component — the service-layer component that executes business operations (CRUD) against the database |
| CBS | Acronym | Component-Based System — the CBS message schema layer defining data transfer structures |
| CC | Acronym | Common Component — reusable business logic components in the CC layer |
| `TEMPLATE_ID_EKK1091D010` | Constant | "EKK1091D010" — Progress Registration template identifier |
| `TEMPLATE_ID_EKK1091B001` | Constant | "EKK1091B001" — Progress Review Meeting template identifier |
| `TEMPLATE_ID_EKK0361D010` | Constant | "EKK0361D010" — Optional ISP Service Contract Registration template identifier |
| `TEMPLATE_ID_EKK0011D020` | Constant | "EKK0011D020" — Application Detail Registration template identifier |
| `IDO_DIV_SINKI` | Constant | "00001" — Movement Classification for New Contract |
| `IDO_DIV_TSUIKA` | Constant | "00002" — Movement Classification for Service Addition |
| `PRG_TKJK_1_VAL_IPV6_INFO_ADD` | Constant | "Multi-Session Information Registration" — value for the Progress Special Item 1 field |
| `TEMPLATE_LIST_KEY` | Constant | JCMConstants key — the map key under which the CAANMsg template array is stored in the output parameter map |
| `FUNC_CODE_KEY` | Constant | JCMConstants key — the hash key for the function code in the input data |
