Source:
<code>public void setArtifact(BlackboardArtifact artifact) { this.removeAll(); reset(); <START> initComponents(); <END> List<BlackboardAttribute> phoneNumList = new ArrayList<>(); List<BlackboardAttribute> emailList = new ArrayList<>(); List<BlackboardAttribute> nameList = new ArrayList<>(); List<BlackboardAttribute> otherList = new ArrayList<>(); List<BlackboardAttribute> accountAttributesList = new ArrayList<>(); try { for (BlackboardAttribute bba : artifact.getAttributes()) { if (bba.getAttributeType().getTypeName().startsWith("TSK_PHONE")) { phoneNumList.add(bba); accountAttributesList.add(bba); } else if (bba.getAttributeType().getTypeName().startsWith("TSK_EMAIL")) { emailList.add(bba); accountAttributesList.add(bba); } else if (bba.getAttributeType().getTypeName().startsWith("TSK_NAME")) { nameList.add(bba); } else { otherList.add(bba); if (bba.getAttributeType().getTypeName().equalsIgnoreCase("TSK_ID")) { accountAttributesList.add(bba); } } } } catch (TskCoreException ex) { logger.log(Level.SEVERE, String.format("Error getting attributes for artifact (artifact_id=%d, obj_id=%d)", artifact.getArtifactID(), artifact.getObjectID()), ex); } updateNamePanel(nameList); updateSection(phoneNumList, this.phonesLabel, this.phoneNumbersPanel); updateSection(emailList, this.emailsLabel, this.emailsPanel); updateSection(otherList, this.othersLabel, this.otherAttrsPanel); try { initiatePersonasSearch(accountAttributesList); } catch (CentralRepoException ex) { logger.log(Level.SEVERE, String.format("Error getting Personas for Contact artifact (artifact_id=%d, obj_id=%d)", artifact.getArtifactID(), artifact.getObjectID()), ex); } this.revalidate(); }</code><technical_language>initComponent called in setArtifacts. called in constructor</technical_language>

Target:
public void setArtifact(BlackboardArtifact artifact) { resetComponent(); List<BlackboardAttribute> phoneNumList = new ArrayList<>(); List<BlackboardAttribute> emailList = new ArrayList<>(); List<BlackboardAttribute> nameList = new ArrayList<>(); List<BlackboardAttribute> otherList = new ArrayList<>(); List<BlackboardAttribute> accountAttributesList = new ArrayList<>(); try { for (BlackboardAttribute bba : artifact.getAttributes()) { if (bba.getAttributeType().getTypeName().startsWith("TSK_PHONE")) { phoneNumList.add(bba); accountAttributesList.add(bba); } else if (bba.getAttributeType().getTypeName().startsWith("TSK_EMAIL")) { emailList.add(bba); accountAttributesList.add(bba); } else if (bba.getAttributeType().getTypeName().startsWith("TSK_NAME")) { nameList.add(bba); } else { otherList.add(bba); if (bba.getAttributeType().getTypeName().equalsIgnoreCase("TSK_ID")) { accountAttributesList.add(bba); } } } } catch (TskCoreException ex) { logger.log(Level.SEVERE, String.format("Error getting attributes for artifact (artifact_id=%d, obj_id=%d)", artifact.getArtifactID(), artifact.getObjectID()), ex); } updateNamePanel(nameList); updateSection(phoneNumList, this.phonesLabel, this.phoneNumbersPanel); updateSection(emailList, this.emailsLabel, this.emailsPanel); updateSection(otherList, this.othersLabel, this.otherAttrsPanel); try { initiatePersonasSearch(accountAttributesList); } catch (CentralRepoException ex) { logger.log(Level.SEVERE, String.format("Error getting Personas for Contact artifact (artifact_id=%d, obj_id=%d)", artifact.getArtifactID(), artifact.getObjectID()), ex); } this.revalidate(); this.repaint(); }