private static void buildDynamicRowForAreaPtgBase ( final Object ptg , final byte originalOperandClass , final List < SerialRow > rowList , final Ptg [ ] newPtg ) { AreaPtgBase areaPtg = ( AreaPtgBase ) ptg ; int originFirstRow = areaPtg . getFirstRow ( ) ; int originLastRow = areaPtg . getLastRow ( ) ; int unitSize = 2 ; for ( int i = 0 ; i < rowList . size ( ) ; i ++ ) { Row row = rowList . get ( i ) . getRow ( ) ; int shiftRow = row . getRowNum ( ) - originFirstRow ; if ( ptg instanceof Area3DPxg ) { Area3DPxg area3dPxg = ( Area3DPxg ) ptg ; Area3DPxg new3dpxg = new Area3DPxg ( area3dPxg . getExternalWorkbookNumber ( ) , new SheetIdentifier ( null , new NameIdentifier ( area3dPxg . getSheetName ( ) , false ) ) , area3dPxg . format2DRefAsString ( ) ) ; new3dpxg . setClass ( originalOperandClass ) ; new3dpxg . setFirstColRelative ( area3dPxg . isFirstColRelative ( ) ) ; new3dpxg . setLastColRelative ( area3dPxg . isLastColRelative ( ) ) ; new3dpxg . setFirstRow ( originFirstRow + shiftRow ) ; new3dpxg . setLastRow ( originLastRow + shiftRow ) ; new3dpxg . setFirstRowRelative ( area3dPxg . isFirstRowRelative ( ) ) ; new3dpxg . setLastRowRelative ( area3dPxg . isLastRowRelative ( ) ) ; new3dpxg . setLastSheetName ( area3dPxg . getLastSheetName ( ) ) ; newPtg [ i * unitSize ] = new3dpxg ; } else { AreaPtgBase areaPtgBase = ( AreaPtgBase ) ptg ; newPtg [ i * unitSize ] = new AreaPtg ( originFirstRow + shiftRow , originLastRow + shiftRow , areaPtgBase . getFirstColumn ( ) , areaPtgBase . getLastColumn ( ) , areaPtgBase . isFirstRowRelative ( ) , areaPtgBase . isLastRowRelative ( ) , areaPtgBase . isFirstColRelative ( ) , areaPtgBase . isLastColRelative ( ) ) ; } if ( i < ( rowList . size ( ) - 1 ) ) { newPtg [ i * unitSize + 1 ] = ParenthesisPtg . instance ; } } }
Builds the dynamic row for area ptg base .